I was wondering is the coresight trace available in secure world? I was trying to use non-invasive coresight to capture the trace while my trusted application running as the debug method. But seems like the coresight never generate trace after the Cortex A57 core switches from normal world to secure world.
There are some prerequisites I think I already met.
- I’m using Jetson TX2 NX. The fuses are not blown(SPIDEN, SPNIDEN, DEVICEEN). I have checked through sysfs. The DBGAUTHSTATUS_EL1 value is 0xff as well.
- I have turned off the Denver cores before I enable the coresight ETM/PTM.
- I also tied the CA to specific Cortex A57 before I enable tracing so that the SMC call will be preformed on this core and TA will run on this core. I also changed the ATF code to output the CPU affinity register value just in case.
- The coresight can generate trace in normal world perfectly fine. I can dump the trace from FIFO sysfs and decode it. Only the secure world trace are missing.
Is there any hardware limitation done by NVIDIA or some configuration I missed so that tracing in secure world is impossible? Cause ARM ETM specification definitely allows this use case as long as the authentication signals are enabled.