diff options
author | Michal Simek <michal.simek@xilinx.com> | 2021-08-19 12:02:57 +0200 |
---|---|---|
committer | Michal Simek <michal.simek@xilinx.com> | 2021-08-26 08:14:43 +0200 |
commit | e69213611ea74e9c40ef0454142a1f6dc5589268 (patch) | |
tree | 59c8108727f87b6fbfa5c565043fc812445d44e5 /arch/arm/mach-zynqmp | |
parent | f28a22d55a5d2f08ad4befb5f27fd00eebc2b85d (diff) | |
download | u-boot-e69213611ea74e9c40ef0454142a1f6dc5589268.tar.gz u-boot-e69213611ea74e9c40ef0454142a1f6dc5589268.tar.bz2 u-boot-e69213611ea74e9c40ef0454142a1f6dc5589268.zip |
xilinx: zynqmp: Generate different u-boot.itb for MULTI_DTB_FIT
When MULTI_DTB_FIT is enabled fit-dtb.blob fit image is created which
contain all DTBs listed by CONFIG_OF_LIST. And with DTB_RELESELECT there is
a need to handle it as one file with DTBs in it not as separate DTBs in
u-boot.its/itb.
That's why extend mkimage_fit_atf.sh to generate u-boot.itb correctly.
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Diffstat (limited to 'arch/arm/mach-zynqmp')
-rwxr-xr-x | arch/arm/mach-zynqmp/mkimage_fit_atf.sh | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/arch/arm/mach-zynqmp/mkimage_fit_atf.sh b/arch/arm/mach-zynqmp/mkimage_fit_atf.sh index 592be7f670..feb3a6260a 100755 --- a/arch/arm/mach-zynqmp/mkimage_fit_atf.sh +++ b/arch/arm/mach-zynqmp/mkimage_fit_atf.sh @@ -111,6 +111,51 @@ cat << __TEE __TEE fi +MULTI_DTB=`awk '/CONFIG_MULTI_DTB_FIT / { print $3 }' include/generated/autoconf.h` + +if [ 1"$MULTI_DTB" -eq 11 ]; then + cat << __FDT_IMAGE_EOF + fdt_1 { + description = "Multi DTB fit image"; + data = /incbin/("fit-dtb.blob"); + type = "flat_dt"; + arch = "arm64"; + compression = "none"; + $DTB_LOAD + hash { + algo = "md5"; + }; + }; + }; + configurations { + default = "config_1"; +__FDT_IMAGE_EOF + +if [ ! -f $BL31 ]; then +cat << __CONF_SECTION1_EOF + config_1 { + description = "Multi DTB without TF-A"; + firmware = "uboot"; + loadables = "fdt_1"; + }; +__CONF_SECTION1_EOF +else +cat << __CONF_SECTION1_EOF + config_1 { + description = "Multi DTB with TF-A"; + firmware = "atf"; + loadables = "uboot", "fdt_1"; + }; +__CONF_SECTION1_EOF +fi + +cat << __ITS_EOF + }; +}; +__ITS_EOF + +else + DEFAULT=1 cnt=1 for dtname in $DT @@ -181,3 +226,5 @@ cat << __ITS_EOF }; }; __ITS_EOF + +fi |