From 4566b1075187e158dc7942c06771642635069553 Mon Sep 17 00:00:00 2001 From: Javier Viguera Date: Tue, 2 Jan 2024 17:09:49 +0100 Subject: [PATCH] imx-boot, imx-mkimage: update to NXP's lf-6.1.55-2.2.0 release for ccimx93 Signed-off-by: Javier Viguera --- ...ture-commands-output-into-a-log-file.patch | 40 ++++++++++--------- ...-makefile-target-to-build-A0-revisio.patch | 29 ++++++-------- .../imx-mkimage/imx-boot_1.0.bbappend | 6 +-- .../imx-mkimage/imx-mkimage_git.bbappend | 8 ++-- 4 files changed, 42 insertions(+), 41 deletions(-) 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 index 9668a97fd..f8606fb4b 100644 --- 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 @@ -11,7 +11,7 @@ Signed-off-by: Javier Viguera 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/iMX9/soc.mak b/iMX9/soc.mak -index 6d4613dd7d92..97e311059df8 100644 +index b17db6b7ca8c..c4bcac4e42cd 100644 --- a/iMX9/soc.mak +++ b/iMX9/soc.mak @@ -1,4 +1,5 @@ @@ -20,26 +20,30 @@ index 6d4613dd7d92..97e311059df8 100644 CC ?= gcc REV ?= A0 -@@ -98,7 +99,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; \ +@@ -110,7 +111,7 @@ define append_container + @flashbin_size=`wc -c flash.bin | awk '{print $$1}'`; \ + psize=$$((0x400 * $(2))); \ + pad_cnt=$$(((flashbin_size + psize - 1) / psize)); \ +- echo "append $(1) at $$((pad_cnt * $(2))) KB, psize=$$psize"; \ ++ echo "append $(1) at $$((pad_cnt * $(2))) KB, psize=$$psize" | tee -a $(MKIMAGE_LOG); \ + dd if=$(1) of=flash.bin bs=1K seek=$$((pad_cnt * $(2))); + endef + +@@ -209,7 +210,7 @@ u-boot-atf-container.img: bl31.bin u-boot-hash.bin + -ap bl31.bin a55 $(ATF_LOAD_ADDR) \ + -ap u-boot-hash.bin a55 $(UBOOT_LOAD_ADDR) \ + -out u-boot-atf-container.img; \ - fi + fi | tee $(MKIMAGE_LOG) u-boot-atf-container-spinand.img: bl31.bin u-boot-hash.bin - if [ -f tee.bin ]; then \ -@@ -125,11 +126,11 @@ clean: - @echo "imx9 clean done" + if [ -f $(TEE) ]; then \ +@@ -286,7 +287,7 @@ endif - 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: $(MKIMG) $(AHAB_IMG) $(SPL_A55_IMG) u-boot-atf-container.img $(OEI_A55_DDR) + ./$(MKIMG) -soc IMX9 -append $(AHAB_IMG) -c $(OEI_OPT_A55) \ +- -ap $(SPL_A55_IMG) a55 $(SPL_LOAD_ADDR) -out flash.bin ++ -ap $(SPL_A55_IMG) a55 $(SPL_LOAD_ADDR) -out flash.bin | tee -a $(MKIMAGE_LOG) + $(call append_container,u-boot-atf-container.img,1) - flash_singleboot_spinand: $(MKIMG) $(AHAB_IMG) u-boot-spl-ddr.bin u-boot-atf-container-spinand.img flash_fw.bin + flash_singleboot_no_ahabfw: $(MKIMG) $(SPL_A55_IMG) u-boot-atf-container.img $(OEI_A55_DDR) diff --git a/meta-digi-arm/dynamic-layers/freescale-layer/recipes-bsp/imx-mkimage/files/0002-imx9-soc.mak-add-makefile-target-to-build-A0-revisio.patch b/meta-digi-arm/dynamic-layers/freescale-layer/recipes-bsp/imx-mkimage/files/0002-imx9-soc.mak-add-makefile-target-to-build-A0-revisio.patch index f62c6dea4..3c835ca13 100644 --- a/meta-digi-arm/dynamic-layers/freescale-layer/recipes-bsp/imx-mkimage/files/0002-imx9-soc.mak-add-makefile-target-to-build-A0-revisio.patch +++ b/meta-digi-arm/dynamic-layers/freescale-layer/recipes-bsp/imx-mkimage/files/0002-imx9-soc.mak-add-makefile-target-to-build-A0-revisio.patch @@ -4,25 +4,22 @@ Subject: [PATCH] imx9: soc.mak: add makefile target to build A0 revision Signed-off-by: Javier Viguera --- - iMX9/soc.mak | 8 ++++++++ - 1 file changed, 8 insertions(+) + iMX9/soc.mak | 5 +++++ + 1 file changed, 5 insertions(+) diff --git a/iMX9/soc.mak b/iMX9/soc.mak -index 97e311059df8..59352f22deb1 100644 +index c4bcac4e42cd..4f741451d1d0 100644 --- a/iMX9/soc.mak +++ b/iMX9/soc.mak -@@ -133,6 +133,14 @@ flash_singleboot: $(MKIMG) $(AHAB_IMG) u-boot-spl-ddr.bin u-boot-atf-container.i - 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; +@@ -290,6 +290,11 @@ flash_singleboot: $(MKIMG) $(AHAB_IMG) $(SPL_A55_IMG) u-boot-atf-container.img $ + -ap $(SPL_A55_IMG) a55 $(SPL_LOAD_ADDR) -out flash.bin | tee -a $(MKIMAGE_LOG) + $(call append_container,u-boot-atf-container.img,1) -+flash_singleboot_a0: $(MKIMG) mx93a0-ahab-container.img u-boot-spl-ddr.bin u-boot-atf-container.img -+ ./$(MKIMG) -soc IMX9 -append mx93a0-ahab-container.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" | tee -a $(MKIMAGE_LOG); \ -+ dd if=u-boot-atf-container.img of=flash.bin bs=1K seek=$$pad_cnt; ++flash_singleboot_a0: $(MKIMG) mx93a0-ahab-container.img $(SPL_A55_IMG) u-boot-atf-container.img $(OEI_A55_DDR) ++ ./$(MKIMG) -soc IMX9 -append mx93a0-ahab-container.img -c $(OEI_OPT_A55) \ ++ -ap $(SPL_A55_IMG) a55 $(SPL_LOAD_ADDR) -out flash.bin | tee -a $(MKIMAGE_LOG) ++ $(call append_container,u-boot-atf-container.img,1) + - flash_singleboot_spinand: $(MKIMG) $(AHAB_IMG) u-boot-spl-ddr.bin u-boot-atf-container-spinand.img flash_fw.bin - ./$(MKIMG) -soc IMX9 -dev nand 4K -append $(AHAB_IMG) -c -ap u-boot-spl-ddr.bin a35 $(SPL_LOAD_ADDR) -out flash.bin - cp flash.bin boot-spl-container.img + flash_singleboot_no_ahabfw: $(MKIMG) $(SPL_A55_IMG) u-boot-atf-container.img $(OEI_A55_DDR) + ./$(MKIMG) -soc IMX9 -c $(OEI_OPT_A55) \ + -ap $(SPL_A55_IMG) a55 $(SPL_LOAD_ADDR) -out flash.bin 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 2060db12f..08a624d46 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 @@ -12,10 +12,10 @@ SRC_URI:append:ccimx93 = " \ file://0002-imx9-soc.mak-add-makefile-target-to-build-A0-revisio.patch \ " -# Use NXP's lf-6.1.36-2.1.0 release for ccimx93 +# Use NXP's lf-6.1.55-2.2.0 release for ccimx93 SRC_URI:ccimx93 = "git://github.com/nxp-imx/imx-mkimage.git;protocol=https;branch=${SRCBRANCH}" -SRCBRANCH:ccimx93 = "lf-6.1.36_2.1.0" -SRCREV:ccimx93 = "5a0faefc223e51e088433663b6e7d6fbce89bf59" +SRCBRANCH:ccimx93 = "lf-6.1.55_2.2.0" +SRCREV:ccimx93 = "c4365450fb115d87f245df2864fee1604d97c06a" DEPENDS += "${@oe.utils.conditional('TRUSTFENCE_SIGN', '1', 'trustfence-sign-tools-native', '', d)}" diff --git a/meta-digi-arm/dynamic-layers/freescale-layer/recipes-bsp/imx-mkimage/imx-mkimage_git.bbappend b/meta-digi-arm/dynamic-layers/freescale-layer/recipes-bsp/imx-mkimage/imx-mkimage_git.bbappend index b40e5563b..321037dc0 100644 --- a/meta-digi-arm/dynamic-layers/freescale-layer/recipes-bsp/imx-mkimage/imx-mkimage_git.bbappend +++ b/meta-digi-arm/dynamic-layers/freescale-layer/recipes-bsp/imx-mkimage/imx-mkimage_git.bbappend @@ -1,4 +1,4 @@ -# Copyright (C) 2022 Digi International +# Copyright (C) 2022-2024 Digi International Inc. FILESEXTRAPATHS:prepend := "${THISDIR}/files:" @@ -6,10 +6,10 @@ SRC_URI:append:ccimx8m = " \ file://0001-imx8m-soc.mak-preserve-dtbs-after-build.patch \ " -# Use NXP's lf-6.1.36-2.1.0 release for ccimx93 +# Use NXP's lf-6.1.55-2.2.0 release for ccimx93 SRC_URI:ccimx93 = "git://github.com/nxp-imx/imx-mkimage.git;protocol=https;branch=${SRCBRANCH}" -SRCBRANCH:ccimx93 = "lf-6.1.36_2.1.0" -SRCREV:ccimx93 = "5a0faefc223e51e088433663b6e7d6fbce89bf59" +SRCBRANCH:ccimx93 = "lf-6.1.55_2.2.0" +SRCREV:ccimx93 = "c4365450fb115d87f245df2864fee1604d97c06a" # "fmacro-prefix-map" is not supported on old versions of GCC DEBUG_PREFIX_MAP:remove:class-nativesdk = "-fmacro-prefix-map=${WORKDIR}=/usr/src/debug/${PN}/${EXTENDPE}${PV}-${PR}"