diff --git a/meta-digi-arm/dynamic-layers/freescale-layer/recipes-bsp/imx-mkimage/files/0001-imx9-soc.mak-capture-commands-output-into-a-log-file.patch b/meta-digi-arm/dynamic-layers/freescale-layer/recipes-bsp/imx-mkimage/files/0001-imx9-soc.mak-capture-commands-output-into-a-log-file.patch new file mode 100644 index 000000000..763f23979 --- /dev/null +++ b/meta-digi-arm/dynamic-layers/freescale-layer/recipes-bsp/imx-mkimage/files/0001-imx9-soc.mak-capture-commands-output-into-a-log-file.patch @@ -0,0 +1,45 @@ +From: Javier Viguera +Date: Thu, 31 Aug 2023 16:33:13 +0200 +Subject: [PATCH] imx9: soc.mak: capture commands output into a log file + +This is later used to get the needed information for the signing of the +boot artifacts. + +Signed-off-by: Javier Viguera +--- + iMX9/soc.mak | 7 ++++--- + 1 file changed, 4 insertions(+), 3 deletions(-) + +diff --git a/iMX9/soc.mak b/iMX9/soc.mak +index 7c4086c153d0..7ec4bb5eaeb4 100644 +--- a/iMX9/soc.mak ++++ b/iMX9/soc.mak +@@ -1,4 +1,5 @@ + MKIMG = ../mkimage_imx8 ++MKIMAGE_LOG = "mkimage-$(firstword $(MAKECMDGOALS)).log" + + CC ?= gcc + REV ?= A0 +@@ -71,7 +72,7 @@ u-boot-atf-container.img: bl31.bin u-boot-hash.bin + fi; \ + else \ + ./$(MKIMG) -soc IMX9 -c -ap bl31.bin a35 $(ATF_LOAD_ADDR) -ap u-boot-hash.bin a35 $(UBOOT_LOAD_ADDR) -out u-boot-atf-container.img; \ +- fi ++ fi | tee $(MKIMAGE_LOG) + + .PHONY: clean nightly + clean: +@@ -80,11 +81,11 @@ clean: + @echo "imx8ulp clean done" + + flash_singleboot: $(MKIMG) $(AHAB_IMG) u-boot-spl-ddr.bin u-boot-atf-container.img +- ./$(MKIMG) -soc IMX9 -append $(AHAB_IMG) -c -ap u-boot-spl-ddr.bin a35 $(SPL_LOAD_ADDR) -out flash.bin ++ ./$(MKIMG) -soc IMX9 -append $(AHAB_IMG) -c -ap u-boot-spl-ddr.bin a35 $(SPL_LOAD_ADDR) -out flash.bin | tee -a $(MKIMAGE_LOG) + cp flash.bin boot-spl-container.img + @flashbin_size=`wc -c flash.bin | awk '{print $$1}'`; \ + pad_cnt=$$(((flashbin_size + 0x400 - 1) / 0x400)); \ +- echo "append u-boot-atf-container.img at $$pad_cnt KB"; \ ++ echo "append u-boot-atf-container.img at $$pad_cnt KB" | tee -a $(MKIMAGE_LOG); \ + dd if=u-boot-atf-container.img of=flash.bin bs=1K seek=$$pad_cnt; + + flash_singleboot_flexspi: $(MKIMG) $(AHAB_IMG) u-boot-spl-ddr.bin u-boot-atf-container.img diff --git a/meta-digi-arm/dynamic-layers/freescale-layer/recipes-bsp/imx-mkimage/imx-boot_1.0.bbappend b/meta-digi-arm/dynamic-layers/freescale-layer/recipes-bsp/imx-mkimage/imx-boot_1.0.bbappend index 918a7310c..6ee026814 100644 --- a/meta-digi-arm/dynamic-layers/freescale-layer/recipes-bsp/imx-mkimage/imx-boot_1.0.bbappend +++ b/meta-digi-arm/dynamic-layers/freescale-layer/recipes-bsp/imx-mkimage/imx-boot_1.0.bbappend @@ -1,4 +1,4 @@ -# Copyright (C) 2022 Digi International +# Copyright (C) 2022,2023 Digi International FILESEXTRAPATHS:prepend := "${THISDIR}/files:" @@ -7,6 +7,10 @@ SRC_URI:append:ccimx8m = " \ file://0002-imx8m-soc.mak-capture-commands-output-into-a-log-fil.patch \ " +SRC_URI:append:ccimx93 = " \ + file://0001-imx9-soc.mak-capture-commands-output-into-a-log-file.patch \ +" + # Use NXP's lf-6.1.22-2.0.0 release for ccimx93 SRC_URI:ccimx93 = "git://github.com/nxp-imx/imx-mkimage.git;protocol=https;branch=${SRCBRANCH}" SRCBRANCH:ccimx93 = "lf-6.1.22_2.0.0" @@ -85,6 +89,9 @@ do_deploy:append:ccimx8m() { do_deploy:append:ccimx93() { generate_symlinks + for target in ${IMXBOOT_TARGETS}; do + install -m 0644 ${BOOT_STAGING}/mkimage-${target}.log ${DEPLOYDIR}/${BOOT_TOOLS} + done } do_deploy:ccimx8x () {