esp32s2 riscv ulp: Ensure reset vector is always at offset 0x0

Previous linker script relied on nothing else using the .text section

As reported at https://esp32.com/viewtopic.php?f=2&t=20734&p=75997
This commit is contained in:
Angus Gratton 2021-05-05 17:53:47 +10:00
parent 3dbafb9a13
commit 3ee4370578
2 changed files with 4 additions and 1 deletions

View File

@ -12,6 +12,7 @@ SECTIONS
. = ORIGIN(ram);
.text :
{
*start.S.obj(.text.vectors) /* Default reset vector must link to offset 0x0 */
*(.text)
*(.text*)
} >ram

View File

@ -1,4 +1,4 @@
.section .text
.section .text.vectors
.global irq_vector
.global reset_vector
@ -11,6 +11,8 @@ reset_vector:
irq_vector:
ret
.section .text
__start:
/* setup the stack pointer */
la sp, __stack_top