diff options
-rw-r--r-- | arch/powerpc/Kconfig | 19 | ||||
-rw-r--r-- | arch/powerpc/Makefile | 9 | ||||
-rw-r--r-- | arch/powerpc/boot/Makefile | 126 | ||||
-rw-r--r-- | arch/powerpc/boot/cuboot-mpc7448hpc2.c (renamed from arch/powerpc/boot/cuboot-hpc2.c) | 0 | ||||
-rwxr-xr-x | arch/powerpc/boot/wrapper | 23 |
5 files changed, 103 insertions, 74 deletions
diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig index 1348bbc92510..d21495f35727 100644 --- a/arch/powerpc/Kconfig +++ b/arch/powerpc/Kconfig | |||
@@ -438,25 +438,6 @@ config WANT_DEVICE_TREE | |||
438 | bool | 438 | bool |
439 | default n | 439 | default n |
440 | 440 | ||
441 | config DEVICE_TREE | ||
442 | string "Static device tree source file" | ||
443 | depends on WANT_DEVICE_TREE | ||
444 | help | ||
445 | This specifies the device tree source (.dts) file to be | ||
446 | compiled and included when building the bootwrapper. If a | ||
447 | relative filename is given, then it will be relative to | ||
448 | arch/powerpc/boot/dts. If you are not using the bootwrapper, | ||
449 | or do not need to build a dts into the bootwrapper, this | ||
450 | field is ignored. | ||
451 | |||
452 | For example, this is required when building a cuImage target | ||
453 | for an older U-Boot, which cannot pass a device tree itself. | ||
454 | Such a kernel will not work with a newer U-Boot that tries to | ||
455 | pass a device tree (unless you tell it not to). If your U-Boot | ||
456 | does not mention a device tree in "help bootm", then use the | ||
457 | cuImage target and specify a device tree here. Otherwise, use | ||
458 | the uImage target and leave this field blank. | ||
459 | |||
460 | endmenu | 441 | endmenu |
461 | 442 | ||
462 | config ISA_DMA_API | 443 | config ISA_DMA_API |
diff --git a/arch/powerpc/Makefile b/arch/powerpc/Makefile index f70df9b64f8f..6845482f0093 100644 --- a/arch/powerpc/Makefile +++ b/arch/powerpc/Makefile | |||
@@ -151,14 +151,11 @@ core-$(CONFIG_XMON) += arch/powerpc/xmon/ | |||
151 | drivers-$(CONFIG_OPROFILE) += arch/powerpc/oprofile/ | 151 | drivers-$(CONFIG_OPROFILE) += arch/powerpc/oprofile/ |
152 | 152 | ||
153 | # Default to zImage, override when needed | 153 | # Default to zImage, override when needed |
154 | defaultimage-y := zImage | 154 | all: zImage |
155 | defaultimage-$(CONFIG_DEFAULT_UIMAGE) := uImage | ||
156 | KBUILD_IMAGE := $(defaultimage-y) | ||
157 | all: $(KBUILD_IMAGE) | ||
158 | 155 | ||
159 | CPPFLAGS_vmlinux.lds := -Upowerpc | 156 | CPPFLAGS_vmlinux.lds := -Upowerpc |
160 | 157 | ||
161 | BOOT_TARGETS = zImage zImage.initrd uImage | 158 | BOOT_TARGETS = zImage zImage.initrd uImage treeImage.% cuImage.% |
162 | 159 | ||
163 | PHONY += $(BOOT_TARGETS) | 160 | PHONY += $(BOOT_TARGETS) |
164 | 161 | ||
@@ -180,7 +177,7 @@ define archhelp | |||
180 | endef | 177 | endef |
181 | 178 | ||
182 | install: vdso_install | 179 | install: vdso_install |
183 | $(Q)$(MAKE) $(build)=$(boot) BOOTIMAGE=$(KBUILD_IMAGE) install | 180 | $(Q)$(MAKE) $(build)=$(boot) install |
184 | 181 | ||
185 | vdso_install: | 182 | vdso_install: |
186 | ifeq ($(CONFIG_PPC64),y) | 183 | ifeq ($(CONFIG_PPC64),y) |
diff --git a/arch/powerpc/boot/Makefile b/arch/powerpc/boot/Makefile index 122a27078998..49797a45416c 100644 --- a/arch/powerpc/boot/Makefile +++ b/arch/powerpc/boot/Makefile | |||
@@ -60,8 +60,9 @@ src-wlib := string.S crt0.S stdio.c main.c \ | |||
60 | src-plat := of.c cuboot-52xx.c cuboot-824x.c cuboot-83xx.c cuboot-85xx.c holly.c \ | 60 | src-plat := of.c cuboot-52xx.c cuboot-824x.c cuboot-83xx.c cuboot-85xx.c holly.c \ |
61 | cuboot-ebony.c treeboot-ebony.c prpmc2800.c \ | 61 | cuboot-ebony.c treeboot-ebony.c prpmc2800.c \ |
62 | ps3-head.S ps3-hvcall.S ps3.c treeboot-bamboo.c cuboot-8xx.c \ | 62 | ps3-head.S ps3-hvcall.S ps3.c treeboot-bamboo.c cuboot-8xx.c \ |
63 | cuboot-pq2.c cuboot-sequoia.c treeboot-walnut.c cuboot-bamboo.c \ | 63 | cuboot-pq2.c cuboot-sequoia.c treeboot-walnut.c \ |
64 | fixed-head.S ep88xc.c cuboot-hpc2.c ep405.c cuboot-taishan.c \ | 64 | cuboot-bamboo.c cuboot-mpc7448hpc2.c cuboot-taishan.c \ |
65 | fixed-head.S ep88xc.c ep405.c \ | ||
65 | cuboot-katmai.c cuboot-rainier.c redboot-8xx.c ep8248e.c \ | 66 | cuboot-katmai.c cuboot-rainier.c redboot-8xx.c ep8248e.c \ |
66 | cuboot-warp.c cuboot-85xx-cpm2.c | 67 | cuboot-warp.c cuboot-85xx-cpm2.c |
67 | src-boot := $(src-wlib) $(src-plat) empty.c | 68 | src-boot := $(src-wlib) $(src-plat) empty.c |
@@ -123,6 +124,8 @@ targets += $(patsubst $(obj)/%,%,$(obj-boot) wrapper.a) | |||
123 | extra-y := $(obj)/wrapper.a $(obj-plat) $(obj)/empty.o \ | 124 | extra-y := $(obj)/wrapper.a $(obj-plat) $(obj)/empty.o \ |
124 | $(obj)/zImage.lds $(obj)/zImage.coff.lds $(obj)/zImage.ps3.lds | 125 | $(obj)/zImage.lds $(obj)/zImage.coff.lds $(obj)/zImage.ps3.lds |
125 | 126 | ||
127 | dtstree := $(srctree)/$(src)/dts | ||
128 | |||
126 | wrapper :=$(srctree)/$(src)/wrapper | 129 | wrapper :=$(srctree)/$(src)/wrapper |
127 | wrapperbits := $(extra-y) $(addprefix $(obj)/,addnote hack-coff mktree dtc) \ | 130 | wrapperbits := $(extra-y) $(addprefix $(obj)/,addnote hack-coff mktree dtc) \ |
128 | $(wrapper) FORCE | 131 | $(wrapper) FORCE |
@@ -181,7 +184,7 @@ quiet_cmd_wrap = WRAP $@ | |||
181 | image-$(CONFIG_PPC_PSERIES) += zImage.pseries | 184 | image-$(CONFIG_PPC_PSERIES) += zImage.pseries |
182 | image-$(CONFIG_PPC_MAPLE) += zImage.pseries | 185 | image-$(CONFIG_PPC_MAPLE) += zImage.pseries |
183 | image-$(CONFIG_PPC_IBM_CELL_BLADE) += zImage.pseries | 186 | image-$(CONFIG_PPC_IBM_CELL_BLADE) += zImage.pseries |
184 | image-$(CONFIG_PPC_PS3) += zImage.ps3 | 187 | image-$(CONFIG_PPC_PS3) += zImage-dtb.ps3 |
185 | image-$(CONFIG_PPC_CELLEB) += zImage.pseries | 188 | image-$(CONFIG_PPC_CELLEB) += zImage.pseries |
186 | image-$(CONFIG_PPC_CHRP) += zImage.chrp | 189 | image-$(CONFIG_PPC_CHRP) += zImage.chrp |
187 | image-$(CONFIG_PPC_EFIKA) += zImage.chrp | 190 | image-$(CONFIG_PPC_EFIKA) += zImage.chrp |
@@ -191,33 +194,69 @@ image-$(CONFIG_PPC_PRPMC2800) += zImage.prpmc2800 | |||
191 | image-$(CONFIG_PPC_ISERIES) += zImage.iseries | 194 | image-$(CONFIG_PPC_ISERIES) += zImage.iseries |
192 | image-$(CONFIG_DEFAULT_UIMAGE) += uImage | 195 | image-$(CONFIG_DEFAULT_UIMAGE) += uImage |
193 | 196 | ||
194 | ifneq ($(CONFIG_DEVICE_TREE),"") | 197 | # |
195 | image-$(CONFIG_PPC_8xx) += cuImage.8xx | 198 | # Targets which embed a device tree blob |
196 | image-$(CONFIG_PPC_EP88XC) += zImage.ep88xc | 199 | # |
197 | image-$(CONFIG_EP405) += zImage.ep405 | 200 | # Theses are default targets to build images which embed device tree blobs. |
198 | image-$(CONFIG_8260) += cuImage.pq2 | 201 | # They are only required on boards which do not have FDT support in firmware. |
199 | image-$(CONFIG_EP8248E) += zImage.ep8248e | 202 | # Boards with newish u-boot firmare can use the uImage target above |
200 | image-$(CONFIG_PPC_MPC52xx) += cuImage.52xx | 203 | # |
201 | image-$(CONFIG_STORCENTER) += cuImage.824x | 204 | |
202 | image-$(CONFIG_PPC_83xx) += cuImage.83xx | 205 | # Board ports in arch/powerpc/platform/40x/Kconfig |
203 | image-$(CONFIG_PPC_85xx) += cuImage.85xx | 206 | image-$(CONFIG_EP405) += zImage-dtb.ep405 |
204 | ifeq ($(CONFIG_CPM2),y) | 207 | image-$(CONFIG_WALNUT) += treeImage.walnut |
205 | image-$(CONFIG_PPC_85xx) += cuImage.85xx-cpm2 | 208 | |
206 | endif | 209 | # Board ports in arch/powerpc/platform/44x/Kconfig |
207 | image-$(CONFIG_MPC7448HPC2) += cuImage.hpc2 | ||
208 | image-$(CONFIG_EBONY) += treeImage.ebony cuImage.ebony | 210 | image-$(CONFIG_EBONY) += treeImage.ebony cuImage.ebony |
209 | image-$(CONFIG_BAMBOO) += treeImage.bamboo cuImage.bamboo | 211 | image-$(CONFIG_BAMBOO) += treeImage.bamboo cuImage.bamboo |
210 | image-$(CONFIG_SEQUOIA) += cuImage.sequoia | 212 | image-$(CONFIG_SEQUOIA) += cuImage.sequoia |
211 | image-$(CONFIG_RAINIER) += cuImage.rainier | 213 | image-$(CONFIG_RAINIER) += cuImage.rainier |
212 | image-$(CONFIG_WALNUT) += treeImage.walnut | ||
213 | image-$(CONFIG_TAISHAN) += cuImage.taishan | 214 | image-$(CONFIG_TAISHAN) += cuImage.taishan |
214 | image-$(CONFIG_KATMAI) += cuImage.katmai | 215 | image-$(CONFIG_KATMAI) += cuImage.katmai |
215 | image-$(CONFIG_WARP) += cuImage.warp | 216 | image-$(CONFIG_WARP) += cuImage.warp |
216 | endif | ||
217 | 217 | ||
218 | ifneq ($(CONFIG_REDBOOT),"") | 218 | # Board ports in arch/powerpc/platform/8xx/Kconfig |
219 | image-$(CONFIG_PPC_8xx) += zImage.redboot-8xx | 219 | image-$(CONFIG_PPC_MPC86XADS) += cuImage.mpc866ads |
220 | endif | 220 | image-$(CONFIG_PPC_MPC885ADS) += cuImage.mpc885ads |
221 | image-$(CONFIG_PPC_EP88XC) += zImage-dtb.ep88xc | ||
222 | image-$(CONFIG_PPC_ADDER875) += cuImage.adder875-uboot \ | ||
223 | zImage-dtb.adder875-redboot | ||
224 | |||
225 | # Board ports in arch/powerpc/platform/52xx/Kconfig | ||
226 | image-$(CONFIG_PPC_LITE5200) += cuImage.lite5200 cuImage.lite5200b | ||
227 | |||
228 | # Board ports in arch/powerpc/platform/82xx/Kconfig | ||
229 | image-$(CONFIG_MPC8272_ADS) += cuImage.mpc8272ads | ||
230 | image-$(CONFIG_PQ2FADS) += cuImage.pq2fads | ||
231 | image-$(CONFIG_EP8248E) += zImage-dtb.ep8248e | ||
232 | |||
233 | # Board ports in arch/powerpc/platform/83xx/Kconfig | ||
234 | image-$(CONFIG_MPC832x_MDS) += cuImage.mpc832x_mds | ||
235 | image-$(CONFIG_MPC832x_RDB) += cuImage.mpc832x_rdb | ||
236 | image-$(CONFIG_MPC834x_ITX) += cuImage.mpc8349emitx \ | ||
237 | cuImage.mpc8349emitxgp | ||
238 | image-$(CONFIG_MPC834x_MDS) += cuImage.mpc834x_mds | ||
239 | image-$(CONFIG_MPC836x_MDS) += cuImage.mpc836x_mds | ||
240 | |||
241 | # Board ports in arch/powerpc/platform/85xx/Kconfig | ||
242 | image-$(CONFIG_MPC8540_ADS) += cuImage.mpc8540ads | ||
243 | image-$(CONFIG_MPC8560_ADS) += cuImage.mpc8560ads | ||
244 | image-$(CONFIG_MPC85xx_CDS) += cuImage.mpc8541cds \ | ||
245 | cuImage.mpc8548cds \ | ||
246 | cuImage.mpc8555cds | ||
247 | image-$(CONFIG_MPC85xx_MDS) += cuImage.mpc8568mds | ||
248 | image-$(CONFIG_MPC85xx_DS) += cuImage.mpc8544ds \ | ||
249 | cuImage.mpc8572ds | ||
250 | image-$(CONFIG_TQM8540) += cuImage.tqm8540 | ||
251 | image-$(CONFIG_TQM8541) += cuImage.tqm8541 | ||
252 | image-$(CONFIG_TQM8555) += cuImage.tqm8555 | ||
253 | image-$(CONFIG_TQM8560) += cuImage.tqm8560 | ||
254 | image-$(CONFIG_SBC8548) += cuImage.tqm8548 | ||
255 | image-$(CONFIG_SBC8560) += cuImage.tqm8560 | ||
256 | |||
257 | # Board ports in arch/powerpc/platform/embedded6xx/Kconfig | ||
258 | image-$(CONFIG_STORCENTER) += cuImage.storcenter | ||
259 | image-$(CONFIG_MPC7448HPC2) += cuImage.mpc7448hpc2 | ||
221 | 260 | ||
222 | # For 32-bit powermacs, build the COFF and miboot images | 261 | # For 32-bit powermacs, build the COFF and miboot images |
223 | # as well as the ELF images. | 262 | # as well as the ELF images. |
@@ -233,24 +272,20 @@ targets += $(image-y) $(initrd-y) | |||
233 | 272 | ||
234 | $(addprefix $(obj)/, $(initrd-y)): $(obj)/ramdisk.image.gz | 273 | $(addprefix $(obj)/, $(initrd-y)): $(obj)/ramdisk.image.gz |
235 | 274 | ||
236 | # If CONFIG_WANT_DEVICE_TREE is set and CONFIG_DEVICE_TREE isn't an | ||
237 | # empty string, define 'dts' to be path to the dts | ||
238 | # CONFIG_DEVICE_TREE will have "" around it, make sure to strip them | ||
239 | ifeq ($(CONFIG_WANT_DEVICE_TREE),y) | ||
240 | ifneq ($(CONFIG_DEVICE_TREE),"") | ||
241 | dts = $(if $(shell echo $(CONFIG_DEVICE_TREE) | grep '^/'),\ | ||
242 | ,$(srctree)/$(src)/dts/)$(CONFIG_DEVICE_TREE:"%"=%) | ||
243 | endif | ||
244 | endif | ||
245 | |||
246 | # Don't put the ramdisk on the pattern rule; when its missing make will try | 275 | # Don't put the ramdisk on the pattern rule; when its missing make will try |
247 | # the pattern rule with less dependencies that also matches (even with the | 276 | # the pattern rule with less dependencies that also matches (even with the |
248 | # hard dependency listed). | 277 | # hard dependency listed). |
249 | $(obj)/zImage.initrd.%: vmlinux $(wrapperbits) $(dts) | 278 | $(obj)/zImage.initrd.%: vmlinux $(wrapperbits) |
250 | $(call if_changed,wrap,$*,$(dts),,$(obj)/ramdisk.image.gz) | 279 | $(call if_changed,wrap,$*,,,$(obj)/ramdisk.image.gz) |
251 | 280 | ||
252 | $(obj)/zImage.%: vmlinux $(wrapperbits) $(dts) | 281 | $(obj)/zImage.%: vmlinux $(wrapperbits) |
253 | $(call if_changed,wrap,$*,$(dts)) | 282 | $(call if_changed,wrap,$*) |
283 | |||
284 | $(obj)/zImage-dtb.initrd.%: vmlinux $(wrapperbits) $(dtstree)/%.dts | ||
285 | $(call if_changed,wrap,$*,$(dtstree)/$*.dts,,$(obj)/ramdisk.image.gz) | ||
286 | |||
287 | $(obj)/zImage-dtb.%: vmlinux $(wrapperbits) $(dtstree)/%.dts | ||
288 | $(call if_changed,wrap,$*,$(dtstree)/$*.dts) | ||
254 | 289 | ||
255 | # This cannot be in the root of $(src) as the zImage rule always adds a $(obj) | 290 | # This cannot be in the root of $(src) as the zImage rule always adds a $(obj) |
256 | # prefix | 291 | # prefix |
@@ -260,24 +295,17 @@ $(obj)/vmlinux.strip: vmlinux | |||
260 | $(obj)/zImage.iseries: vmlinux | 295 | $(obj)/zImage.iseries: vmlinux |
261 | $(STRIP) -s -R .comment $< -o $@ | 296 | $(STRIP) -s -R .comment $< -o $@ |
262 | 297 | ||
263 | $(obj)/zImage.ps3: vmlinux $(wrapper) $(wrapperbits) $(srctree)/$(src)/dts/ps3.dts | ||
264 | $(STRIP) -s -R .comment $< -o vmlinux.strip | ||
265 | $(call cmd,wrap,ps3,$(srctree)/$(src)/dts/ps3.dts,,) | ||
266 | |||
267 | $(obj)/zImage.initrd.ps3: vmlinux $(wrapper) $(wrapperbits) $(srctree)/$(src)/dts/ps3.dts $(obj)/ramdisk.image.gz | ||
268 | $(call cmd,wrap,ps3,$(srctree)/$(src)/dts/ps3.dts,,$(obj)/ramdisk.image.gz) | ||
269 | |||
270 | $(obj)/uImage: vmlinux $(wrapperbits) | 298 | $(obj)/uImage: vmlinux $(wrapperbits) |
271 | $(call if_changed,wrap,uboot) | 299 | $(call if_changed,wrap,uboot) |
272 | 300 | ||
273 | $(obj)/cuImage.%: vmlinux $(dts) $(wrapperbits) | 301 | $(obj)/cuImage.%: vmlinux $(dtstree)/%.dts $(wrapperbits) |
274 | $(call if_changed,wrap,cuboot-$*,$(dts)) | 302 | $(call if_changed,wrap,cuboot-$*,$(dtstree)/$*.dts) |
275 | 303 | ||
276 | $(obj)/treeImage.initrd.%: vmlinux $(dts) $(wrapperbits) | 304 | $(obj)/treeImage.initrd.%: vmlinux $(dtstree)/%.dts $(wrapperbits) |
277 | $(call if_changed,wrap,treeboot-$*,$(dts),,$(obj)/ramdisk.image.gz) | 305 | $(call if_changed,wrap,treeboot-$*,$(dtstree)/$*.dts,,$(obj)/ramdisk.image.gz) |
278 | 306 | ||
279 | $(obj)/treeImage.%: vmlinux $(dts) $(wrapperbits) | 307 | $(obj)/treeImage.%: vmlinux $(dtstree)/%.dts $(wrapperbits) |
280 | $(call if_changed,wrap,treeboot-$*,$(dts)) | 308 | $(call if_changed,wrap,treeboot-$*,$(dtstree)/$*.dts) |
281 | 309 | ||
282 | # If there isn't a platform selected then just strip the vmlinux. | 310 | # If there isn't a platform selected then just strip the vmlinux. |
283 | ifeq (,$(image-y)) | 311 | ifeq (,$(image-y)) |
diff --git a/arch/powerpc/boot/cuboot-hpc2.c b/arch/powerpc/boot/cuboot-mpc7448hpc2.c index 1b8953259d75..1b8953259d75 100644 --- a/arch/powerpc/boot/cuboot-hpc2.c +++ b/arch/powerpc/boot/cuboot-mpc7448hpc2.c | |||
diff --git a/arch/powerpc/boot/wrapper b/arch/powerpc/boot/wrapper index 763a0c46f441..c3178155311b 100755 --- a/arch/powerpc/boot/wrapper +++ b/arch/powerpc/boot/wrapper | |||
@@ -158,6 +158,29 @@ miboot|uboot) | |||
158 | cuboot*) | 158 | cuboot*) |
159 | binary=y | 159 | binary=y |
160 | gzip= | 160 | gzip= |
161 | case "$platform" in | ||
162 | *-mpc885ads|*-adder875*|*-ep88xc) | ||
163 | platformo=$object/cuboot-8xx.o | ||
164 | ;; | ||
165 | *5200*|*-motionpro) | ||
166 | platformo=$object/cuboot-52xx.o | ||
167 | ;; | ||
168 | *-pq2fads|*-ep8248e|*-mpc8272*|*-storcenter) | ||
169 | platformo=$object/cuboot-pq2.o | ||
170 | ;; | ||
171 | *-mpc824*) | ||
172 | platformo=$object/cuboot-824x.o | ||
173 | ;; | ||
174 | *-mpc83*) | ||
175 | platformo=$object/cuboot-83xx.o | ||
176 | ;; | ||
177 | *-tqm8541|*-mpc8560*|*-tqm8560|*-tqm8555*) | ||
178 | platformo=$object/cuboot-85xx-cpm2.o | ||
179 | ;; | ||
180 | *-mpc85*) | ||
181 | platformo=$object/cuboot-85xx.o | ||
182 | ;; | ||
183 | esac | ||
161 | ;; | 184 | ;; |
162 | ps3) | 185 | ps3) |
163 | platformo="$object/ps3-head.o $object/ps3-hvcall.o $object/ps3.o" | 186 | platformo="$object/ps3-head.o $object/ps3-hvcall.o $object/ps3.o" |