aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYoshinori Sato <ysato@users.sourceforge.jp>2008-07-03 23:54:51 -0400
committerPaul Mundt <lethal@linux-sh.org>2008-07-28 05:10:33 -0400
commitf12ae6bc4ad0054386b380dbf90e63617cd5ab92 (patch)
tree51efc329cb0559547ec4ece96dd5d684a8404a73
parentf2fb4e4f647dabf1177d3ce164988e73482d76b1 (diff)
sh: Fix up link error on SH-2 zImage with older binutils.
Signed-off-by: Yoshinori Sato <ysato@users.sourceforge.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
-rw-r--r--arch/sh/boot/compressed/Makefile_325
-rw-r--r--arch/sh/boot/compressed/Makefile_645
-rw-r--r--arch/sh/boot/compressed/piggy.S8
-rw-r--r--arch/sh/boot/compressed/vmlinux.scr9
4 files changed, 12 insertions, 15 deletions
diff --git a/arch/sh/boot/compressed/Makefile_32 b/arch/sh/boot/compressed/Makefile_32
index c0d25fb1aa60..47685f618ae7 100644
--- a/arch/sh/boot/compressed/Makefile_32
+++ b/arch/sh/boot/compressed/Makefile_32
@@ -35,8 +35,7 @@ $(obj)/vmlinux.bin: vmlinux FORCE
35$(obj)/vmlinux.bin.gz: $(obj)/vmlinux.bin FORCE 35$(obj)/vmlinux.bin.gz: $(obj)/vmlinux.bin FORCE
36 $(call if_changed,gzip) 36 $(call if_changed,gzip)
37 37
38LDFLAGS_piggy.o := -r --format binary --oformat elf32-sh-linux -T
39OBJCOPYFLAGS += -R .empty_zero_page 38OBJCOPYFLAGS += -R .empty_zero_page
40 39
41$(obj)/piggy.o: $(obj)/vmlinux.scr $(obj)/vmlinux.bin.gz FORCE 40$(obj)/piggy.o: $(obj)/piggy.S $(obj)/vmlinux.bin.gz FORCE
42 $(call if_changed,ld) 41 $(call if_changed,as_o_S)
diff --git a/arch/sh/boot/compressed/Makefile_64 b/arch/sh/boot/compressed/Makefile_64
index 912f3e205a0d..658d4f915556 100644
--- a/arch/sh/boot/compressed/Makefile_64
+++ b/arch/sh/boot/compressed/Makefile_64
@@ -37,8 +37,7 @@ $(obj)/vmlinux.bin: vmlinux FORCE
37$(obj)/vmlinux.bin.gz: $(obj)/vmlinux.bin FORCE 37$(obj)/vmlinux.bin.gz: $(obj)/vmlinux.bin FORCE
38 $(call if_changed,gzip) 38 $(call if_changed,gzip)
39 39
40LDFLAGS_piggy.o := -r --format binary --oformat elf32-sh64-linux -T
41OBJCOPYFLAGS += -R .empty_zero_page 40OBJCOPYFLAGS += -R .empty_zero_page
42 41
43$(obj)/piggy.o: $(obj)/vmlinux.scr $(obj)/vmlinux.bin.gz FORCE 42$(obj)/piggy.o: $(obj)/piggy.S $(obj)/vmlinux.bin.gz FORCE
44 $(call if_changed,ld) 43 $(call if_changed,as_o_S)
diff --git a/arch/sh/boot/compressed/piggy.S b/arch/sh/boot/compressed/piggy.S
new file mode 100644
index 000000000000..566071926b13
--- /dev/null
+++ b/arch/sh/boot/compressed/piggy.S
@@ -0,0 +1,8 @@
1 .global input_len, input_data
2 .data
3input_len:
4 .long input_data_end - input_data
5input_data:
6 .incbin "arch/sh/boot/compressed/vmlinux.bin.gz"
7input_data_end:
8 .end
diff --git a/arch/sh/boot/compressed/vmlinux.scr b/arch/sh/boot/compressed/vmlinux.scr
deleted file mode 100644
index 1ed9d791f863..000000000000
--- a/arch/sh/boot/compressed/vmlinux.scr
+++ /dev/null
@@ -1,9 +0,0 @@
1SECTIONS
2{
3 .data : {
4 input_len = .;
5 LONG(input_data_end - input_data) input_data = .;
6 *(.data)
7 input_data_end = .;
8 }
9}