Other Parts Discussed in Thread: HALCOGEN
Hi,
My customer is developing software and their startup code is based on below file.
\ti\Hercules\SafeTI Diagnostic Library\2.4.0\demo_app\HALCoGen\RM57L843_NoOS\source\HL_sys_startup.c
At the end of _c_int00(), SL_SelfTest_STC(STC1_COMPARE_SELFCHECK, TRUE, &stcSelfTestConfig) is called.
Then, at the end of SL_SelfTest_STC(), _SL_Kickoff_STC_execution() is called and CPU is reset.
This is an expected behavior.
But in customer's system, CPU reset does not happen most of the time (9 times in 10 trials).
Customer did some investigation and found the code reaches properly to _SL_Kickoff_STC_execution(), but no CPU reset is generated.
It seems _SL_Kickoff_STC_execution() does not do anything special according to sl_asm_api.asm.;/* Kick off the STC execution */
.def _SL_Kickoff_STC_execution
.asmFunc
_SL_Kickoff_STC_execution
WFI
MOV R0, R0
MOV R0, R0
MOV R0, R0
MOV R0, R0
MOV R0, R0
B _SL_Kickoff_STC_execution ; This would ensure that the CPU retries WFI
; until LBIST is indeed entered because only the CPU reset from LBIST would exit from this loop.
BX LR ;Though not required, to be safe adding branch here
.endasmfunc
This behavior is observed only when no JTAG is connected.
If JTAG is connected and the code starts from CCS "SYSTEM Reset", the issue does not occur. CPU reset is always generated after _SL_Kickoff_STC_execution().
What is potential cause of such behavior?
Thanks and regards,
Koichiro Tashiro