aboutsummaryrefslogtreecommitdiffstats
path: root/arch/s390
diff options
context:
space:
mode:
authorHeiko Carstens <heiko.carstens@de.ibm.com>2011-03-15 12:08:32 -0400
committerMartin Schwidefsky <sky@mschwide.boeblingen.de.ibm.com>2011-03-15 12:08:24 -0400
commitd7b081ac0b8eee5f2a58123235061ee1b99a4f4d (patch)
treea1deecb029e2a511112e2364e6878bf843d9773c /arch/s390
parent3041b6ab5f36ac303981e9f170ff2ae43dc9d125 (diff)
[S390] support XZ compressed kernel
Add support for XZ compressed kernel. Same as on x86 and sh. Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'arch/s390')
-rw-r--r--arch/s390/Kconfig1
-rw-r--r--arch/s390/boot/compressed/Makefile6
-rw-r--r--arch/s390/boot/compressed/misc.c5
3 files changed, 11 insertions, 1 deletions
diff --git a/arch/s390/Kconfig b/arch/s390/Kconfig
index 271a02f821c0..2508a6f31588 100644
--- a/arch/s390/Kconfig
+++ b/arch/s390/Kconfig
@@ -85,6 +85,7 @@ config S390
85 select HAVE_KERNEL_BZIP2 85 select HAVE_KERNEL_BZIP2
86 select HAVE_KERNEL_LZMA 86 select HAVE_KERNEL_LZMA
87 select HAVE_KERNEL_LZO 87 select HAVE_KERNEL_LZO
88 select HAVE_KERNEL_XZ
88 select HAVE_GET_USER_PAGES_FAST 89 select HAVE_GET_USER_PAGES_FAST
89 select HAVE_ARCH_MUTEX_CPU_RELAX 90 select HAVE_ARCH_MUTEX_CPU_RELAX
90 select ARCH_INLINE_SPIN_TRYLOCK 91 select ARCH_INLINE_SPIN_TRYLOCK
diff --git a/arch/s390/boot/compressed/Makefile b/arch/s390/boot/compressed/Makefile
index 1c999f726a58..10e22c4ec4a7 100644
--- a/arch/s390/boot/compressed/Makefile
+++ b/arch/s390/boot/compressed/Makefile
@@ -7,7 +7,8 @@
7BITS := $(if $(CONFIG_64BIT),64,31) 7BITS := $(if $(CONFIG_64BIT),64,31)
8 8
9targets := vmlinux.lds vmlinux vmlinux.bin vmlinux.bin.gz vmlinux.bin.bz2 \ 9targets := vmlinux.lds vmlinux vmlinux.bin vmlinux.bin.gz vmlinux.bin.bz2 \
10 vmlinux.bin.lzma vmlinux.bin.lzo misc.o piggy.o sizes.h head$(BITS).o 10 vmlinux.bin.xz vmlinux.bin.lzma vmlinux.bin.lzo misc.o piggy.o \
11 sizes.h head$(BITS).o
11 12
12KBUILD_CFLAGS := -m$(BITS) -D__KERNEL__ $(LINUX_INCLUDE) -O2 13KBUILD_CFLAGS := -m$(BITS) -D__KERNEL__ $(LINUX_INCLUDE) -O2
13KBUILD_CFLAGS += $(cflags-y) 14KBUILD_CFLAGS += $(cflags-y)
@@ -48,6 +49,7 @@ suffix-$(CONFIG_KERNEL_GZIP) := gz
48suffix-$(CONFIG_KERNEL_BZIP2) := bz2 49suffix-$(CONFIG_KERNEL_BZIP2) := bz2
49suffix-$(CONFIG_KERNEL_LZMA) := lzma 50suffix-$(CONFIG_KERNEL_LZMA) := lzma
50suffix-$(CONFIG_KERNEL_LZO) := lzo 51suffix-$(CONFIG_KERNEL_LZO) := lzo
52suffix-$(CONFIG_KERNEL_XZ) := xz
51 53
52$(obj)/vmlinux.bin.gz: $(vmlinux.bin.all-y) 54$(obj)/vmlinux.bin.gz: $(vmlinux.bin.all-y)
53 $(call if_changed,gzip) 55 $(call if_changed,gzip)
@@ -57,6 +59,8 @@ $(obj)/vmlinux.bin.lzma: $(vmlinux.bin.all-y)
57 $(call if_changed,lzma) 59 $(call if_changed,lzma)
58$(obj)/vmlinux.bin.lzo: $(vmlinux.bin.all-y) 60$(obj)/vmlinux.bin.lzo: $(vmlinux.bin.all-y)
59 $(call if_changed,lzo) 61 $(call if_changed,lzo)
62$(obj)/vmlinux.bin.xz: $(vmlinux.bin.all-y)
63 $(call if_changed,xzkern)
60 64
61LDFLAGS_piggy.o := -r --format binary --oformat $(LD_BFD) -T 65LDFLAGS_piggy.o := -r --format binary --oformat $(LD_BFD) -T
62$(obj)/piggy.o: $(obj)/vmlinux.scr $(obj)/vmlinux.bin.$(suffix-y) 66$(obj)/piggy.o: $(obj)/vmlinux.scr $(obj)/vmlinux.bin.$(suffix-y)
diff --git a/arch/s390/boot/compressed/misc.c b/arch/s390/boot/compressed/misc.c
index 2751b3a8a66f..028f23ea81d1 100644
--- a/arch/s390/boot/compressed/misc.c
+++ b/arch/s390/boot/compressed/misc.c
@@ -19,6 +19,7 @@
19#undef memset 19#undef memset
20#undef memcpy 20#undef memcpy
21#undef memmove 21#undef memmove
22#define memmove memmove
22#define memzero(s, n) memset((s), 0, (n)) 23#define memzero(s, n) memset((s), 0, (n))
23 24
24/* Symbols defined by linker scripts */ 25/* Symbols defined by linker scripts */
@@ -54,6 +55,10 @@ static unsigned long free_mem_end_ptr;
54#include "../../../../lib/decompress_unlzo.c" 55#include "../../../../lib/decompress_unlzo.c"
55#endif 56#endif
56 57
58#ifdef CONFIG_KERNEL_XZ
59#include "../../../../lib/decompress_unxz.c"
60#endif
61
57extern _sclp_print_early(const char *); 62extern _sclp_print_early(const char *);
58 63
59int puts(const char *s) 64int puts(const char *s)