diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2012-07-07 14:36:36 +0200 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2012-07-23 23:57:44 +0200 |
commit | 644800f593f799502323e21f1ad4d6861f5c5b35 (patch) | |
tree | 41838672217a3ea40b6ce3872c6e1a4a30e7f564 /lib | |
parent | 0742542f8755b41db65be8767dd8b674854ea33f (diff) | |
download | barebox-644800f593f799502323e21f1ad4d6861f5c5b35.tar.gz barebox-644800f593f799502323e21f1ad4d6861f5c5b35.tar.xz |
lzo: Allow for static inlining
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/decompress_unlzo.c | 9 | ||||
-rw-r--r-- | lib/lzo/lzo1x_decompress.c | 2 |
2 files changed, 8 insertions, 3 deletions
diff --git a/lib/decompress_unlzo.c b/lib/decompress_unlzo.c index 000bd704c3..0e6a7ad6d2 100644 --- a/lib/decompress_unlzo.c +++ b/lib/decompress_unlzo.c @@ -33,11 +33,16 @@ #include <common.h> #include <malloc.h> #include <linux/types.h> -#include <lzo.h> #include <errno.h> #include <fs.h> #include <xfuncs.h> +#ifdef STATIC +#include "lzo/lzo1x_decompress.c" +#endif + +#include <lzo.h> + #include <linux/compiler.h> #include <asm/unaligned.h> @@ -106,7 +111,7 @@ static inline int parse_header(u8 *input, int *skip, int in_len) return 1; } -int decompress_unlzo(u8 *input, int in_len, +STATIC int decompress_unlzo(u8 *input, int in_len, int (*fill) (void *, unsigned int), int (*flush) (void *, unsigned int), u8 *output, int *posp, diff --git a/lib/lzo/lzo1x_decompress.c b/lib/lzo/lzo1x_decompress.c index af943829dc..7f1451f085 100644 --- a/lib/lzo/lzo1x_decompress.c +++ b/lib/lzo/lzo1x_decompress.c @@ -23,7 +23,7 @@ #define COPY4(dst, src) \ put_unaligned(get_unaligned((const u32 *)(src)), (u32 *)(dst)) -int lzo1x_decompress_safe(const unsigned char *in, size_t in_len, +STATIC int lzo1x_decompress_safe(const unsigned char *in, size_t in_len, unsigned char *out, size_t *out_len) { const unsigned char * const ip_end = in + in_len; |