This is an automated email from the ASF dual-hosted git repository. xiaoxiang pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/nuttx.git
The following commit(s) were added to refs/heads/master by this push: new 08fe636001 xtensa/esp32[s2|c3|c6|h2]: fix sched_[lock|unlock] boot crash 08fe636001 is described below commit 08fe63600137fb43fb61ab7b9a7efadad37fa574 Author: Tiago Medicci Serrano <tiago.medi...@espressif.com> AuthorDate: Fri Jan 31 15:38:57 2025 -0300 xtensa/esp32[s2|c3|c6|h2]: fix sched_[lock|unlock] boot crash Move the code to iram0 since sched_lock/sched_unlock is called in the early boot phase. --- boards/risc-v/esp32c3/common/scripts/esp32c3_sections.ld | 4 ++++ boards/risc-v/esp32c6/common/scripts/esp32c6_sections.ld | 4 ++++ boards/risc-v/esp32h2/common/scripts/esp32h2_sections.ld | 4 ++++ boards/xtensa/esp32s2/common/scripts/esp32s2_sections.ld | 9 +++++++++ 4 files changed, 21 insertions(+) diff --git a/boards/risc-v/esp32c3/common/scripts/esp32c3_sections.ld b/boards/risc-v/esp32c3/common/scripts/esp32c3_sections.ld index 0832895a3b..84f3bb94c3 100644 --- a/boards/risc-v/esp32c3/common/scripts/esp32c3_sections.ld +++ b/boards/risc-v/esp32c3/common/scripts/esp32c3_sections.ld @@ -74,6 +74,8 @@ SECTIONS *(.iram1.*) *libsched.a:irq_dispatch.*(.text .text.* .literal .literal.*) + *libsched.a:sched_lock.*(.text .text.* .literal .literal.*) + *libsched.a:sched_unlock.*(.text .text.* .literal .literal.*) *libarch.a:*(.text.esprv_intc_int_get_type .literal.esprv_intc_int_get_type) *libarch.a:*riscv_doirq.*(.text .text.* .literal .literal.*) @@ -194,6 +196,8 @@ SECTIONS *(.dram1.*) *libsched.a:irq_dispatch.*(.rodata .rodata.*) + *libsched.a:sched_lock.*(.rodata .rodata.*) + *libsched.a:sched_unlock.*(.rodata .rodata.*) *libarch.a:*(.rodata.esprv_intc_int_get_type) *libarch.a:*riscv_doirq.*(.rodata .rodata.*) diff --git a/boards/risc-v/esp32c6/common/scripts/esp32c6_sections.ld b/boards/risc-v/esp32c6/common/scripts/esp32c6_sections.ld index 9114aa39c5..33be8f79ae 100644 --- a/boards/risc-v/esp32c6/common/scripts/esp32c6_sections.ld +++ b/boards/risc-v/esp32c6/common/scripts/esp32c6_sections.ld @@ -74,6 +74,8 @@ SECTIONS *(.iram1.*) *libsched.a:irq_dispatch.*(.text .text.* .literal .literal.*) + *libsched.a:sched_lock.*(.text .text.* .literal .literal.*) + *libsched.a:sched_unlock.*(.text .text.* .literal .literal.*) *libarch.a:*(.text.esprv_intc_int_get_type .literal.esprv_intc_int_get_type) *libarch.a:*riscv_doirq.*(.text .text.* .literal .literal.*) @@ -218,6 +220,8 @@ SECTIONS *(.dram1.*) *libsched.a:irq_dispatch.*(.rodata .rodata.*) + *libsched.a:sched_lock.*(.rodata .rodata.*) + *libsched.a:sched_unlock.*(.rodata .rodata.*) *libarch.a:*(.rodata.esprv_intc_int_get_type) *libarch.a:*riscv_doirq.*(.rodata .rodata.*) diff --git a/boards/risc-v/esp32h2/common/scripts/esp32h2_sections.ld b/boards/risc-v/esp32h2/common/scripts/esp32h2_sections.ld index e6af8045f7..dbb9fb5630 100644 --- a/boards/risc-v/esp32h2/common/scripts/esp32h2_sections.ld +++ b/boards/risc-v/esp32h2/common/scripts/esp32h2_sections.ld @@ -74,6 +74,8 @@ SECTIONS *(.iram1.*) *libsched.a:irq_dispatch.*(.text .text.* .literal .literal.*) + *libsched.a:sched_lock.*(.text .text.* .literal .literal.*) + *libsched.a:sched_unlock.*(.text .text.* .literal .literal.*) *libarch.a:*(.text.esprv_intc_int_get_type .literal.esprv_intc_int_get_type) *libarch.a:*riscv_doirq.*(.text .text.* .literal .literal.*) @@ -213,6 +215,8 @@ SECTIONS *(.dram1.*) *libsched.a:irq_dispatch.*(.rodata .rodata.*) + *libsched.a:sched_lock.*(.rodata .rodata.*) + *libsched.a:sched_unlock.*(.rodata .rodata.*) *libarch.a:*(.rodata.esprv_intc_int_get_type) *libarch.a:*riscv_doirq.*(.rodata .rodata.*) diff --git a/boards/xtensa/esp32s2/common/scripts/esp32s2_sections.ld b/boards/xtensa/esp32s2/common/scripts/esp32s2_sections.ld index 8e995abba3..130fa80587 100644 --- a/boards/xtensa/esp32s2/common/scripts/esp32s2_sections.ld +++ b/boards/xtensa/esp32s2/common/scripts/esp32s2_sections.ld @@ -172,6 +172,11 @@ SECTIONS *libarch.a:*cpu_region_protect.*(.text .text.* .literal .literal.*) *libc.a:sq_remlast.*(.literal .text .literal.* .text.*) + + *libsched.a:irq_dispatch.*(.text .text.* .literal .literal.*) + *libsched.a:sched_lock.*(.text .text.* .literal .literal.*) + *libsched.a:sched_unlock.*(.text .text.* .literal .literal.*) + *(.wifirxiram .wifirxiram.*) *(.wifi0iram .wifi0iram.*) *(.wifiorslpiram .wifiorslpiram.*) @@ -319,6 +324,10 @@ SECTIONS *libarch.a:*log_noos.*(.rodata .rodata.*) *libarch.a:*cpu_region_protect.*(.rodata .rodata.*) + *libsched.a:irq_dispatch.*(.rodata .rodata.*) + *libsched.a:sched_lock.*(.rodata .rodata.*) + *libsched.a:sched_unlock.*(.rodata .rodata.*) + . = ALIGN(4); _edata = ABSOLUTE(.); _data_end = ABSOLUTE(.);