diff options
| author | Tom Hochstein <tom.hochstein@nxp.com> | 2024-08-20 12:43:40 -0700 |
|---|---|---|
| committer | Tom Hochstein <tom.hochstein@nxp.com> | 2024-08-20 12:55:12 -0700 |
| commit | 9cbfa8f33730e59e8be810ecdd3967738b07380a (patch) | |
| tree | 694e8682dd7547ebf59bc531fe106ac3ef6b8020 | |
| parent | 2db7047ba40efed4d9e7c86c63d71158d974e297 (diff) | |
| download | meta-freescale-9cbfa8f33730e59e8be810ecdd3967738b07380a.tar.gz | |
imx-boot: Update to latest from NXP 6.6.23-2.0.0
- Add i.MX 91 support
- Add missing STMM deploy
Signed-off-by: Tom Hochstein <tom.hochstein@nxp.com>
| -rw-r--r-- | recipes-bsp/imx-mkimage/imx-boot_1.0.bb | 40 |
1 files changed, 32 insertions, 8 deletions
diff --git a/recipes-bsp/imx-mkimage/imx-boot_1.0.bb b/recipes-bsp/imx-mkimage/imx-boot_1.0.bb index 7013d6d1f..83b9ad789 100644 --- a/recipes-bsp/imx-mkimage/imx-boot_1.0.bb +++ b/recipes-bsp/imx-mkimage/imx-boot_1.0.bb | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | # Copyright (C) 2017-2020 NXP | 1 | # Copyright (C) 2017-2024 NXP |
| 2 | 2 | ||
| 3 | require imx-mkimage_git.inc | 3 | require imx-mkimage_git.inc |
| 4 | 4 | ||
| @@ -18,6 +18,7 @@ DEPENDS += " \ | |||
| 18 | # xxd is a dependency of fspi_packer.sh | 18 | # xxd is a dependency of fspi_packer.sh |
| 19 | DEPENDS += "xxd-native" | 19 | DEPENDS += "xxd-native" |
| 20 | DEPENDS:append:mx8m-generic-bsp = " u-boot-mkimage-native dtc-native" | 20 | DEPENDS:append:mx8m-generic-bsp = " u-boot-mkimage-native dtc-native" |
| 21 | DEPENDS:append:mx93-generic-bsp = " u-boot-mkimage-native dtc-native" | ||
| 21 | BOOT_NAME = "imx-boot" | 22 | BOOT_NAME = "imx-boot" |
| 22 | PROVIDES = "${BOOT_NAME}" | 23 | PROVIDES = "${BOOT_NAME}" |
| 23 | 24 | ||
| @@ -52,6 +53,7 @@ TOOLS_NAME ?= "mkimage_imx8" | |||
| 52 | IMX_BOOT_SOC_TARGET ?= "INVALID" | 53 | IMX_BOOT_SOC_TARGET ?= "INVALID" |
| 53 | 54 | ||
| 54 | DEPLOY_OPTEE = "${@bb.utils.contains('MACHINE_FEATURES', 'optee', 'true', 'false', d)}" | 55 | DEPLOY_OPTEE = "${@bb.utils.contains('MACHINE_FEATURES', 'optee', 'true', 'false', d)}" |
| 56 | DEPLOY_OPTEE_STMM = "${@bb.utils.contains('MACHINE_FEATURES', 'optee stmm', 'true', 'false', d)}" | ||
| 55 | 57 | ||
| 56 | IMXBOOT_TARGETS ?= \ | 58 | IMXBOOT_TARGETS ?= \ |
| 57 | "${@bb.utils.contains('UBOOT_CONFIG', 'fspi', 'flash_flexspi', \ | 59 | "${@bb.utils.contains('UBOOT_CONFIG', 'fspi', 'flash_flexspi', \ |
| @@ -61,8 +63,8 @@ IMXBOOT_TARGETS ?= \ | |||
| 61 | BOOT_STAGING = "${S}/${IMX_BOOT_SOC_TARGET}" | 63 | BOOT_STAGING = "${S}/${IMX_BOOT_SOC_TARGET}" |
| 62 | BOOT_STAGING:mx8m-generic-bsp = "${S}/iMX8M" | 64 | BOOT_STAGING:mx8m-generic-bsp = "${S}/iMX8M" |
| 63 | BOOT_STAGING:mx8dx-generic-bsp = "${S}/iMX8QX" | 65 | BOOT_STAGING:mx8dx-generic-bsp = "${S}/iMX8QX" |
| 64 | BOOT_STAGING:mx91p-generic-bsp = "${S}/iMX91" | 66 | BOOT_STAGING:mx91-generic-bsp = "${S}/iMX91" |
| 65 | BOOT_STAGING:mx93-generic-bsp = "${S}/iMX93" | 67 | BOOT_STAGING:mx93-generic-bsp = "${S}/iMX93" |
| 66 | BOOT_STAGING:mx95-generic-bsp = "${S}/iMX95" | 68 | BOOT_STAGING:mx95-generic-bsp = "${S}/iMX95" |
| 67 | 69 | ||
| 68 | SOC_FAMILY = "INVALID" | 70 | SOC_FAMILY = "INVALID" |
| @@ -70,7 +72,7 @@ SOC_FAMILY:mx8-generic-bsp = "mx8" | |||
| 70 | SOC_FAMILY:mx8m-generic-bsp = "mx8m" | 72 | SOC_FAMILY:mx8m-generic-bsp = "mx8m" |
| 71 | SOC_FAMILY:mx8x-generic-bsp = "mx8x" | 73 | SOC_FAMILY:mx8x-generic-bsp = "mx8x" |
| 72 | SOC_FAMILY:mx8ulp-generic-bsp = "mx8ulp" | 74 | SOC_FAMILY:mx8ulp-generic-bsp = "mx8ulp" |
| 73 | SOC_FAMILY:mx91p-generic-bsp = "mx93" | 75 | SOC_FAMILY:mx91-generic-bsp = "mx91" |
| 74 | SOC_FAMILY:mx93-generic-bsp = "mx93" | 76 | SOC_FAMILY:mx93-generic-bsp = "mx93" |
| 75 | SOC_FAMILY:mx95-generic-bsp = "mx95" | 77 | SOC_FAMILY:mx95-generic-bsp = "mx95" |
| 76 | 78 | ||
| @@ -153,6 +155,11 @@ compile_mx8ulp() { | |||
| 153 | fi | 155 | fi |
| 154 | } | 156 | } |
| 155 | 157 | ||
| 158 | compile_mx91() { | ||
| 159 | bbnote i.MX 91 boot binary build | ||
| 160 | compile_mx93 | ||
| 161 | } | ||
| 162 | |||
| 156 | compile_mx93() { | 163 | compile_mx93() { |
| 157 | bbnote i.MX 93 boot binary build | 164 | bbnote i.MX 93 boot binary build |
| 158 | for ddr_firmware in ${DDR_FIRMWARE_NAME}; do | 165 | for ddr_firmware in ${DDR_FIRMWARE_NAME}; do |
| @@ -219,21 +226,26 @@ do_compile() { | |||
| 219 | 226 | ||
| 220 | for target in ${IMXBOOT_TARGETS}; do | 227 | for target in ${IMXBOOT_TARGETS}; do |
| 221 | compile_${SOC_FAMILY} | 228 | compile_${SOC_FAMILY} |
| 222 | if [ "$target" = "flash_linux_m4_no_v2x" ]; then | 229 | case $target in |
| 230 | *no_v2x) | ||
| 223 | # Special target build for i.MX 8DXL with V2X off | 231 | # Special target build for i.MX 8DXL with V2X off |
| 224 | bbnote "building ${IMX_BOOT_SOC_TARGET} - ${REV_OPTION} V2X=NO ${target}" | 232 | bbnote "building ${IMX_BOOT_SOC_TARGET} - ${REV_OPTION} V2X=NO ${target}" |
| 225 | make SOC=${IMX_BOOT_SOC_TARGET} ${REV_OPTION} V2X=NO dtbs=${UBOOT_DTB_NAME_EXTRA} flash_linux_m4 | 233 | make SOC=${IMX_BOOT_SOC_TARGET} ${REV_OPTION} V2X=NO dtbs=${UBOOT_DTB_NAME_EXTRA} flash_linux_m4 |
| 226 | elif [[ $target == *sttm_capsule ]]; then | 234 | ;; |
| 235 | *stmm_capsule) | ||
| 227 | # target for flash_evk_stmm_capsule or | 236 | # target for flash_evk_stmm_capsule or |
| 228 | # flash_singleboot_stmm_capsule | 237 | # flash_singleboot_stmm_capsule |
| 229 | cp ${RECIPE_SYSROOT_NATIVE}/${bindir}/mkeficapsule ${BOOT_STAGING} | 238 | cp ${RECIPE_SYSROOT_NATIVE}/${bindir}/mkeficapsule ${BOOT_STAGING} |
| 230 | bbnote "building ${IMX_BOOT_SOC_TARGET} - TEE=tee.bin-stmm ${target}" | 239 | bbnote "building ${IMX_BOOT_SOC_TARGET} - TEE=tee.bin-stmm ${target}" |
| 231 | cp ${DEPLOY_DIR_IMAGE}/CRT.* ${BOOT_STAGING} | 240 | cp ${DEPLOY_DIR_IMAGE}/CRT.* ${BOOT_STAGING} |
| 232 | make SOC=${IMX_BOOT_SOC_TARGET} TEE=tee.bin-stmm dtbs=${UBOOT_DTB_NAME} ${REV_OPTION} ${target} | 241 | make SOC=${IMX_BOOT_SOC_TARGET} TEE=tee.bin-stmm dtbs=${UBOOT_DTB_NAME} ${REV_OPTION} ${target} |
| 233 | else | 242 | ;; |
| 243 | *) | ||
| 234 | bbnote "building ${IMX_BOOT_SOC_TARGET} - ${REV_OPTION} ${MKIMAGE_EXTRA_ARGS} ${target}" | 244 | bbnote "building ${IMX_BOOT_SOC_TARGET} - ${REV_OPTION} ${MKIMAGE_EXTRA_ARGS} ${target}" |
| 235 | make SOC=${IMX_BOOT_SOC_TARGET} ${REV_OPTION} ${MKIMAGE_EXTRA_ARGS} dtbs=${UBOOT_DTB_NAME} ${target} | 245 | make SOC=${IMX_BOOT_SOC_TARGET} ${REV_OPTION} ${MKIMAGE_EXTRA_ARGS} dtbs=${UBOOT_DTB_NAME} ${target} |
| 236 | fi | 246 | ;; |
| 247 | esac | ||
| 248 | |||
| 237 | if [ -e "${BOOT_STAGING}/flash.bin" ]; then | 249 | if [ -e "${BOOT_STAGING}/flash.bin" ]; then |
| 238 | cp ${BOOT_STAGING}/flash.bin ${S}/${BOOT_CONFIG_MACHINE_EXTRA}-${target} | 250 | cp ${BOOT_STAGING}/flash.bin ${S}/${BOOT_CONFIG_MACHINE_EXTRA}-${target} |
| 239 | fi | 251 | fi |
| @@ -316,6 +328,10 @@ deploy_mx8ulp() { | |||
| 316 | fi | 328 | fi |
| 317 | } | 329 | } |
| 318 | 330 | ||
| 331 | deploy_mx91() { | ||
| 332 | deploy_mx93 | ||
| 333 | } | ||
| 334 | |||
| 319 | deploy_mx93() { | 335 | deploy_mx93() { |
| 320 | install -d ${DEPLOYDIR}/${BOOT_TOOLS} | 336 | install -d ${DEPLOYDIR}/${BOOT_TOOLS} |
| 321 | 337 | ||
| @@ -353,6 +369,14 @@ do_deploy() { | |||
| 353 | # copy makefile (soc.mak) for reference | 369 | # copy makefile (soc.mak) for reference |
| 354 | install -m 0644 ${BOOT_STAGING}/soc.mak ${DEPLOYDIR}/${BOOT_TOOLS} | 370 | install -m 0644 ${BOOT_STAGING}/soc.mak ${DEPLOYDIR}/${BOOT_TOOLS} |
| 355 | 371 | ||
| 372 | # copy stmm files to deploy path | ||
| 373 | if ${DEPLOY_OPTEE_STMM}; then | ||
| 374 | install -m 0644 ${BOOT_STAGING}/tee.bin-stmm ${DEPLOYDIR}/${BOOT_TOOLS} | ||
| 375 | install -m 0644 ${BOOT_STAGING}/capsule1.bin ${DEPLOYDIR}/${BOOT_TOOLS} | ||
| 376 | install -m 0644 ${BOOT_STAGING}/CRT.* ${DEPLOYDIR}/${BOOT_TOOLS} | ||
| 377 | install -m 0755 ${BOOT_STAGING}/mkeficapsule ${DEPLOYDIR}/${BOOT_TOOLS} | ||
| 378 | fi | ||
| 379 | |||
| 356 | for type in ${UBOOT_CONFIG}; do | 380 | for type in ${UBOOT_CONFIG}; do |
| 357 | UBOOT_CONFIG_EXTRA="$type" | 381 | UBOOT_CONFIG_EXTRA="$type" |
| 358 | UBOOT_NAME_EXTRA="u-boot-${MACHINE}.bin-${UBOOT_CONFIG_EXTRA}" | 382 | UBOOT_NAME_EXTRA="u-boot-${MACHINE}.bin-${UBOOT_CONFIG_EXTRA}" |
