aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYoshinori Sato <ysato@users.sourceforge.jp>2015-12-03 11:20:57 -0500
committerYoshinori Sato <ysato@users.sourceforge.jp>2016-01-20 08:44:13 -0500
commit42b510eb56dea96150dfc0747d4b2486b7fa72e0 (patch)
tree8cc7bc1563f92a9df95abb0a35a91488c0d6a326
parentaf3da5798d7b9d3dc7412cb5e1d4ed106dcecefc (diff)
h8300: Add LZO compression
Signed-off-by: Yoshinori Sato <ysato@users.sourceforge.jp>
-rw-r--r--arch/h8300/Kconfig2
-rw-r--r--arch/h8300/boot/compressed/Makefile11
-rw-r--r--arch/h8300/boot/compressed/misc.c6
3 files changed, 16 insertions, 3 deletions
diff --git a/arch/h8300/Kconfig b/arch/h8300/Kconfig
index 2e20333cbce9..3084e58b4610 100644
--- a/arch/h8300/Kconfig
+++ b/arch/h8300/Kconfig
@@ -18,6 +18,8 @@ config H8300
18 select HAVE_DMA_ATTRS 18 select HAVE_DMA_ATTRS
19 select CLKSRC_OF 19 select CLKSRC_OF
20 select H8300_TMR8 20 select H8300_TMR8
21 select HAVE_KERNEL_GZIP
22 select HAVE_KERNEL_LZO
21 23
22config RWSEM_GENERIC_SPINLOCK 24config RWSEM_GENERIC_SPINLOCK
23 def_bool y 25 def_bool y
diff --git a/arch/h8300/boot/compressed/Makefile b/arch/h8300/boot/compressed/Makefile
index d7bc3fa7f2c6..7643633f1330 100644
--- a/arch/h8300/boot/compressed/Makefile
+++ b/arch/h8300/boot/compressed/Makefile
@@ -28,11 +28,16 @@ $(obj)/vmlinux: $(OBJECTS) $(obj)/piggy.o $(LIBGCC) FORCE
28$(obj)/vmlinux.bin: vmlinux FORCE 28$(obj)/vmlinux.bin: vmlinux FORCE
29 $(call if_changed,objcopy) 29 $(call if_changed,objcopy)
30 30
31$(obj)/vmlinux.bin.gz: $(obj)/vmlinux.bin FORCE 31suffix-$(CONFIG_KERNEL_GZIP) := gzip
32 $(call if_changed,gzip) 32suffix-$(CONFIG_KERNEL_LZO) := lzo
33
34$(obj)/vmlinux.bin.$(suffix-y): $(obj)/vmlinux.bin FORCE
35 $(call if_changed,$(suffix-y))
33 36
34LDFLAGS_piggy.o := -r --format binary --oformat elf32-h8300-linux -T 37LDFLAGS_piggy.o := -r --format binary --oformat elf32-h8300-linux -T
35OBJCOPYFLAGS := -O binary 38OBJCOPYFLAGS := -O binary
36 39
37$(obj)/piggy.o: $(obj)/vmlinux.scr $(obj)/vmlinux.bin.gz FORCE 40$(obj)/piggy.o: $(obj)/vmlinux.scr $(obj)/vmlinux.bin.$(suffix-y) FORCE
38 $(call if_changed,ld) 41 $(call if_changed,ld)
42
43CFLAGS_misc.o = -O0
diff --git a/arch/h8300/boot/compressed/misc.c b/arch/h8300/boot/compressed/misc.c
index 6029c5351895..9f64fe8f29ff 100644
--- a/arch/h8300/boot/compressed/misc.c
+++ b/arch/h8300/boot/compressed/misc.c
@@ -32,7 +32,13 @@ extern char output[];
32 32
33#define HEAP_SIZE 0x10000 33#define HEAP_SIZE 0x10000
34 34
35#ifdef CONFIG_KERNEL_GZIP
35#include "../../../../lib/decompress_inflate.c" 36#include "../../../../lib/decompress_inflate.c"
37#endif
38
39#ifdef CONFIG_KERNEL_LZO
40#include "../../../../lib/decompress_unlzo.c"
41#endif
36 42
37void *memset(void *s, int c, size_t n) 43void *memset(void *s, int c, size_t n)
38{ 44{