Hello Toradex support,
I am trying to use secure boot on IMX8MP and Mallow board V1.1. I followed the code-signing-tool from NXP (CST_UG.pdf in cst-3.4.1):
cd keys
./hab4_pki_tree.sh
with rsa, 2048, and 4 keys
cd ../crts
../linux64/bin/srktool -h 4 -t SRK_1_2_3_4_table.bin -e SRK_1_2_3_4_fuse.bin -d sha256 -c SRK1_sha256_2048_65537_v3_usr_crt.pem,SRK2_sha256_2048_65537_v3_usr_crt.pem,SRK3_sha256_2048_65537_v3_usr_crt.pem,SRK4_sha256_2048_65537_v3_usr_crt.pem -f 1
Then, I try to build tdx-reference-multimedia-image using Yocto, modifying local.conf:
# SECURE BOOT
INHERIT += "tdx-signed"
TDX_IMX_HAB_ENABLE = "1"
UBOOT_SIGN_ENABLE = "1"
TDX_IMX_HAB_CST_SRK_CA = "0"
TDX_IMX_HAB_CST_KEY_SIZE = "2048"
TDX_IMX_HAB_CST_DIG_ALGO = "sha256"
TDX_IMX_HAB_CST_DIR = "/home/matej/cst-3.4.1"
TDX_IMX_HAB_CST_CERTS_DIR = "/home/matej/cst-3.4.1/crts"
The build, however, fails. Here is the log:
WARNING: You have included the meta-tpm layer, but 'tpm or tpm2' has not been enabled in your DISTRO_FEATURES. Some bbappend files and preferred version setting may not take effect. See the meta-tpm README for details on enabling tpm support.
WARNING: You have included the meta-security layer, but 'security' has not been enabled in your DISTRO_FEATURES. Some bbappend files and preferred version setting may not take effect. See the meta-security README for details on enabling security support.
WARNING: Host distribution "linuxmint-21.3" has not been validated with this version of the build system; you may possibly experience unexpected failures. It is recommended that you use a tested distribution.
WARNING: No recipes in default available for:
/home/matej/oe-core-imx8mp/build/../layers/meta-toradex-nxp/recipes-bsp/imx-mkimage/imx-mkimage_1.0.bbappend
/home/matej/oe-core-imx8mp/build/../layers/meta-toradex-nxp/recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_1.20.0.imx.bbappend
NOTE: Resolving any missing task queue dependencies
Build Configuration:
BB_VERSION = "2.0.0"
BUILD_SYS = "x86_64-linux"
NATIVELSBSTRING = "universal"
TARGET_SYS = "aarch64-tdx-linux"
MACHINE = "verdin-imx8mp"
DISTRO = "tdx-xwayland"
DISTRO_VERSION = "6.7.0-devel-20250114114651+build.0"
TUNE_FEATURES = "aarch64 armv8a crc cortexa53"
TARGET_FPU = ""
meta-toradex-nxp = "HEAD:92a03e8efa00234026139919789989a11bc7ed58"
meta-freescale = "HEAD:4c81b4161b99698b03332842b588dd8235ac47e4"
meta-freescale-3rdparty = "HEAD:9e94b64bdfebcf7bfdf2af6447cec866a4efa814"
meta-toradex-ti = "HEAD:514cf7550c3873c8011b63e4a52f46223c2ea0f6"
meta-arm-toolchain
meta-arm = "HEAD:260e3adc2bf322f52d81c0642c825088a88bb051"
meta-ti-bsp
meta-ti-extras = "HEAD:c57b63147d2ac0dde16e43f7407d0ff50e62efdb"
meta-toradex-bsp-common = "HEAD:0fc41401fb86fa642f43c103441a81c69498a0ce"
meta-oe
meta-filesystems
meta-gnome
meta-xfce
meta-networking
meta-multimedia
meta-python = "HEAD:8e297cdc841c6cad34097f00a6903ba25edfc153"
meta-freescale-distro = "HEAD:d5bbb487b2816dfc74984a78b67f7361ce404253"
meta-toradex-demos = "HEAD:df4296ba9a5334ac036b2445dd7fe848de9290bb"
meta-qt5 = "HEAD:644ebf220245bdc06e7696ccc90acc97a0dd2566"
meta-tpm = "HEAD:353078bc06c8b471736daab6ed193e30d533d1f1"
meta-toradex-distro = "HEAD:7212583d894bbf5501fb1ff20c131ce485b4e4b7"
meta-poky = "HEAD:6518f291d692997632304451695b6c194fec6fa6"
meta = "HEAD:ab2649ef6c83f0ae7cac554a72e6bea4dcda0e99"
meta-custom = "<unknown>:<unknown>"
meta-perl = "HEAD:8e297cdc841c6cad34097f00a6903ba25edfc153"
meta-security = "HEAD:353078bc06c8b471736daab6ed193e30d533d1f1"
meta-toradex-security = "kirkstone-6.x.y:c05a06c4283beb2ad36e08d22d97eee3d52778f3"
Sstate summary: Wanted 439 Local 430 Mirrors 0 Missed 9 Current 3197 (97% match, 99% complete)
NOTE: Executing Tasks
NOTE: Setscene tasks completed
NOTE: Running task 3899 of 8784 (/home/matej/oe-core-imx8mp/build/../layers/meta-toradex-nxp/recipes-kernel/linux/linux-toradex_5.15-2.2.x.bb:do_package_qa)
NOTE: recipe linux-toradex-5.15.148+gitAUTOINC+f437ddb719-r0: task do_package_qa: Started
NOTE: Running task 8401 of 8784 (/home/matej/oe-core-imx8mp/build/../layers/meta-freescale/recipes-bsp/imx-mkimage/imx-boot_1.0.bb:do_compile)
NOTE: recipe imx-boot-1.0-r0: task do_compile: Started
ERROR: imx-boot-1.0-r0 do_compile: ExecutionError('/home/matej/oe-core-imx8mp/build/tmp/work/verdin_imx8mp-tdx-linux/imx-boot/1.0-r0/temp/run.do_compile.8420', 126, None, None)
ERROR: Logfile of failure stored in: /home/matej/oe-core-imx8mp/build/tmp/work/verdin_imx8mp-tdx-linux/imx-boot/1.0-r0/temp/log.do_compile.8420
NOTE: recipe imx-boot-1.0-r0: task do_compile: Failed
ERROR: Task (/home/matej/oe-core-imx8mp/build/../layers/meta-freescale/recipes-bsp/imx-mkimage/imx-boot_1.0.bb:do_compile) failed with exit code '1'
NOTE: recipe linux-toradex-5.15.148+gitAUTOINC+f437ddb719-r0: task do_package_qa: Succeeded
NOTE: Tasks Summary: Attempted 8759 tasks of which 8757 didn't need to be rerun and 1 failed.
NOTE: Writing buildhistory
NOTE: Writing buildhistory took: 3 seconds
I also include the log file home/matej/oe-core-imx8mp/build/tmp/work/verdin_imx8mp-tdx-linux/imx-boot/1.0-r0/temp/log.do_compile.8420.
log.do_compile.8420 (6.5 KB)
I am not sure the whole process is correct. Do you have any suggestions what may cause the problem?
Thank you.
Best regards
Matej I.