diff options
author | Aidan MacDonald <amachronic@protonmail.com> | 2022-05-17 16:29:18 +0100 |
---|---|---|
committer | Aidan MacDonald <amachronic@protonmail.com> | 2022-05-22 07:16:11 -0400 |
commit | 5ee9a451266b0b8616435319f43e874932d2a237 (patch) | |
tree | 6f9e0050a83490fe327b9843d88f98a6cf9c3cd9 | |
parent | 981e9728390b401404c36241e2ce6bd4cfcb723d (diff) | |
download | rockbox-5ee9a45126.tar.gz rockbox-5ee9a45126.zip |
mips: stop backtraces at main()
Initialize ra=0 before calling main so backtraces don't walk
through the startup code.
Change-Id: Ia8796ce38b32d14025b47b3e00061267ee25cbaf
-rw-r--r-- | firmware/target/mips/ingenic_jz47xx/crt0.S | 2 | ||||
-rw-r--r-- | firmware/target/mips/ingenic_x1000/crt0.S | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/firmware/target/mips/ingenic_jz47xx/crt0.S b/firmware/target/mips/ingenic_jz47xx/crt0.S index 258a5c02fc..1652bea8e5 100644 --- a/firmware/target/mips/ingenic_jz47xx/crt0.S +++ b/firmware/target/mips/ingenic_jz47xx/crt0.S @@ -185,7 +185,7 @@ _irq_stack_loop: jal system_main /* Init clocks etc first */ ssnop j main - ssnop + move ra, zero /* init backtrace root */ /* diff --git a/firmware/target/mips/ingenic_x1000/crt0.S b/firmware/target/mips/ingenic_x1000/crt0.S index d079b01e2a..9d89ac1227 100644 --- a/firmware/target/mips/ingenic_x1000/crt0.S +++ b/firmware/target/mips/ingenic_x1000/crt0.S @@ -110,7 +110,7 @@ _realstart: jal system_early_init nop j main - nop + move ra, zero /* init backtrace root */ /* copy(void* src, void* dst, void* dst_end) */ _copy: |