summaryrefslogtreecommitdiff
path: root/arch/powerpc/boot/wrapper
AgeCommit message (Collapse)Author
2008-04-17[POWERPC] bootwrapper: Use physical address in PHDR for uImageKumar Gala
Now that we properly set the physical address in the program header of the vmlinux ELF we can extract it to properly set the load and entry point for u-boot uImages. Before we always hard coded the load & entry point to 0. However there are situations that the kernel may be built with a non-zero physical address. We use objdump to extract the PHDR. We assume that there is only one PHDR in the vmlinux of type LOAD. Signed-off-by: Kumar Gala <galak@kernel.crashing.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
2008-04-02[POWERPC] bootwrapper: Add a firmware-independent simpleboot target.Grant Likely
This target produces a flat binary rather than an ELF file, fixes the entry point at the beginning of the image, and takes a complete device tree with no fixups needed. Signed-off-by: Grant Likely <grant.likely@secretlab.ca> Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com>
2008-04-01[POWERPC] PS3: Bootwrapper improvementsGeoff Levand
Improve the debugging support of the PS3 bootwraper code: o Increase the size of the PS3 bootwrapper overlay from 256 to 512 bytes to allow for more debugging code in the overlay. o Use the dot symbol to set the size of __system_reset_overlay. The assembler will then emit an error if the overlay code is too big. o Remove some unused instructions. o Update the text describing the PS3 bootwrapper overlay. o Add a check for null pointer writes. o Change hcall return value from s64. Signed-off-by: Geoff Levand <geoffrey.levand@am.sony.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2008-03-26[POWERPC] 85xx: Emerson KSI8560 bootwrapperAlexandr Smirnov
Add boot wrapper for Emerson KSI8560 board. Signed-off-by: Alexandr Smirnov <asmirnov@ru.mvista.com> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2008-03-20[POWERPC] Fix build failure for tqm8540 and sbc85xx defconfigsPaul Gortmaker
The wrapper script didn't have entries for the TQM8540 board and the SBC8548 or SBC8560 boards. I've assumed that the TQM8540 console is 8250 based and not CPM based by looking at its defconfig. There was also a trailing * on the TQM8555 entry that I removed too. Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Grant Likely <grant.likely@secretlab.ca> Signed-off-by: Paul Mackerras <paulus@samba.org>
2008-03-07[POWERPC] 8xx: Fix wrapper platform for adder875, and combine defconfigs.Scott Wood
This fixes the following bug: http://ozlabs.org/pipermail/linuxppc-dev/2008-February/051979.html Separate defconfigs are no longer needed now that CONFIG_DEVICE_TREE is gone. Signed-off-by: Scott Wood <scottwood@freescale.com> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2008-02-07[POWERPC] bootwrapper: Build multiple cuImagesGrant Likely
Currently, the kernel uses CONFIG_DEVICE_TREE to wrap a kernel image with a fdt blob which means for any given configuration only one dts file can be selected and so support for only one board can be built This moves the selection of the default .dts file out of the kernel config and into the bootwrapper makefile. The makefile chooses which images to build based on the kernel config and the dts source file name is taken directly from the image name. For example "cuImage.ebony" will use "ebony.dts" as the device tree source file. In addition, this patch allows a specific image to be requested from the command line by adding "cuImage.%" and "treeImage.%" targets to the list of valid built targets in arch/powerpc/Makefile. This allows the default dts selection to be overridden. Another advantage to this change is it allows a single defconfig to be supplied for all boards using the same chip family and only differing in the device tree. Important note: This patch adds two new zImage targets; zImage.dtb.% and zImage.dtb.initrd.% for zImages with embedded dtb files. Currently there are 5 platforms which require this: ps3, ep405, mpc885ads, ep88xc, adder875-redboot and ep8248e. This patch *changes the zImage filenames* for those platforms. ie. 'zImage.ps3' is now 'zImage.dtb.ps3'. This new zImage.dtb targets were added so that the .dts file could be part of the dependancies list for building them. Signed-off-by: Grant Likely <grant.likely@secretlab.ca> Signed-off-by: Paul Mackerras <paulus@samba.org>
2008-01-23[POWERPC] 82xx: Embedded Planet EP8248E supportScott Wood
This board is also resold by Freescale under the names "QUICCStart MPC8248 Evaluation System" and "CWH-PPC-8248N-VE". Signed-off-by: Scott Wood <scottwood@freescale.com> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2008-01-23[POWERPC] 8xx: Analogue & Micro Adder875 board support.Scott Wood
Signed-off-by: Scott Wood <scottwood@freescale.com> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2007-12-23[POWERPC] 4xx: EP405 boards support for arch/powerpcBenjamin Herrenschmidt
Brings EP405 support to arch/powerpc. The IRQ routing for the CPLD comes from a device-tree property, PCI is working to the point where I can see the video card, USB device, and south bridge. This should work with both EP405 and EP405PC. I've not totally figured out how IRQs are wired on this hardware though, thus at this stage, expect only USB interrupts working, pretty much the same as what arch/ppc did. Also, the flash, nvram, rtc and temp control still have to be wired. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com>
2007-12-20[POWERPC] Use embedded dtc in kernel buildsDavid Gibson
This patch alters the kernel makefiles to build dtc from the sources embedded in the previous patch. It also changes the arch/powerpc/boot/wrapper script to use the embedded dtc, rather than expecting a copy of dtc already installed on the system. Signed-off-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-06[POWERPC] Allow for bootwrapper utilities being in different directory to ↵David Woodhouse
objects It's possible that the executables which are built as helpers for the bootwrapper stuff might end up in a different place to the intermediate object files. Handle that. Signed-off-by: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-06[POWERPC] Find device-tree source file in default directoryDavid Woodhouse
If a .dts file is given to the bootwrapper script without a full path name, look in a sensible place for it. Signed-off-by: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-06[POWERPC] Create otheros.bld next to specified output file, not in $object ↵David Woodhouse
directory The bootwrapper script currently generates an 'otheros.bld' file in addition to the file specified by the -o option, when asked to build a wrapper for PS3. It should do that in the same directory as the output, not the directory where the wrapper objects are kept (which might potentially not be writable when the script runs). Arguably, the 'otheros.bld' ought to be created with the filename specified as the -o argument. But that's a more intrusive change. Signed-off-by: David Woodhouse <dwmw2@infradead.org> Acked-by: Geoff Levand <geoffrey.levand@am.sony.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-11-08Merge branch 'for-2.6.24' of ↵Paul Mackerras
master.kernel.org:/pub/scm/linux/kernel/git/jwboyer/powerpc-4xx into merge
2007-11-08[POWERPC] bootwrapper: Revert ps3 binary flag usage, and remove .bin suffixScott Wood
The ps3 target produces two images, and the binary one is not the "primary" image that corresponds to the -o flag; thus, it no longer uses the generic binary flag. On platforms which do use the binary flag, it no longer produces a .bin suffix, so that the output file matches what was passed to the -o flag. This should fix the zImage ln problems for the ps3 target. Signed-off-by: Scott Wood <scottwood@freescale.com> Acked-by: Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-11-01[POWERPC] bootwrapper: Bail from script if any command failsGrant Likely
Add the 'set -e' command to the wrapper script so that if any command fails then the script will automatically exit Signed-off-by: Grant Likely <grant.likely@secretlab.ca> Acked-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com>
2007-11-01[POWERPC] bootwrapper: Allow wrapper script to execute verboselyGrant Likely
Allow wrapper script to print verbose progress when the V is set in the environment. Signed-off-by: Grant Likely <grant.likely@secretlab.ca> Acked-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com>
2007-10-04[POWERPC] 8xx/wrapper: Embedded Planet EP88xC supportScott Wood
This board is also resold by Freescale under the names "QUICCStart MPC885 Evaluation System" and "CWH-PPC-885XN-VE". Signed-off-by: Scott Wood <scottwood@freescale.com> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
2007-07-10[POWERPC] PS3: Bootwrapper support.Geoff Levand
Add support to build the PS3 flash rom image and remove some unneeded lmb calls. The PS3's lv1 loader supports loading gzipped binary images from flash rom to addr zero. The loader enters the image at addr 0x100. In this implementation a bootwrapper overlay is use to arrange for the kernel to be loaded to addr zero and to have a suitable bootwrapper entry at 0x100. To construct the rom image, 0x100 bytes from offset 0x100 in the kernel is copied to the bootwrapper symbol __system_reset_kernel. The 0x100 bytes at the bootwrapper symbol __system_reset_overlay is then copied to offset 0x100. At runtime the bootwrapper program copies the 0x100 bytes at __system_reset_kernel to addr 0x100. zImage.ps3 is a wrapped image that contains a flat device tree, an lv1 compatible entry point, and an optional initrd. otheros.bld is the gzip compresed rom image built from zImage.ps3. otheros.bld is suitable for programming into the PS3 boot flash memory. Signed-off-by: Geoff Levand <geoffrey.levand@am.sony.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-06-02[POWERPC] Fix zImage.coff generation for 32-bit pmacMilton Miller
Commit 9da82a6dee9db4cd5ae7a74ab4f51afb52b6efb9 inadvertently removed the platform override for zImage.coff to be generated with pmaccoff. Rather than add a special makefile rule, change the platform for which the wrapper platform uses the special rules. Signed-off-by: Milton Miller <miltonm@bga.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-05-08[POWERPC] Support for the Ebony 440GP reference board in arch/powerpcDavid Gibson
This adds platform support code for the Ebony (440GP) evaluation board. This includes both code in arch/powerpc/platforms/44x for board initialization, and zImage wrapper code to correctly tweak the flattened device tree based on information from the firmware. The zImage supports both IBM OpenBIOS (aka "treeboot") and old versions of uboot which don't support a flattened device tree. Signed-off-by: David Gibson <dwg@au1.ibm.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-05-02[POWERPC] Small cleanups to the cuboot bootwrapper codeDavid Gibson
This patch makes a few small cleanups to the cuboot code. - It removes the double layered selection of images, via cuboot-plat-y, instead having the cuboot platforms directly select a suitable image-y (this changes the name of the final cuboot image from plain cuImage to cuImage.<platform>). - Factors out some code in the wrapper that's potentially useful to platforms other than uboot. Signed-off-by: David Gibson <david@gibson.dropbear.id.au> Acked-by: Scott Wood <scottwood@freescale.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-04-24[POWERPC] bootwrapper: Add a cuboot platform and a cuImage targetScott Wood
The cuImage target will build a uImage with bootwrapper code and a device tree. The default device tree and platform file are determined by the kernel configuration. Signed-off-by: Scott Wood <scottwood@freescale.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-04-13[POWERPC] bootwrapper: no-gzip fixesMilton Miller
Commit a9903811bf8d130a26004f9cb27b66513a267908 missed two uses of the the .gz suffix in the wrapper script and didn't clean the additonal possibly cached files. Signed-off-by: Milton Miller <miltonm@bga.com> Acked-by: Scott Wood <scottwood@freescale.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-03-21[POWERPC] bootwrapper: Make compression of the kernel image optional.Scott Wood
The --no-gzip option can be passed to the wrapper so that the kernel image is included uncompressed into the zImage. This is intended for bootloaders where the zImage itself can be compressed, or where boot time is considered more important than kernel image size. Signed-off-by: Scott Wood <scottwood@freescale.com> Acked-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-03-13[POWERPC] zImage: Cleanup and improve zImage entry pointDavid Gibson
This patch re-organises the way the zImage wrapper code is entered, to allow more flexibility on platforms with unusual entry conditions. After this patch, a platform .o file has two options: 1) It can define a _zimage_start, in which case the platform code gets control from the very beginning of execution. In this case the platform code is responsible for relocating the zImage if necessary, clearing the BSS, performing any platform specific initialization, and finally calling start() to load and enter the kernel. 2) It can define platform_init(). In this case the generic crt0.S handles initial entry, and calls platform_init() before calling start(). The signature of platform_init() is changed, however, to take up to 5 parameters (in r3..r7) as they come from the platform's initial loader, instead of a fixed set of parameters based on OF's usage. When using the generic crt0.S, the platform .o can optionally supply a custom stack to use, using the BSS_STACK() macro. If this is not supplied, the crt0.S will assume that the loader has supplied a usable stack. In either case, the platform code communicates information to the generic code (specifically, a PROM pointer for OF systems, and/or an initrd image address supplied by the bootloader) via a global structure "loader_info". In addition the wrapper script is rearranged to ensure that the platform .o is always linked first. This means that platforms where the zImage entry point is at a fixed address or offset, rather than being encoded in the binary header can be supported using option (1). Signed-off-by: David Gibson <dwg@au1.ibm.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2006-11-13[PATCH] Remove dtb file created by wrapper scriptMark A. Greer
When the wrapper script is passed a dts file, it runs 'dtc' to create a dtb file. This patch deletes that dtb file once its no longer needed. Signed-off-by: Mark A. Greer <mgreer@mvista.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2006-10-18[POWERPC] More bootwrapper reorganizationMark A. Greer
More reorganization of the bootwrapper: - Add dtb section to zImage - ft_init now called by platform_init - Pack a flat dt before calling kernel - Remove size parameter from free - printf only calls console_ops.write it its not NULL - Some cleanup Signed-off-by: Mark A. Greer <mgreer@mvista.com> Signed-off-by: Paul Mackerras <paulus@samba.org>
2006-09-28[POWERPC] Create a "wrapper" script and use it in arch/powerpc/bootPaul Mackerras
This puts the knowledge of how to create various sorts of zImage wrappers into a script called "wrapper" that could be used outside of the kernel tree. This changes arch/powerpc/boot so it first builds the files that the wrapper script needs, then runs it to create whatever flavours of zImage are required. This version does uImages as well. The zImage names are changed slightly; zImage.pseries is the one with the PT_NOTE program header entry added, and zImage.pmac is the one without. If the zImage.pseries gets made, it will also get hardlinked to zImage; otherwise, if zImage.pmac is made, it gets hardlinked to zImage. Signed-off-by: Paul Mackerras <paulus@samba.org>