[sw/silicon_creator] Update loop in the asm exception handler
Signed-off-by: Alphan Ulusoy <alphan@google.com>
diff --git a/sw/device/silicon_creator/lib/irq_asm.S b/sw/device/silicon_creator/lib/irq_asm.S
index 29af854..8163187 100644
--- a/sw/device/silicon_creator/lib/irq_asm.S
+++ b/sw/device/silicon_creator/lib/irq_asm.S
@@ -18,11 +18,12 @@
* Exception handler that is safe to call before the C runtime has been
* initialized. It must not use the stack or global pointer.
*
- * The exception handler will use the watchdog timer to trigger a reset.
+ * The exception handler will use the reset manager to trigger a reset.
*/
.globl _asm_exception_handler
.type _asm_exception_handler, @function
_asm_exception_handler:
+.L_exception_loop:
// Request a system reset.
li t0, TOP_EARLGREY_RSTMGR_AON_BASE_ADDR
li t1, MULTIBIT_ASM_BOOL4_TRUE
@@ -35,10 +36,8 @@
li t0, TOP_EARLGREY_FLASH_CTRL_CORE_BASE_ADDR
sw zero, FLASH_CTRL_DIS_REG_OFFSET(t0)
- // Enter a wait for interrupt loop, the device should reset shortly.
-.L_wfi_loop:
wfi
- j .L_wfi_loop
+ j .L_exception_loop
// Set size so this function can be disassembled.
.size _asm_exception_handler, .-_asm_exception_handler