summaryrefslogtreecommitdiff
path: root/target/linux/rdc/patches/600-x86_lzma.patch
diff options
context:
space:
mode:
Diffstat (limited to 'target/linux/rdc/patches/600-x86_lzma.patch')
-rw-r--r--target/linux/rdc/patches/600-x86_lzma.patch86
1 files changed, 44 insertions, 42 deletions
diff --git a/target/linux/rdc/patches/600-x86_lzma.patch b/target/linux/rdc/patches/600-x86_lzma.patch
index bb10f1f..292ec88 100644
--- a/target/linux/rdc/patches/600-x86_lzma.patch
+++ b/target/linux/rdc/patches/600-x86_lzma.patch
@@ -1,6 +1,6 @@
-diff -Naur linux-old/arch/i386/boot/compressed/LzmaDecode.c linux-lzma/arch/i386/boot/compressed/LzmaDecode.c
---- linux-old/arch/i386/boot/compressed/LzmaDecode.c 1969-12-31 19:00:00.000000000 -0500
-+++ linux-lzma/arch/i386/boot/compressed/LzmaDecode.c 2005-06-05 00:07:38.000000000 -0400
+diff -Naur linux-old/arch/x86/boot/compressed/LzmaDecode.c linux-lzma/arch/i386/boot/compressed/LzmaDecode.c
+--- linux-old/arch/x86/boot/compressed/LzmaDecode.c 1969-12-31 19:00:00.000000000 -0500
++++ linux-lzma/arch/x86/boot/compressed/LzmaDecode.c 2005-06-05 00:07:38.000000000 -0400
@@ -0,0 +1,586 @@
+/*
+ LzmaDecode.c
@@ -588,9 +588,9 @@ diff -Naur linux-old/arch/i386/boot/compressed/LzmaDecode.c linux-lzma/arch/i386
+ *outSizeProcessed = nowPos;
+ return LZMA_RESULT_OK;
+}
-diff -Naur linux-old/arch/i386/boot/compressed/LzmaDecode.h linux-lzma/arch/i386/boot/compressed/LzmaDecode.h
---- linux-old/arch/i386/boot/compressed/LzmaDecode.h 1969-12-31 19:00:00.000000000 -0500
-+++ linux-lzma/arch/i386/boot/compressed/LzmaDecode.h 2005-06-05 00:07:39.000000000 -0400
+diff -Naur linux-old/arch/x86/boot/compressed/LzmaDecode.h linux-lzma/arch/i386/boot/compressed/LzmaDecode.h
+--- linux-old/arch/x86/boot/compressed/LzmaDecode.h 1969-12-31 19:00:00.000000000 -0500
++++ linux-lzma/arch/x86/boot/compressed/LzmaDecode.h 2005-06-05 00:07:39.000000000 -0400
@@ -0,0 +1,100 @@
+/*
+ LzmaDecode.h
@@ -692,9 +692,9 @@ diff -Naur linux-old/arch/i386/boot/compressed/LzmaDecode.h linux-lzma/arch/i386
+ UInt32 *outSizeProcessed);
+
+#endif
-diff -Naur linux-old/arch/i386/boot/compressed/lzma_misc.c linux-lzma/arch/i386/boot/compressed/lzma_misc.c
---- linux-old/arch/i386/boot/compressed/lzma_misc.c 1969-12-31 19:00:00.000000000 -0500
-+++ linux-lzma/arch/i386/boot/compressed/lzma_misc.c 2005-06-04 21:33:48.000000000 -0400
+diff -Naur linux-old/arch/x86/boot/compressed/lzma_misc.c linux-lzma/arch/i386/boot/compressed/lzma_misc.c
+--- linux-old/arch/x86/boot/compressed/lzma_misc.c 1969-12-31 19:00:00.000000000 -0500
++++ linux-lzma/arch/x86/boot/compressed/lzma_misc.c 2005-06-04 21:33:48.000000000 -0400
@@ -0,0 +1,281 @@
+/*
+ * lzma_misc.c
@@ -977,24 +977,48 @@ diff -Naur linux-old/arch/i386/boot/compressed/lzma_misc.c linux-lzma/arch/i386/
+ lzma_unzip();
+ return;
+}
-diff -Naur linux-old/arch/i386/boot/compressed/Makefile linux-lzma/arch/i386/boot/compressed/Makefile
---- linux-old/arch/i386/boot/compressed/Makefile 2005-06-04 21:53:40.000000000 -0400
-+++ linux-lzma/arch/i386/boot/compressed/Makefile 2005-06-05 00:25:23.000000000 -0400
-@@ -4,7 +4,7 @@
+diff -urN linux-2.6.19.2/scripts/Makefile.lib linux-2.6.19.2.new/scripts/Makefile.lib
+--- linux-2.6.19.2/scripts/Makefile.lib 2007-01-10 20:10:37.000000000 +0100
++++ linux-2.6.19.2.new/scripts/Makefile.lib 2007-04-15 23:51:54.000000000 +0200
+@@ -162,4 +162,9 @@
+ quiet_cmd_gzip = GZIP $@
+ cmd_gzip = gzip -f -9 < $< > $@
+
+-
++# LZMA
++#
++quiet_cmd_lzma = LZMA $@
++cmd_lzma = bash -e scripts/lzma_kern $< $@ -lc7 -lp0 -pb0
++# to use lzmacomp,
++# cmd_lzma = lzmacomp $< 700 > $@
+diff -u linux/scripts/lzma_kern linux/scripts/lzma_kern
+--- linux/scripts/lzma_kern 2007-07-27 20:18:17.013014750 -0700
++++ linux/scripts/lzma_kern 2007-07-27 20:18:17.013014750 -0700
+@@ -0,0 +1,4 @@
++get-size() { echo "$5" ;}
++printf -v len '%.8x' "$(get-size $(ls -l "$1"))"
++lzma e "$@"
++echo -ne "\x$(echo $len | cut -c 7,8)\x$(echo $len | cut -c 5,6)\x$(echo $len | cut -c 3,4)\x$(echo $len | cut -c 1,2)" >> "$2"
+diff -urN linux-2.6.24/arch/x86/boot/compressed/Makefile_32 linux-2.6.24.new/arch/x86/boot/compressed/Makefile_32
+--- linux-2.6.24/arch/x86/boot/compressed/Makefile_32 2008-01-24 23:58:37.000000000 +0100
++++ linux-2.6.24.new/arch/x86/boot/compressed/Makefile_32 2008-02-13 15:21:03.000000000 +0100
+@@ -4,8 +4,8 @@
# create a compressed vmlinux image from the original vmlinux
#
--targets := vmlinux vmlinux.bin vmlinux.bin.gz head.o misc.o piggy.o \
-+targets := vmlinux vmlinux.bin vmlinux.bin.lzma head.o lzma_misc.o piggy.o \
- vmlinux.bin.all vmlinux.relocs
+-targets := vmlinux vmlinux.bin vmlinux.bin.gz head_32.o misc_32.o piggy.o \
+- vmlinux.bin.all vmlinux.relocs
++targets := vmlinux vmlinux.bin vmlinux.bin.lzma head_32.o piggy.o \
++ vmlinux.bin.all vmlinux.relocs lzma_misc.o
EXTRA_AFLAGS := -traditional
+ LDFLAGS_vmlinux := -T
@@ -17,7 +17,7 @@
$(call cc-option,-fno-stack-protector)
LDFLAGS := -m elf_i386
--$(obj)/vmlinux: $(src)/vmlinux.lds $(obj)/head.o $(obj)/misc.o $(obj)/piggy.o FORCE
-+$(obj)/vmlinux: $(src)/vmlinux.lds $(obj)/head.o $(obj)/lzma_misc.o $(obj)/piggy.o FORCE
+-$(obj)/vmlinux: $(src)/vmlinux_32.lds $(obj)/head_32.o $(obj)/misc_32.o $(obj)/piggy.o FORCE
++$(obj)/vmlinux: $(src)/vmlinux_32.lds $(obj)/head_32.o $(obj)/lzma_misc.o $(obj)/piggy.o FORCE
$(call if_changed,ld)
@:
@@ -1015,28 +1039,6 @@ diff -Naur linux-old/arch/i386/boot/compressed/Makefile linux-lzma/arch/i386/boo
LDFLAGS_piggy.o := -r --format binary --oformat elf32-i386 -T
--$(obj)/piggy.o: $(src)/vmlinux.scr $(obj)/vmlinux.bin.gz FORCE
-+$(obj)/piggy.o: $(src)/vmlinux.scr $(obj)/vmlinux.bin.lzma FORCE
+-$(obj)/piggy.o: $(src)/vmlinux_32.scr $(obj)/vmlinux.bin.gz FORCE
++$(obj)/piggy.o: $(src)/vmlinux_32.scr $(obj)/vmlinux.bin.lzma FORCE
$(call if_changed,ld)
-diff -urN linux-2.6.19.2/scripts/Makefile.lib linux-2.6.19.2.new/scripts/Makefile.lib
---- linux-2.6.19.2/scripts/Makefile.lib 2007-01-10 20:10:37.000000000 +0100
-+++ linux-2.6.19.2.new/scripts/Makefile.lib 2007-04-15 23:51:54.000000000 +0200
-@@ -162,4 +162,9 @@
- quiet_cmd_gzip = GZIP $@
- cmd_gzip = gzip -f -9 < $< > $@
-
--
-+# LZMA
-+#
-+quiet_cmd_lzma = LZMA $@
-+cmd_lzma = bash -e scripts/lzma_kern $< $@ -lc7 -lp0 -pb0
-+# to use lzmacomp,
-+# cmd_lzma = lzmacomp $< 700 > $@
-diff -u linux/scripts/lzma_kern linux/scripts/lzma_kern
---- linux/scripts/lzma_kern 2007-07-27 20:18:17.013014750 -0700
-+++ linux/scripts/lzma_kern 2007-07-27 20:18:17.013014750 -0700
-@@ -0,0 +1,4 @@
-+get-size() { echo "$5" ;}
-+printf -v len '%.8x' "$(get-size $(ls -l "$1"))"
-+lzma e "$@"
-+echo -ne "\x$(echo $len | cut -c 7,8)\x$(echo $len | cut -c 5,6)\x$(echo $len | cut -c 3,4)\x$(echo $len | cut -c 1,2)" >> "$2"