diff options
author | Yoshinori Sato <ysato@users.sourceforge.jp> | 2008-07-03 23:54:51 -0400 |
---|---|---|
committer | Paul Mundt <lethal@linux-sh.org> | 2008-07-28 05:10:33 -0400 |
commit | f12ae6bc4ad0054386b380dbf90e63617cd5ab92 (patch) | |
tree | 51efc329cb0559547ec4ece96dd5d684a8404a73 /arch/sh/boot | |
parent | f2fb4e4f647dabf1177d3ce164988e73482d76b1 (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>
Diffstat (limited to 'arch/sh/boot')
-rw-r--r-- | arch/sh/boot/compressed/Makefile_32 | 5 | ||||
-rw-r--r-- | arch/sh/boot/compressed/Makefile_64 | 5 | ||||
-rw-r--r-- | arch/sh/boot/compressed/piggy.S | 8 | ||||
-rw-r--r-- | arch/sh/boot/compressed/vmlinux.scr | 9 |
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 | ||
38 | LDFLAGS_piggy.o := -r --format binary --oformat elf32-sh-linux -T | ||
39 | OBJCOPYFLAGS += -R .empty_zero_page | 38 | OBJCOPYFLAGS += -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 | ||
40 | LDFLAGS_piggy.o := -r --format binary --oformat elf32-sh64-linux -T | ||
41 | OBJCOPYFLAGS += -R .empty_zero_page | 40 | OBJCOPYFLAGS += -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 | ||
3 | input_len: | ||
4 | .long input_data_end - input_data | ||
5 | input_data: | ||
6 | .incbin "arch/sh/boot/compressed/vmlinux.bin.gz" | ||
7 | input_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 @@ | |||
1 | SECTIONS | ||
2 | { | ||
3 | .data : { | ||
4 | input_len = .; | ||
5 | LONG(input_data_end - input_data) input_data = .; | ||
6 | *(.data) | ||
7 | input_data_end = .; | ||
8 | } | ||
9 | } | ||