Reviewed-by: Philipp Tomsich <philipp.toms...@theobroma-systems.com> > On 01 Mar 2017, at 03:25, Andre Przywara <andre.przyw...@arm.com> wrote: > > This is an updated and slightly extended version of the SPL FIT loading > series I posted as an RFC some weeks ago. > I tried to fix all bugs that have been pointed out by the diligent > reviewers, also added patches to automatically build the FIT images. > > The first patch is a bug fix for a regression introduced with -rc1. > I put this in there to allow people testing the series and to provide > an actual patch for this fix, which should make it still into 2017.03. > The next four patches introduce the core of the extened SPL FIT loading > support, see below for a description. > Patches 6-9 make some room in the sunxi 64-bit SPL to allow > compiling in the FIT loading bits. Patch 10 and 11 let the SPL choose > the proper DT from the FIT image. > The next two patches add the infrastructure and an actual generator script, > so the FIT image is automatically created at build time. > Patches 14 and 15 enable the SPL FIT support in the Pine64 and the > OrangePi PC 2 defconfigs. > The last two patches are new and eventually store a DT file name in the > SPL header, so U-Boot can easily pick the proper DT when scanning the > FIT image. The idea is that this DT name should stay with the board, > ideally on eMMC or SPI flash. So both U-Boot and a firmware update tool > could identify a board, updating with compatible firmware while keeping > the DT name in place. Ideally a board vendor would once seed this name > onto on-board storage like SPI flash. > > Let me know what you think! > > Cheers, > Andre. > > Based on top of sunxi/master (35affe7698e9). > > ------- > Currently the FIT format is not used to its full potential in the SPL: > It only loads the first image from the /images node and appends the > proper FDT. > Some boards and platforms would benefit from loading more images before > starting U-Boot proper, notably Allwinner A64 and ARMv8 Rockchip boards, > which use an ARM Trusted Firmware (ATF) image to be executed before U-Boot. > > This series tries to solve this in a board agnostic and generic way: > We extend the SPL FIT loading scheme to allow loading multiple images. > So apart from loading the image which is referenced by the "firmware" > property in the respective configuration node and placing the DTB right > behind it, we iterate over all strings in the "loadable" property. > Each image referenced there will be loaded to its specified load address. > The entry point U-Boot eventually branches to will be taken from the > first image to explicitly provide the "entry" property, or, if none > of them does so, from the load address of the "firmware" image. > This keeps the scheme compatible with the FIT images our Makefile creates > automatically at the moment. > Apart from the already mentioned ATF scenario this opens up more usage > scenarios, of which the commit message of patch 04/11 lists some. > The remaining patches prepare ane finally enable this scheme for the 64-bit > Allwinner boards. > > Andre Przywara (15): > SPL: FIT: refactor FDT loading > SPL: FIT: rework U-Boot image loading > SPL: FIT: factor out spl_load_fit_image() > SPL: FIT: allow loading multiple images > tools: mksunxiboot: allow larger SPL binaries > armv8: SPL: only compile GIC code if needed > armv8: fsl: move ccn504 code into FSL Makefile > sunxi: A64: move SPL stack to end of SRAM A2 > sunxi: SPL: store RAM size in gd > sunxi: SPL: add FIT config selector for Pine64 boards > Makefile: add rules to generate SPL FIT images > sunxi: A64: Pine64: introduce FIT generator script > sunxi: Pine64: defconfig: enable SPL FIT support > sunxi: OrangePi-PC2: defconfig: enable SPL FIT support > sunxi: use SPL header DT name for FIT board matching > > Philipp Tomsich (1): > armv8: spl: Call spl_relocate_stack_gd for ARMv8 > > Siarhei Siamashka (1): > sunxi: Store the device tree name in the SPL header > > Kconfig | 17 ++ > Makefile | 20 +++ > arch/arm/cpu/armv8/fsl-layerscape/Makefile | 1 + > arch/arm/include/asm/arch-sunxi/spl.h | 19 ++- > arch/arm/lib/Makefile | 3 +- > arch/arm/lib/crt0_64.S | 14 +- > board/sunxi/board.c | 36 ++++- > board/sunxi/mksunxi_fit_atf.sh | 73 +++++++++ > common/spl/spl_fit.c | 246 +++++++++++++++++------------ > configs/orangepi_pc2_defconfig | 6 + > configs/pine64_plus_defconfig | 6 + > include/configs/sunxi-common.h | 17 +- > scripts/Makefile.spl | 3 +- > tools/mksunxiboot.c | 51 +++++- > 14 files changed, 387 insertions(+), 125 deletions(-) > create mode 100755 board/sunxi/mksunxi_fit_atf.sh > > -- > 2.8.2 >
signature.asc
Description: Message signed with OpenPGP using GPGMail
_______________________________________________ U-Boot mailing list U-Boot@lists.denx.de https://lists.denx.de/listinfo/u-boot