Skip to content

Commit 5b4125f

Browse files
committed
[cortex-m] Fix too far branch in reset handler
1 parent 13e35ea commit 5b4125f

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/modm/platform/core/cortex/reset_handler.sx.in

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
.syntax unified
1515
.align 4
1616
.type Reset_Handler, %function
17-
.func Reset_Handler
17+
.func Reset_Handler
1818
Reset_Handler:
1919
// Some bootloaders do not reset the stack pointer back to the VTOR entry
2020
ldr r0,=__main_stack_top
@@ -32,5 +32,6 @@ Reset_Handler:
3232
%% endif
3333
bl __modm_initialize_platform
3434
bl modm_initialize_platform
35-
b __modm_startup
35+
ldr r0,=__modm_startup
36+
bx r0
3637
.endfunc

0 commit comments

Comments
 (0)