commit 72ca57982ee42e75390b6c4e9c6e8df7f04d40c8
parent 241b3584574db84a622a448f0939d36b8eff7f14
Author: Matsuda Kenji <info@mtkn.jp>
Date: Thu, 6 Apr 2023 11:00:06 +0900
delete unnecessary instructions
Diffstat:
1 file changed, 5 insertions(+), 10 deletions(-)
diff --git a/boot2/boot2.S b/boot2/boot2.S
@@ -7,8 +7,6 @@
.equ PPB_BASE, 0xe0000000
boot2:
- push {r4, lr}
-
ldr r4, =PADS_QSPI_BASE
ldr r1, =(2 << 4 | 1) // 8mA, slew fast
str r1, [r4, #0x4] // PADS_QSPI: GPIO_QSPI_SCLK
@@ -104,17 +102,14 @@ wait_sreg:
str r1, [r4, #0x8] // SSI: SSIENR
// exit from boot2
- pop {r4}
- pop {r0}
- cmp r0, #0
- beq vector_into_flash
- bx r0
-vector_into_flash:
ldr r0, =(XIP_BASE + 0x100)
ldr r1, =(PPB_BASE + 0xed08)
str r0, [r1, #0] // M0PLUS: VTOR
- ldmia r0, {r0, r1}
- msr msp, r0
+ //ldmia r0, {r0, r1}
+ ldr r1, [r0, #0x4] // entry point
+ ldr r0, [r0, #0] // stack pointer
+ mov sp, r0
+ //msr msp, r0
bx r1
assert_rxd_fifo_empty: