diff options
author | Sam Ravnborg <sam@ravnborg.org> | 2008-12-03 06:14:26 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-12-04 12:17:21 -0500 |
commit | a8c601ca21e790f6a9d996bb0bf31f7496eb9509 (patch) | |
tree | 3a14a41ec3fc4b57ec9d195f2a4365a149c395bc | |
parent | a88b5ba8bd8ac18aad65ee6c6a254e2e74876db3 (diff) |
sparc,sparc64: unify boot/
Simple unification:
o renamed piggyback to *_32.c/*_64.c
o copied content of Makefile from sparc64 to sparc and guard it
o updated sparc/boot/.gitignore
o deleted remaining files in sparc64/boot
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | arch/sparc/Makefile | 9 | ||||
-rw-r--r-- | arch/sparc/boot/.gitignore | 3 | ||||
-rw-r--r-- | arch/sparc/boot/Makefile | 33 | ||||
-rw-r--r-- | arch/sparc/boot/piggyback_32.c (renamed from arch/sparc/boot/piggyback.c) | 0 | ||||
-rw-r--r-- | arch/sparc/boot/piggyback_64.c (renamed from arch/sparc64/boot/piggyback.c) | 0 | ||||
-rw-r--r-- | arch/sparc64/boot/.gitignore | 4 | ||||
-rw-r--r-- | arch/sparc64/boot/Makefile | 33 |
7 files changed, 37 insertions, 45 deletions
diff --git a/arch/sparc/Makefile b/arch/sparc/Makefile index 4b39ac68c3b1..efc90711f79d 100644 --- a/arch/sparc/Makefile +++ b/arch/sparc/Makefile | |||
@@ -89,17 +89,16 @@ ifdef CONFIG_KALLSYMS | |||
89 | export kallsyms.o := .tmp_kallsyms2.o | 89 | export kallsyms.o := .tmp_kallsyms2.o |
90 | endif | 90 | endif |
91 | 91 | ||
92 | boot-y := arch/sparc/boot | 92 | boot := arch/sparc/boot |
93 | boot-$(CONFIG_SPARC64) := arch/sparc64/boot | ||
94 | 93 | ||
95 | image zImage tftpboot.img vmlinux.aout: vmlinux | 94 | image zImage tftpboot.img vmlinux.aout: vmlinux |
96 | $(Q)$(MAKE) $(build)=$(boot-y) $(boot-y)/$@ | 95 | $(Q)$(MAKE) $(build)=$(boot) $(boot)/$@ |
97 | 96 | ||
98 | archclean: | 97 | archclean: |
99 | $(Q)$(MAKE) $(clean)=$(boot-y) | 98 | $(Q)$(MAKE) $(clean)=$(boot) |
100 | 99 | ||
101 | # This is the image used for packaging | 100 | # This is the image used for packaging |
102 | KBUILD_IMAGE := $(boot-y)/zImage | 101 | KBUILD_IMAGE := $(boot)/zImage |
103 | 102 | ||
104 | # Don't use tabs in echo arguments. | 103 | # Don't use tabs in echo arguments. |
105 | ifeq ($(ARCH),sparc) | 104 | ifeq ($(ARCH),sparc) |
diff --git a/arch/sparc/boot/.gitignore b/arch/sparc/boot/.gitignore index 8ffba5762be1..fc6f3986c76c 100644 --- a/arch/sparc/boot/.gitignore +++ b/arch/sparc/boot/.gitignore | |||
@@ -2,4 +2,7 @@ btfix.S | |||
2 | btfixupprep | 2 | btfixupprep |
3 | image | 3 | image |
4 | zImage | 4 | zImage |
5 | tftpboot.img | ||
6 | vmlinux.aout | ||
7 | piggyback | ||
5 | 8 | ||
diff --git a/arch/sparc/boot/Makefile b/arch/sparc/boot/Makefile index 06b653df820d..96041a8d39e8 100644 --- a/arch/sparc/boot/Makefile +++ b/arch/sparc/boot/Makefile | |||
@@ -6,14 +6,16 @@ | |||
6 | ROOT_IMG := /usr/src/root.img | 6 | ROOT_IMG := /usr/src/root.img |
7 | ELFTOAOUT := elftoaout | 7 | ELFTOAOUT := elftoaout |
8 | 8 | ||
9 | hostprogs-y := piggyback btfixupprep | 9 | hostprogs-y := piggyback_32 piggyback_64 btfixupprep |
10 | targets := tftpboot.img btfix.o btfix.S image zImage | 10 | targets := tftpboot.img btfix.o btfix.S image zImage vmlinux.aout |
11 | clean-files := System.map | 11 | clean-files := System.map |
12 | 12 | ||
13 | quiet_cmd_elftoaout = ELFTOAOUT $@ | 13 | quiet_cmd_elftoaout = ELFTOAOUT $@ |
14 | cmd_elftoaout = $(ELFTOAOUT) $(obj)/image -o $@ | 14 | cmd_elftoaout = $(ELFTOAOUT) $(obj)/image -o $@ |
15 | |||
16 | ifeq ($(CONFIG_SPARC32),y) | ||
15 | quiet_cmd_piggy = PIGGY $@ | 17 | quiet_cmd_piggy = PIGGY $@ |
16 | cmd_piggy = $(obj)/piggyback $@ $(obj)/System.map $(ROOT_IMG) | 18 | cmd_piggy = $(obj)/piggyback_32 $@ $(obj)/System.map $(ROOT_IMG) |
17 | quiet_cmd_btfix = BTFIX $@ | 19 | quiet_cmd_btfix = BTFIX $@ |
18 | cmd_btfix = $(OBJDUMP) -x vmlinux | $(obj)/btfixupprep > $@ | 20 | cmd_btfix = $(OBJDUMP) -x vmlinux | $(obj)/btfixupprep > $@ |
19 | quiet_cmd_sysmap = SYSMAP $(obj)/System.map | 21 | quiet_cmd_sysmap = SYSMAP $(obj)/System.map |
@@ -62,3 +64,28 @@ $(obj)/tftpboot.img: $(obj)/piggyback $(obj)/System.map $(obj)/image FORCE | |||
62 | 64 | ||
63 | $(obj)/btfix.S: $(obj)/btfixupprep vmlinux FORCE | 65 | $(obj)/btfix.S: $(obj)/btfixupprep vmlinux FORCE |
64 | $(call if_changed,btfix) | 66 | $(call if_changed,btfix) |
67 | |||
68 | endif | ||
69 | |||
70 | ifeq ($(CONFIG_SPARC64),y) | ||
71 | quiet_cmd_piggy = PIGGY $@ | ||
72 | cmd_piggy = $(obj)/piggyback_64 $@ System.map $(ROOT_IMG) | ||
73 | quiet_cmd_strip = STRIP $@ | ||
74 | cmd_strip = $(STRIP) -R .comment -R .note -K sun4u_init -K _end -K _start vmlinux -o $@ | ||
75 | |||
76 | |||
77 | # Actual linking | ||
78 | $(obj)/image: vmlinux FORCE | ||
79 | $(call if_changed,strip) | ||
80 | @echo ' kernel: $@ is ready' | ||
81 | |||
82 | $(obj)/tftpboot.img: vmlinux $(obj)/piggyback_64 System.map $(ROOT_IMG) FORCE | ||
83 | $(call if_changed,elftoaout) | ||
84 | $(call if_changed,piggy) | ||
85 | @echo ' kernel: $@ is ready' | ||
86 | |||
87 | $(obj)/vmlinux.aout: vmlinux FORCE | ||
88 | $(call if_changed,elftoaout) | ||
89 | @echo ' kernel: $@ is ready' | ||
90 | endif | ||
91 | |||
diff --git a/arch/sparc/boot/piggyback.c b/arch/sparc/boot/piggyback_32.c index c9f500c1a8b2..c9f500c1a8b2 100644 --- a/arch/sparc/boot/piggyback.c +++ b/arch/sparc/boot/piggyback_32.c | |||
diff --git a/arch/sparc64/boot/piggyback.c b/arch/sparc/boot/piggyback_64.c index de364bfed0bb..de364bfed0bb 100644 --- a/arch/sparc64/boot/piggyback.c +++ b/arch/sparc/boot/piggyback_64.c | |||
diff --git a/arch/sparc64/boot/.gitignore b/arch/sparc64/boot/.gitignore deleted file mode 100644 index 36356f9d498e..000000000000 --- a/arch/sparc64/boot/.gitignore +++ /dev/null | |||
@@ -1,4 +0,0 @@ | |||
1 | image | ||
2 | tftpboot.img | ||
3 | vmlinux.aout | ||
4 | piggyback | ||
diff --git a/arch/sparc64/boot/Makefile b/arch/sparc64/boot/Makefile deleted file mode 100644 index 0458b5244f09..000000000000 --- a/arch/sparc64/boot/Makefile +++ /dev/null | |||
@@ -1,33 +0,0 @@ | |||
1 | # Makefile for the Sparc64 boot stuff. | ||
2 | # | ||
3 | # Copyright (C) 1995 David S. Miller (davem@caip.rutgers.edu) | ||
4 | # Copyright (C) 1997 Jakub Jelinek (jj@sunsite.mff.cuni.cz) | ||
5 | |||
6 | ROOT_IMG := /usr/src/root.img | ||
7 | ELFTOAOUT := elftoaout | ||
8 | |||
9 | hostprogs-y := piggyback | ||
10 | targets := image tftpboot.img vmlinux.aout | ||
11 | |||
12 | quiet_cmd_elftoaout = ELF2AOUT $@ | ||
13 | cmd_elftoaout = $(ELFTOAOUT) vmlinux -o $@ | ||
14 | quiet_cmd_piggy = PIGGY $@ | ||
15 | cmd_piggy = $(obj)/piggyback $@ System.map $(ROOT_IMG) | ||
16 | quiet_cmd_strip = STRIP $@ | ||
17 | cmd_strip = $(STRIP) -R .comment -R .note -K sun4u_init -K _end -K _start vmlinux -o $@ | ||
18 | |||
19 | |||
20 | # Actual linking | ||
21 | $(obj)/image: vmlinux FORCE | ||
22 | $(call if_changed,strip) | ||
23 | @echo ' kernel: $@ is ready' | ||
24 | |||
25 | $(obj)/tftpboot.img: vmlinux $(obj)/piggyback System.map $(ROOT_IMG) FORCE | ||
26 | $(call if_changed,elftoaout) | ||
27 | $(call if_changed,piggy) | ||
28 | @echo ' kernel: $@ is ready' | ||
29 | |||
30 | $(obj)/vmlinux.aout: vmlinux FORCE | ||
31 | $(call if_changed,elftoaout) | ||
32 | @echo ' kernel: $@ is ready' | ||
33 | |||