Hello support team,
I am using a StarterWare example to test switching between User Mode and System Mode.
Therfore I call CPUSwitchToUserMode() and CPUSwitchToPrivilegedMode().
The function CPUSwitchToPrivilegedMode() raises an exception with the SWI instruction. Then I observe a very strange behavior. The CPU jumps to the SVC_Handler function, defined in exceptionhandler.asm, but the code is not executed. Instead the CPU jumps right back to the caller. So the CPU remains in User Mode (10000). It's not possible to switch back into System Mode (11111). Unfortunately there is no example in the StarterWare, where these functions are used.
If I have to use the security extension to switch between unsecure state and secure state, independent exception vector tables are required. In the StarterWare the unsecure vector table is set in startup.c. If somebody ever used these functions, I would like to know the results.
(I use the CCS5.5 with a Beaglebone black and AM3359)
Thanks in advance,
Stephan