Hi,
We're using i.MX 6SX based custom board with QSPI boot medium with U-Boot 2021.04. While enabling HAB support (CONFIG_IMX_HAB), booting stops abruptly.
The detailed error message is as follows:
U-Boot 2021.04-20220224+g83a8c869aa (Feb 24 2022 - 09:15:35 +0000)
CPU: i.MX6SX rev1.3 996 MHz (running at 792 MHz)
CPU: Extended Commercial temperature grade (-20C to 105C) at 53C
Reset cause: POR
DRAM: 1 GiB
bind node caam@2100000
- attempt to match compatible string 'fsl,sec-v4.0'
- found match at 'caam_jr': 'fsl,sec-v4.0' matches 'fsl,sec-v4.0'
Error binding driver 'caam_jr': -96
caam@2100000: ret=-96
bind node aips-bus@2200000
- attempt to match compatible string 'fsl,aips-bus'
- attempt to match compatible string 'simple-bus'
- found match at 'simple_bus': 'simple-bus' matches 'simple-bus'
bind node spba-bus@2240000
- attempt to match compatible string 'fsl,spba-bus'
- attempt to match compatible string 'simple-bus'
- found match at 'simple_bus': 'simple-bus' matches 'simple-bus'
bind node pcie@8ffc000
- attempt to match compatible string 'fsl,imx6sx-pcie'
- found match at 'imx_pcie': 'fsl,imx6q-pcie' matches 'fsl,imx6sx-pcie'
Some drivers failed to bind
Error binding driver 'simple_bus': -96
soc: ret=-96
Some drivers failed to bind
dm_scan_fdt() failed: -96
dm_extended_scan() failed: -96
dm_scan() failed: -96
initcall sequence bffa5ca0 failed at call 878138c9 (err=-96)
### ERROR ### Please RESET the board ###
Any help with this would be grateful. Thank in advance.
I managed to solve this issue by studying the changes made in this commit https://source.codeaurora.org/external/imx/uboot-imx/commit/?id=41a325b1e324160b6be96ff54083b655a292...
For my target HW called prototype (imx8mn based) I had to make these changes:
diff --git a/arch/arm/mach-imx/imx8m/Kconfig b/arch/arm/mach-imx/imx8m/Kconfig index 9a733ae0d4..0460349dce 100644 --- a/arch/arm/mach-imx/imx8m/Kconfig +++ b/arch/arm/mach-imx/imx8m/Kconfig @@ -253,6 +253,10 @@ config TARGET_PROTOTYPE select IMX8MN select SUPPORT_SPL select IMX8M_LPDDR4 + select FSL_CAAM + select FSL_BLOB + select MISC + select SPL_CRYPTO_SUPPORT if SPL config TARGET_PHYCORE_IMX8MM bool "PHYTEC PHYCORE i.MX8MM"
diff --git a/board/freescale/prototype/spl.c b/board/freescale/prototype/spl.c index b5c7f2ad3f..95a904842b 100644 --- a/board/freescale/prototype/spl.c +++ b/board/freescale/prototype/spl.c @@ -219,6 +219,14 @@ int power_init_board(void) void spl_board_init(void) { + struct udevice *dev; + uclass_find_first_device(UCLASS_MISC, &dev); + + for (; dev; uclass_find_next_device(&dev)) { + if (device_probe(dev)) + continue; + } + puts("Normal Boot\n"); }
Further debugging revealed more details as follows:
bind node caam@2100000
- attempt to match compatible string 'fsl,sec-v4.0'
- found match at 'caam_jr': 'fsl,sec-v4.0' matches 'fsl,sec-v4.0'
Cannot find uclass for id 54: please add the UCLASS_DRIVER() declaration for this UCLASS_... id
Missing uclass for driver caam_jr
Error binding driver 'caam_jr': -96
Also note the difference when grepping for "caam_jr" EVK vs custom board:
Hoping these are helpful to debug & answer
@Yuri @jamesbone where can we refer the Error code -96 on U-Boot source? Is it specific to NXP processors? What does it imply?
We've posted in similar issue: https://community.nxp.com/t5/i-MX-Processors/U-boot-CAAM-Secure-Boot-issue/m-p/1419108/highlight/tru...
Thought it could be helpful.