diff options
-rw-r--r-- | secure_fw/spm/cmsis_psa/spm_ipc.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/secure_fw/spm/cmsis_psa/spm_ipc.c b/secure_fw/spm/cmsis_psa/spm_ipc.c index b3fd61cef9..1642626eab 100644 --- a/secure_fw/spm/cmsis_psa/spm_ipc.c +++ b/secure_fw/spm/cmsis_psa/spm_ipc.c @@ -761,6 +761,21 @@ uint32_t tfm_spm_init(void) platform_data_p = POSITION_TO_PTR(p_asset_load[i].dev.addr_ref, struct platform_data_t *); + + /* + * TODO: some partitions declare MMIO not exist on specific + * platforms, and the platform defines a dummy NULL reference + * for these MMIO items, which cause 'nassets' to contain several + * NULL items. Skip these NULL items initialization temporarily to + * avoid HAL API panic. + * Eventually, these platform-specific partitions need to be moved + * into a platform-specific folder. Then this workaround can be + * removed. + */ + if (!platform_data_p) { + continue; + } + #ifdef TFM_FIH_PROFILE_ON FIH_CALL(tfm_spm_hal_configure_default_isolation, fih_rc, part_idx, platform_data_p); |