Is it missing to initialise the MPC for Non Secure QSPI address range?
Closed, ResolvedPublic

Description

While Non-Secure Flash range is set in SAU, there is no MPC initialisation for NonSecure QSPI address range.
I am not sure whether it is required but the existing code does not work and even secure execution (before jumping to NS) cannot read the NS address range so tfm_spm_hal_get_ns_entry_point(); function return 0 so secure execution cannot jump to NS.

If we initialise the QSPI_MPC in the mpc_init_cfg() function as below, Secure execution can read the NS range and can get to be jumped address.

Driver_QSPI_MPC.Initialize();
Driver_QSPI_MPC.ConfigRegion(memory_regions.non_secure_partition_base,
                             memory_regions.non_secure_partition_limit,
                             ARM_MPC_ATTR_NONSECURE);
Driver_QSPI_MPC.LockDown();

Existing code somehow enables the QSPI MPC interrupt while no one initialises it.

Are we missing something?

Thanks

zaya-mc created this task.Dec 22 2018, 4:54 PM
zaya-mc updated the task description. (Show Details)Dec 23 2018, 12:46 PM

Hi Murat,

Which board are you using? Musca A?

On Musca A the code is executed for a while form SRAM?

Could you specif board and TF-M version?

Tamas

Hi Tamas,

It makes sense. I think this is the same issue with T-165 ticket. We are running the image from the QSPI (not SRAM) and that's why we needed to release the QSPI address range.
As offered in the T-165, we might add a compiler switch to run from SRAM or QSPI.

It is not a blocker for us just you might consider if it makes sense.

Regards.
Murat

Hi Murat,

Since the discussion is ongoing in T-165, I suggest to close this ticket. Do you agree?

Tamas

HI Tamas, yes let us close this ticket. Thanks.

tamasban closed this task as Resolved.Jan 3 2019, 10:20 AM
tamasban claimed this task.