diff options
author | 2022-04-22 14:21:09 +0200 | |
---|---|---|
committer | 2022-04-22 14:29:07 +0200 | |
commit | 981a13d5be3c923b4286e2f239fe2130c5e50daa (patch) | |
tree | e1194a8a33442293a0e8b1ae2581bfdaa15219ef | |
parent | 7035723f1f8eddea2bb65b2ee23f31dc87d3b98f (diff) | |
download | cortex-m-981a13d5be3c923b4286e2f239fe2130c5e50daa.tar.gz cortex-m-981a13d5be3c923b4286e2f239fe2130c5e50daa.tar.zst cortex-m-981a13d5be3c923b4286e2f239fe2130c5e50daa.zip |
Fix inline assembly.
-rw-r--r-- | cortex-m-rt/src/lib.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/cortex-m-rt/src/lib.rs b/cortex-m-rt/src/lib.rs index 1e977c6..aa0ff34 100644 --- a/cortex-m-rt/src/lib.rs +++ b/cortex-m-rt/src/lib.rs @@ -548,7 +548,7 @@ cfg_global_asm! { ldr r1, =__edata ldr r2, =__sidata 2: - cmp r0, r0 + cmp r1, r0 beq 3f ldm r2!, {{r3}} stm r0!, {{r3}} @@ -569,7 +569,8 @@ cfg_global_asm! { // Push `lr` to the stack for debuggers, to prevent them unwinding past Reset. // See https://sourceware.org/binutils/docs/as/CFI-directives.html. - ".cfi_def_cfa sp, 0 + "4: + .cfi_def_cfa sp, 0 push {{lr}} .cfi_offset lr, 0", |