File tree Expand file tree Collapse file tree 1 file changed +9
-0
lines changed
src/rp2_common/pico_standard_link Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -225,6 +225,9 @@ _reset_handler:
225
225
cmp r0, #0
226
226
bne hold_non_core0_in_bootrom
227
227
228
+ // In a NO_FLASH binary, don't perform .data copy, since it's loaded
229
+ // in-place by the SRAM load. Still need to clear .bss
230
+ #if !PICO_NO_FLASH
228
231
adr r4, data_cpy_table
229
232
230
233
// assume there is at least one entry
@@ -235,6 +238,7 @@ _reset_handler:
235
238
bl data_cpy
236
239
b 1b
237
240
2:
241
+ #endif
238
242
239
243
// Zero out the BSS
240
244
ldr r1, =__bss_start__
@@ -266,13 +270,18 @@ _exit:
266
270
bkpt #0
267
271
b 1b
268
272
273
+ #if !PICO_NO_FLASH
269
274
data_cpy_loop:
270
275
ldm r1!, {r0}
271
276
stm r2!, {r0}
272
277
data_cpy:
273
278
cmp r2, r3
274
279
blo data_cpy_loop
275
280
bx lr
281
+ #endif
282
+
283
+ // Note the data copy table is still included for NO_FLASH builds, even though
284
+ // we skip the copy, because it is listed in binary info
276
285
277
286
.align 2
278
287
data_cpy_table:
You can’t perform that action at this time.
0 commit comments