Secure world logs

Hi,
While running inside normal world kernel, when i invoke smc call to perform some function inside secure world. How can i see the logs from secure os?

Thanks

hello beckrakesh,

please refer to the flags DEBUG_LOAD_TRUSTY_APP for enable debug messages in the trusty_app.
thanks

$L4T_Sources/r32.4.3/Linux_for_Tegra/source/public/trusty/lk/trusty/lib/trusty/trusty_app.c

I have enable the define of DEBUG_LOAD_TRUSTY_APP in " $L4T_Sources/r32.4.3/Linux_for_Tegra/source/public/trusty/lk/trusty/lib/trusty/trusty_app.c",
but I can’t see any logs in normal world.
Can you give me an example or detailed step-by-step instructions?

Thanks

Hi,
I have enabled the define of DEBUG_LOAD_TRUSTY_APP in " $L4T_Sources/r32.4.3/Linux_for_Tegra/source/public/trusty/lk/trusty/lib/trusty/trusty_app.c ",
but I can’t see any logs in normal world. How can see the logs from secure os in normal world? Any experiences?

if you are doing smc call directly then you won’t be able to see the logs.

Secure world logs are stored maybe in buffer and needs to be flushed to normal world so that it will be appended in dmesg logs. This is weird, i still don’t know why. UART also doesn’t show the logs.

If you want to see how this flushing happens from SW to NW, see /public_sources/kernel_src/kernel/nvidia/drivers/trusty/trusty-log.c

I use one trick to get the logs ;)

  1. Call your SMC
  2. Call a trusted application in trusty such as tipc-test
    you will be able to see the logs from SW in your dmesg logs.

Reason for this is, when you call trusted app, it internally calls smc for flushing logs inside SW into NW.

Hope this helps.

Very very thank you!
I see the logs in dmesg. ;)

I have a another question:
Can I store files in trusty as normal world? I know YES according to the android aosp trusty(trusty/app/storage - Git at Google), But while I compile jetson trusty_src with “storage-unittest” , failed.