diff --git a/arch/arm/core/cortex_m/reset.S b/arch/arm/core/cortex_m/reset.S index e80d7f5f4f2..631b1076639 100644 --- a/arch/arm/core/cortex_m/reset.S +++ b/arch/arm/core/cortex_m/reset.S @@ -79,6 +79,11 @@ SECTION_SUBSEC_FUNC(TEXT,_reset_section,__start) msr BASEPRI, r0 #endif +#ifdef CONFIG_WDOG_INIT + /* board-specific watchdog initialization is necessary */ + bl _WdogInit +#endif + #ifdef CONFIG_INIT_STACKS ldr r0, =_interrupt_stack ldr r1, =0xaa @@ -97,11 +102,6 @@ SECTION_SUBSEC_FUNC(TEXT,_reset_section,__start) movs.n r0, #2 /* switch to using PSP (bit1 of CONTROL reg) */ msr CONTROL, r0 -#ifdef CONFIG_WDOG_INIT - /* board-specific watchdog initialization is necessary */ - bl _WdogInit -#endif - b _PrepC #if defined(CONFIG_SOC_TI_LM3S6965_QEMU)