STM32H533RE-Issue while jumping from NonSecure world to Secure world
I am currently working on an STM32 TrustZone project and trying to implement the following flow:
NonSecure world running
↓
Calls Secure_add()
↓
Secure world executes
↓
Returns value 8
↓
UART prints the result in NonSecure world
However, I am facing an issue while jumping from the NonSecure world to the Secure world. The expected secure function execution is not happening properly.
If anyone has faced a similar issue or has suggestions regarding NSC gateway configuration, linker settings, or TrustZone function calls, please share your insights.

this much i am getting the out
CMSE_NS_ENTRY uint32_t Secure_add(uint32_t a, uint32_t b)
{
return a + b;
} ------------------------ My Nsc.c entry logic
for(int i = 0; i < 5; i++)
{
printf("NONSECURE WORLD RUNNING\r\n");
printf("I am amritha\r\n");
//for(volatile int d=0; d<500000; d++);
}
uint32_t result;
printf("Before Secure_add\r\n");
result = Secure_add(5,3);
printf("Before Secure_add\r\n");
printf("Secure result = %lu\r\n", result); -------------------------my non secure main.c
