wok-6.x view linux-libre/stuff/linux-squashfs-lzma-2.6.34.u @ rev 16339
ARM: fix squeak-vm cross compilation
author | Christophe Lincoln <pankso@slitaz.org> |
---|---|
date | Sat Apr 12 14:27:19 2014 +0200 (2014-04-12) |
parents | |
children |
line source
1 --- linux-2.6.30.6/include/linux/decompress/bunzip2_mm.h
2 +++ linux-2.6.30.6/include/linux/decompress/bunzip2_mm.h
3 @@ -0,0 +1,13 @@
4 +#ifndef BUNZIP2_MM_H
5 +#define BUNZIP2_MM_H
6 +
7 +#ifdef STATIC
8 +/* Code active when included from pre-boot environment: */
9 +#define INIT
10 +#else
11 +/* Compile for initramfs/initrd code only */
12 +#define INIT __init
13 +static void(*error)(char *m);
14 +#endif
15 +
16 +#endif
18 --- linux-2.6.30.6/include/linux/decompress/inflate_mm.h
19 +++ linux-2.6.30.6/include/linux/decompress/inflate_mm.h
20 @@ -0,0 +1,13 @@
21 +#ifndef INFLATE_MM_H
22 +#define INFLATE_MM_H
23 +
24 +#ifdef STATIC
25 +/* Code active when included from pre-boot environment: */
26 +#define INIT
27 +#else
28 +/* Compile for initramfs/initrd code only */
29 +#define INIT __init
30 +static void(*error)(char *m);
31 +#endif
32 +
33 +#endif
35 #--- linux-2.6.30.6/include/linux/decompress/mm.h
36 #+++ linux-2.6.30.6/include/linux/decompress/mm.h
37 @@ -63,8 +63,6 @@
39 #define set_error_fn(x)
41 -#define INIT
42 -
43 #else /* STATIC */
45 /* Code active when compiled standalone for use when loading ramdisk: */
46 @@ -84,10 +82,8 @@
47 #define large_malloc(a) vmalloc(a)
48 #define large_free(a) vfree(a)
50 -static void(*error)(char *m);
51 #define set_error_fn(x) error = x;
53 -#define INIT __init
54 #define STATIC
56 #include <linux/init.h>
58 --- linux-2.6.30.6/include/linux/decompress/unlzma_mm.h
59 +++ linux-2.6.30.6/include/linux/decompress/unlzma_mm.h
60 @@ -0,0 +1,20 @@
61 +#ifndef UNLZMA_MM_H
62 +#define UNLZMA_MM_H
63 +
64 +#ifdef STATIC
65 +
66 +/* Code active when included from pre-boot environment: */
67 +#define INIT
68 +
69 +#elif defined(CONFIG_DECOMPRESS_LZMA_NEEDED)
70 +
71 +/* Make it available to non initramfs/initrd code */
72 +#define INIT
73 +#include <linux/module.h>
74 +#else
75 +
76 +/* Compile for initramfs/initrd code only */
77 +#define INIT __init
78 +#endif
79 +
80 +#endif
82 --- linux-2.6.30.6/lib/Kconfig
83 +++ linux-2.6.30.6/lib/Kconfig
84 @@ -117,6 +117,9 @@
85 config DECOMPRESS_LZMA
86 tristate
88 +config DECOMPRESS_LZMA_NEEDED
89 + boolean
90 +
91 config DECOMPRESS_LZO
92 select LZO_DECOMPRESS
93 tristate
95 --- linux-2.6.30.6/lib/decompress_bunzip2.c
96 +++ linux-2.6.30.6/lib/decompress_bunzip2.c
97 @@ -52,6 +52,7 @@
98 #include <linux/slab.h>
99 #endif /* STATIC */
101 +#include <linux/decompress/bunzip2_mm.h>
102 #include <linux/decompress/mm.h>
104 #ifndef INT_MAX
106 --- linux-2.6.30.6/lib/decompress_inflate.c
107 +++ linux-2.6.30.6/lib/decompress_inflate.c
108 @@ -23,6 +23,7 @@
110 #endif /* STATIC */
112 +#include <linux/decompress/inflate_mm.h>
113 #include <linux/decompress/mm.h>
115 #define GZIP_IOBUF_SIZE (16*1024)
117 --- linux-2.6.30.6/lib/decompress_unlzma.c
118 +++ linux-2.6.30.6/lib/decompress_unlzma.c
119 @@ -36,6 +36,7 @@
120 #include <linux/slab.h>
121 #endif /* STATIC */
123 +#include <linux/decompress/unlzma_mm.h>
124 #include <linux/decompress/mm.h>
126 #define MIN(a, b) (((a) < (b)) ? (a) : (b))
127 @@ -88,7 +89,7 @@
128 }
130 /* Called twice: once at startup and once in rc_normalize() */
131 -static void INIT rc_read(struct rc *rc)
132 +static void INIT rc_read(struct rc *rc, void(*error)(char *x))
133 {
134 rc->buffer_size = rc->fill((char *)rc->buffer, LZMA_IOBUF_SIZE);
135 if (rc->buffer_size <= 0)
136 @@ -115,13 +116,13 @@
137 rc->range = 0xFFFFFFFF;
138 }
140 -static inline void INIT rc_init_code(struct rc *rc)
141 +static inline void INIT rc_init_code(struct rc *rc, void(*error)(char *x))
142 {
143 int i;
145 for (i = 0; i < 5; i++) {
146 if (rc->ptr >= rc->buffer_end)
147 - rc_read(rc);
148 + rc_read(rc, error);
149 rc->code = (rc->code << 8) | *rc->ptr++;
150 }
151 }
152 @@ -134,32 +135,33 @@
153 }
155 /* Called twice, but one callsite is in inline'd rc_is_bit_0_helper() */
156 -static void INIT rc_do_normalize(struct rc *rc)
157 +static void INIT rc_do_normalize(struct rc *rc, void(*error)(char *x))
158 {
159 if (rc->ptr >= rc->buffer_end)
160 - rc_read(rc);
161 + rc_read(rc, error);
162 rc->range <<= 8;
163 rc->code = (rc->code << 8) | *rc->ptr++;
164 }
165 -static inline void INIT rc_normalize(struct rc *rc)
166 +static inline void INIT rc_normalize(struct rc *rc, void(*error)(char *x))
167 {
168 if (rc->range < (1 << RC_TOP_BITS))
169 - rc_do_normalize(rc);
170 + rc_do_normalize(rc, error);
171 }
173 /* Called 9 times */
174 /* Why rc_is_bit_0_helper exists?
175 *Because we want to always expose (rc->code < rc->bound) to optimizer
176 */
177 -static inline uint32_t INIT rc_is_bit_0_helper(struct rc *rc, uint16_t *p)
178 +static inline uint32_t INIT rc_is_bit_0_helper(struct rc *rc, uint16_t *p,
179 + void (*error)(char *x))
180 {
181 - rc_normalize(rc);
182 + rc_normalize(rc, error);
183 rc->bound = *p * (rc->range >> RC_MODEL_TOTAL_BITS);
184 return rc->bound;
185 }
186 -static inline int INIT rc_is_bit_0(struct rc *rc, uint16_t *p)
187 +static inline int INIT rc_is_bit_0(struct rc *rc, uint16_t *p, void(*error)(char *x))
188 {
189 - uint32_t t = rc_is_bit_0_helper(rc, p);
190 + uint32_t t = rc_is_bit_0_helper(rc, p, error);
191 return rc->code < t;
192 }
194 @@ -177,9 +179,9 @@
195 }
197 /* Called 4 times in unlzma loop */
198 -static int INIT rc_get_bit(struct rc *rc, uint16_t *p, int *symbol)
199 +static int INIT rc_get_bit(struct rc *rc, uint16_t *p, int *symbol, void(*error)(char *x))
200 {
201 - if (rc_is_bit_0(rc, p)) {
202 + if (rc_is_bit_0(rc, p, error)) {
203 rc_update_bit_0(rc, p);
204 *symbol *= 2;
205 return 0;
206 @@ -191,9 +193,9 @@
207 }
209 /* Called once */
210 -static inline int INIT rc_direct_bit(struct rc *rc)
211 +static inline int INIT rc_direct_bit(struct rc *rc , void(*error)(char *x))
212 {
213 - rc_normalize(rc);
214 + rc_normalize(rc, error);
215 rc->range >>= 1;
216 if (rc->code >= rc->range) {
217 rc->code -= rc->range;
218 @@ -204,13 +206,14 @@
220 /* Called twice */
221 static inline void INIT
222 -rc_bit_tree_decode(struct rc *rc, uint16_t *p, int num_levels, int *symbol)
223 +rc_bit_tree_decode(struct rc *rc, uint16_t *p, int num_levels, int *symbol,
224 + void(*error)(char *x))
225 {
226 int i = num_levels;
228 *symbol = 1;
229 while (i--)
230 - rc_get_bit(rc, p + *symbol, symbol);
231 + rc_get_bit(rc, p + *symbol, symbol, error);
232 *symbol -= 1 << num_levels;
233 }
235 @@ -406,7 +409,8 @@
236 static inline void INIT process_bit0(struct writer *wr, struct rc *rc,
237 struct cstate *cst, uint16_t *p,
238 int pos_state, uint16_t *prob,
239 - int lc, uint32_t literal_pos_mask) {
240 + int lc, uint32_t literal_pos_mask,
241 + void(*error)(char *x)) {
242 int mi = 1;
243 static const int state[LZMA_NUM_STATES] =
244 { 0, 0, 0, 0, 1, 2, 3, 4, 5, 6, 4, 5 };
245 @@ -427,7 +431,7 @@
246 match_byte <<= 1;
247 bit = match_byte & 0x100;
248 prob_lit = prob + 0x100 + bit + mi;
249 - if (rc_get_bit(rc, prob_lit, &mi)) {
250 + if (rc_get_bit(rc, prob_lit, &mi, error)) {
251 if (!bit)
252 break;
253 } else {
254 @@ -438,7 +442,7 @@
255 }
256 while (mi < 0x100) {
257 uint16_t *prob_lit = prob + mi;
258 - rc_get_bit(rc, prob_lit, &mi);
259 + rc_get_bit(rc, prob_lit, &mi, error);
260 }
261 write_byte(wr, mi);
262 cst->state = state[cst->state];
263 @@ -446,7 +453,8 @@
265 static inline void INIT process_bit1(struct writer *wr, struct rc *rc,
266 struct cstate *cst, uint16_t *p,
267 - int pos_state, uint16_t *prob) {
268 + int pos_state, uint16_t *prob,
269 + void(*error)(char *x)) {
270 int offset;
271 uint16_t *prob_len;
272 int num_bits;
273 @@ -454,7 +459,7 @@
275 rc_update_bit_1(rc, prob);
276 prob = p + LZMA_IS_REP + cst->state;
277 - if (rc_is_bit_0(rc, prob)) {
278 + if (rc_is_bit_0(rc, prob, error)) {
279 rc_update_bit_0(rc, prob);
280 cst->rep3 = cst->rep2;
281 cst->rep2 = cst->rep1;
282 @@ -464,13 +469,13 @@
283 } else {
284 rc_update_bit_1(rc, prob);
285 prob += LZMA_IS_REP_G0 - LZMA_IS_REP;
286 - if (rc_is_bit_0(rc, prob)) {
287 + if (rc_is_bit_0(rc, prob, error)) {
288 rc_update_bit_0(rc, prob);
289 prob = (p + LZMA_IS_REP_0_LONG
290 + (cst->state <<
291 LZMA_NUM_POS_BITS_MAX) +
292 pos_state);
293 - if (rc_is_bit_0(rc, prob)) {
294 + if (rc_is_bit_0(rc, prob, error)) {
295 rc_update_bit_0(rc, prob);
297 cst->state = cst->state < LZMA_NUM_LIT_STATES ?
298 @@ -485,13 +490,13 @@
300 rc_update_bit_1(rc, prob);
301 prob += LZMA_IS_REP_G1 - LZMA_IS_REP_G0;
302 - if (rc_is_bit_0(rc, prob)) {
303 + if (rc_is_bit_0(rc, prob, error)) {
304 rc_update_bit_0(rc, prob);
305 distance = cst->rep1;
306 } else {
307 rc_update_bit_1(rc, prob);
308 prob += LZMA_IS_REP_G2 - LZMA_IS_REP_G1;
309 - if (rc_is_bit_0(rc, prob)) {
310 + if (rc_is_bit_0(rc, prob, error)) {
311 rc_update_bit_0(rc, prob);
312 distance = cst->rep2;
313 } else {
314 @@ -509,7 +514,7 @@
315 }
317 prob_len = prob + LZMA_LEN_CHOICE;
318 - if (rc_is_bit_0(rc, prob_len)) {
319 + if (rc_is_bit_0(rc, prob_len, error)) {
320 rc_update_bit_0(rc, prob_len);
321 prob_len += LZMA_LEN_LOW - LZMA_LEN_CHOICE
322 + (pos_state <<
323 @@ -519,7 +524,7 @@
324 } else {
325 rc_update_bit_1(rc, prob_len);
326 prob_len += LZMA_LEN_CHOICE_2 - LZMA_LEN_CHOICE;
327 - if (rc_is_bit_0(rc, prob_len)) {
328 + if (rc_is_bit_0(rc, prob_len, error)) {
329 rc_update_bit_0(rc, prob_len);
330 prob_len += LZMA_LEN_MID - LZMA_LEN_CHOICE_2
331 + (pos_state <<
332 @@ -535,7 +540,7 @@
333 }
334 }
336 - rc_bit_tree_decode(rc, prob_len, num_bits, &len);
337 + rc_bit_tree_decode(rc, prob_len, num_bits, &len, error);
338 len += offset;
340 if (cst->state < 4) {
341 @@ -550,7 +555,7 @@
342 << LZMA_NUM_POS_SLOT_BITS);
343 rc_bit_tree_decode(rc, prob,
344 LZMA_NUM_POS_SLOT_BITS,
345 - &pos_slot);
346 + &pos_slot, error);
347 if (pos_slot >= LZMA_START_POS_MODEL_INDEX) {
348 int i, mi;
349 num_bits = (pos_slot >> 1) - 1;
350 @@ -563,7 +568,7 @@
351 num_bits -= LZMA_NUM_ALIGN_BITS;
352 while (num_bits--)
353 cst->rep0 = (cst->rep0 << 1) |
354 - rc_direct_bit(rc);
355 + rc_direct_bit(rc, error);
356 prob = p + LZMA_ALIGN;
357 cst->rep0 <<= LZMA_NUM_ALIGN_BITS;
358 num_bits = LZMA_NUM_ALIGN_BITS;
359 @@ -571,7 +576,7 @@
360 i = 1;
361 mi = 1;
362 while (num_bits--) {
363 - if (rc_get_bit(rc, prob + mi, &mi))
364 + if (rc_get_bit(rc, prob + mi, &mi, error))
365 cst->rep0 |= i;
366 i <<= 1;
367 }
368 @@ -588,12 +593,12 @@
372 -STATIC inline int INIT unlzma(unsigned char *buf, int in_len,
373 +STATIC int INIT unlzma(unsigned char *buf, int in_len,
374 int(*fill)(void*, unsigned int),
375 int(*flush)(void*, unsigned int),
376 unsigned char *output,
377 int *posp,
378 - void(*error_fn)(char *x)
379 + void(*error)(char *x)
380 )
381 {
382 extern int cpio_flush_buffer(void*, unsigned int);
383 @@ -610,7 +615,6 @@
384 unsigned char *inbuf;
385 int ret = -1;
387 - set_error_fn(error_fn);
389 if (buf)
390 inbuf = buf;
391 @@ -638,7 +642,7 @@
393 for (i = 0; i < sizeof(header); i++) {
394 if (rc.ptr >= rc.buffer_end)
395 - rc_read(&rc);
396 + rc_read(&rc, error);
397 ((unsigned char *)&header)[i] = *rc.ptr++;
398 }
400 @@ -683,17 +687,17 @@
401 for (i = 0; i < num_probs; i++)
402 p[i] = (1 << RC_MODEL_TOTAL_BITS) >> 1;
403 wr.max_index = wr.next_index = 0;
404 - rc_init_code(&rc);
405 + rc_init_code(&rc, error);
407 while (get_pos(&wr) < header.dst_size) {
408 int pos_state = get_pos(&wr) & pos_state_mask;
409 uint16_t *prob = p + LZMA_IS_MATCH +
410 (cst.state << LZMA_NUM_POS_BITS_MAX) + pos_state;
411 - if (rc_is_bit_0(&rc, prob))
412 + if (rc_is_bit_0(&rc, prob, error))
413 process_bit0(&wr, &rc, &cst, p, pos_state, prob,
414 - lc, literal_pos_mask);
415 + lc, literal_pos_mask, error);
416 else {
417 - process_bit1(&wr, &rc, &cst, p, pos_state, prob);
418 + process_bit1(&wr, &rc, &cst, p, pos_state, prob, error);
419 if (cst.rep0 == 0)
420 break;
421 }
422 @@ -727,6 +731,9 @@
423 exit_0:
424 return ret;
425 }
426 +#if defined(CONFIG_DECOMPRESS_LZMA_NEEDED) && !defined(PREBOOT)
427 +EXPORT_SYMBOL(unlzma);
428 +#endif
430 #ifdef PREBOOT
431 STATIC int INIT decompress(unsigned char *buf, int in_len,
433 --- linux-2.6.34/fs/squashfs/Kconfig
434 +++ linux-2.6.34/fs/squashfs/Kconfig
435 @@ -26,6 +26,12 @@
437 If unsure, say N.
439 +config SQUASHFS_LZMA
440 + bool "Include support for LZMA compressed file systems"
441 + depends on SQUASHFS
442 + select DECOMPRESS_LZMA
443 + select DECOMPRESS_LZMA_NEEDED
444 +
445 config SQUASHFS_EMBEDDED
447 bool "Additional option for memory-constrained systems"
449 --- linux-2.6.34/fs/squashfs/Makefile
450 +++ linux-2.6.34/fs/squashfs/Makefile
451 @@ -5,3 +5,4 @@
452 obj-$(CONFIG_SQUASHFS) += squashfs.o
453 squashfs-y += block.o cache.o dir.o export.o file.o fragment.o id.o inode.o
454 squashfs-y += namei.o super.o symlink.o zlib_wrapper.o decompressor.o
455 +squashfs-$(CONFIG_SQUASHFS_LZMA) += lzma_wrapper.o
457 --- linux-2.6.34/fs/squashfs/decompressor.c
458 +++ linux-2.6.34/fs/squashfs/decompressor.c
459 @@ -50,7 +50,11 @@
461 static const struct squashfs_decompressor *decompressor[] = {
462 &squashfs_zlib_comp_ops,
463 +#ifdef CONFIG_SQUASHFS_LZMA
464 + &squashfs_lzma_comp_ops,
465 +#else
466 &squashfs_lzma_unsupported_comp_ops,
467 +#endif
468 &squashfs_lzo_unsupported_comp_ops,
469 &squashfs_unknown_comp_ops
470 };
472 --- linux-2.6.34/fs/squashfs/lzma_wrapper.c
473 +++ linux-2.6.34/fs/squashfs/lzma_wrapper.c
474 @@ -0,0 +1,152 @@
475 +/*
476 + * Squashfs - a compressed read only filesystem for Linux
477 + *
478 + * Copyright (c) 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009
479 + * Phillip Lougher <phillip@lougher.demon.co.uk>
480 + *
481 + * This program is free software; you can redistribute it and/or
482 + * modify it under the terms of the GNU General Public License
483 + * as published by the Free Software Foundation; either version 2,
484 + * or (at your option) any later version.
485 + *
486 + * This program is distributed in the hope that it will be useful,
487 + * but WITHOUT ANY WARRANTY; without even the implied warranty of
488 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
489 + * GNU General Public License for more details.
490 + *
491 + * You should have received a copy of the GNU General Public License
492 + * along with this program; if not, write to the Free Software
493 + * Foundation, 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
494 + *
495 + * lzma_wrapper.c
496 + */
497 +
498 +#include <asm/unaligned.h>
499 +#include <linux/slab.h>
500 +#include <linux/buffer_head.h>
501 +#include <linux/mutex.h>
502 +#include <linux/vmalloc.h>
503 +#include <linux/decompress/unlzma.h>
504 +
505 +#include "squashfs_fs.h"
506 +#include "squashfs_fs_sb.h"
507 +#include "squashfs_fs_i.h"
508 +#include "squashfs.h"
509 +#include "decompressor.h"
510 +
511 +struct squashfs_lzma {
512 + void *input;
513 + void *output;
514 +};
515 +
516 +/* decompress_unlzma.c is currently non re-entrant... */
517 +DEFINE_MUTEX(lzma_mutex);
518 +
519 +/* decompress_unlzma.c doesn't provide any context in its callbacks... */
520 +static int lzma_error;
521 +
522 +static void error(char *m)
523 +{
524 + ERROR("unlzma error: %s\n", m);
525 + lzma_error = 1;
526 +}
527 +
528 +
529 +static void *lzma_init(struct squashfs_sb_info *msblk)
530 +{
531 + struct squashfs_lzma *stream = kzalloc(sizeof(*stream), GFP_KERNEL);
532 + if (stream == NULL)
533 + goto failed;
534 + stream->input = vmalloc(msblk->block_size);
535 + if (stream->input == NULL)
536 + goto failed;
537 + stream->output = vmalloc(msblk->block_size);
538 + if (stream->output == NULL)
539 + goto failed2;
540 +
541 + return stream;
542 +
543 +failed2:
544 + vfree(stream->input);
545 +failed:
546 + ERROR("failed to allocate lzma workspace\n");
547 + kfree(stream);
548 + return NULL;
549 +}
550 +
551 +
552 +static void lzma_free(void *strm)
553 +{
554 + struct squashfs_lzma *stream = strm;
555 +
556 + if (stream) {
557 + vfree(stream->input);
558 + vfree(stream->output);
559 + }
560 + kfree(stream);
561 +}
562 +
563 +
564 +static int lzma_uncompress(struct squashfs_sb_info *msblk, void **buffer,
565 + struct buffer_head **bh, int b, int offset, int length, int srclength,
566 + int pages)
567 +{
568 + struct squashfs_lzma *stream = msblk->stream;
569 + void *buff = stream->input;
570 + int avail, i, bytes = length, res;
571 +
572 + mutex_lock(&lzma_mutex);
573 +
574 + for (i = 0; i < b; i++) {
575 + wait_on_buffer(bh[i]);
576 + if (!buffer_uptodate(bh[i]))
577 + goto block_release;
578 +
579 + avail = min(bytes, msblk->devblksize - offset);
580 + memcpy(buff, bh[i]->b_data + offset, avail);
581 + buff += avail;
582 + bytes -= avail;
583 + offset = 0;
584 + put_bh(bh[i]);
585 + }
586 +
587 + lzma_error = 0;
588 + res = unlzma(stream->input, length, NULL, NULL, stream->output, NULL,
589 + error);
590 + if (res || lzma_error)
591 + goto failed;
592 +
593 + /* uncompressed size is stored in the LZMA header (5 byte offset) */
594 + res = bytes = get_unaligned_le32(stream->input + 5);
595 + for (i = 0, buff = stream->output; bytes && i < pages; i++) {
596 + avail = min_t(int, bytes, PAGE_CACHE_SIZE);
597 + memcpy(buffer[i], buff, avail);
598 + buff += avail;
599 + bytes -= avail;
600 + }
601 + if (bytes)
602 + goto failed;
603 +
604 + mutex_unlock(&lzma_mutex);
605 + return res;
606 +
607 +block_release:
608 + for (; i < b; i++)
609 + put_bh(bh[i]);
610 +
611 +failed:
612 + mutex_unlock(&lzma_mutex);
613 +
614 + ERROR("lzma decompression failed, data probably corrupt\n");
615 + return -EIO;
616 +}
617 +
618 +const struct squashfs_decompressor squashfs_lzma_comp_ops = {
619 + .init = lzma_init,
620 + .free = lzma_free,
621 + .decompress = lzma_uncompress,
622 + .id = LZMA_COMPRESSION,
623 + .name = "lzma",
624 + .supported = 1
625 +};
626 +
628 --- linux-2.6.34/fs/squashfs/squashfs.h
629 +++ linux-2.6.34/fs/squashfs/squashfs.h
630 @@ -94,3 +94,6 @@
632 /* zlib_wrapper.c */
633 extern const struct squashfs_decompressor squashfs_zlib_comp_ops;
634 +
635 +/* lzma wrapper.c */
636 +extern const struct squashfs_decompressor squashfs_lzma_comp_ops;
638 --- linux-2.6.34/lib/Makefile
639 +++ linux-2.6.34/lib/Makefile
640 @@ -69,7 +69,7 @@ obj-$(CONFIG_LZO_DECOMPRESS) += lzo/
642 lib-$(CONFIG_DECOMPRESS_GZIP) += decompress_inflate.o
643 lib-$(CONFIG_DECOMPRESS_BZIP2) += decompress_bunzip2.o
644 -lib-$(CONFIG_DECOMPRESS_LZMA) += decompress_unlzma.o
645 +obj-$(CONFIG_DECOMPRESS_LZMA) += decompress_unlzma.o
646 lib-$(CONFIG_DECOMPRESS_LZO) += decompress_unlzo.o
648 obj-$(CONFIG_TEXTSEARCH) += textsearch.o