aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sparc/boot/Makefile
diff options
context:
space:
mode:
authorSam Ravnborg <sam@ravnborg.org>2011-01-04 06:39:16 -0500
committerDavid S. Miller <davem@davemloft.net>2011-01-04 22:25:06 -0500
commit1075c4ef707ca83afbeb0950094436eb0245ec86 (patch)
tree4634a2876305271ab09d0fed2e7f3ff5080a22b2 /arch/sparc/boot/Makefile
parenta020bb17b7046cd97ea6924ca99325b6e516bc2d (diff)
sparc: fix tftpboot.img for sparc64 on little-endian host
piggyback_32 adapted to support sparc64: - locating "HdrS" differs for sparc and sparc64 - sparc64 updates a_text, a_data + a_bss in the final a.out header Updated Makefile to use piggyback_32 for sparc64. Deleted the now unused piggyback_64.c piggyback_32.c is host endian neutral and works on both little-endian and big-endian hosts. This fixes a long standing bug where sparc64 could not generate tftpboot.img on a x86 host. Signed-off-by: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc/boot/Makefile')
-rw-r--r--arch/sparc/boot/Makefile6
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/sparc/boot/Makefile b/arch/sparc/boot/Makefile
index 4c81fe59ab58..06a79a2018de 100644
--- a/arch/sparc/boot/Makefile
+++ b/arch/sparc/boot/Makefile
@@ -6,7 +6,7 @@
6ROOT_IMG := /usr/src/root.img 6ROOT_IMG := /usr/src/root.img
7ELFTOAOUT := elftoaout 7ELFTOAOUT := elftoaout
8 8
9hostprogs-y := piggyback_32 piggyback_64 btfixupprep 9hostprogs-y := piggyback_32 btfixupprep
10targets := tftpboot.img btfix.o btfix.S image zImage vmlinux.aout 10targets := tftpboot.img btfix.o btfix.S image zImage vmlinux.aout
11clean-files := System.map 11clean-files := System.map
12 12
@@ -69,7 +69,7 @@ endif
69 69
70ifeq ($(CONFIG_SPARC64),y) 70ifeq ($(CONFIG_SPARC64),y)
71quiet_cmd_piggy = PIGGY $@ 71quiet_cmd_piggy = PIGGY $@
72 cmd_piggy = $(obj)/piggyback_64 $@ System.map $(ROOT_IMG) 72 cmd_piggy = $(obj)/piggyback_32 $(BITS) $@ System.map $(ROOT_IMG)
73quiet_cmd_strip = STRIP $@ 73quiet_cmd_strip = STRIP $@
74 cmd_strip = $(STRIP) -R .comment -R .note -K sun4u_init -K _end -K _start vmlinux -o $@ 74 cmd_strip = $(STRIP) -R .comment -R .note -K sun4u_init -K _end -K _start vmlinux -o $@
75 75
@@ -82,7 +82,7 @@ $(obj)/image: vmlinux FORCE
82$(obj)/zImage: $(obj)/image 82$(obj)/zImage: $(obj)/image
83 $(call if_changed,gzip) 83 $(call if_changed,gzip)
84 84
85$(obj)/tftpboot.img: $(obj)/image $(obj)/piggyback_64 System.map $(ROOT_IMG) FORCE 85$(obj)/tftpboot.img: $(obj)/image $(obj)/piggyback_32 System.map $(ROOT_IMG) FORCE
86 $(call if_changed,elftoaout) 86 $(call if_changed,elftoaout)
87 $(call if_changed,piggy) 87 $(call if_changed,piggy)
88 @echo ' kernel: $@ is ready' 88 @echo ' kernel: $@ is ready'