This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Trustzone Address Space controller fault to secure monitor.

Hi,

I'm using a TZC380 (on an i.MX6 board from NXP) along with NXP CSU to protect some part of my DDR ram and some sensitive devices.

For the TZC configuration, I choose an action set to 3: "sets tzasc_int HIGH and issues a DECERR response".

My secure monitor is configured to route Non Secure External Abort to the secure monitor (SCR = 0xd)

I triggered an illegal access from Linux by trying to read a secure address, and I directly jump to the "Data Abort" entry of my secure monitor VBAR.

At this time, if I print the NS DFSR and DFAR, their content doesn't seem relevant to my error, and especially DFSR doesn't have the Ext bit set.

If I print the S DFSR, I get 0x18 -> Synchronous External Abort.

 

I would expect to jump to the NS VBAR Data Abort entry instead of the MBVAR, and in the latter case, I would expect the External Abort bit to be set in the DFSR

 

Is my understanding wrong ? Can someone clarify a bit the situation of what is happening in such a configuration ?

 

Best,

Vincent

Parents
  • Hi Vincent,

    The SCR doesn't differentiate between S and NS aborts so SCR=0xd routes *all* EAs to the monitor mode. So rocking up at the MVBAR offset is expected.

    The DFSR value is weird. Bit12 is zero which can indicate DECERR on A9, which makes sense, but [3:0] indicate a permissions fault on a table walk.

    Have you put page tables in RAM behind the TZC maybe?
Reply
  • Hi Vincent,

    The SCR doesn't differentiate between S and NS aborts so SCR=0xd routes *all* EAs to the monitor mode. So rocking up at the MVBAR offset is expected.

    The DFSR value is weird. Bit12 is zero which can indicate DECERR on A9, which makes sense, but [3:0] indicate a permissions fault on a table walk.

    Have you put page tables in RAM behind the TZC maybe?
Children