soc: espressif: fix optimization flag boot fault

When DEBUG_OPTIMIZATION or NO_OPTIMIZATION is
enabled, efuse reading fails during bootloader start.
Move those calls into IRAM area so that reading when
cache is disabled works without any faults.

In HAL side, we need to use low level calls to read
CPU id instead of Zephyr's default one.

Signed-off-by: Sylvio Alves <sylvio.alves@espressif.com>
This commit is contained in:
Sylvio Alves 2025-02-23 23:27:51 -03:00 committed by Benjamin Cabé
commit 1903a8f415
7 changed files with 7 additions and 8 deletions

View file

@ -398,6 +398,7 @@ SECTIONS
*libzephyr.a:esp_psram_impl_octal.*(.literal .literal.* .text .text.*)
/* [mapping:hal] */
*libzephyr.a:efuse_hal.*(.literal .text .literal.* .text.*)
*libzephyr.a:mmu_hal.*(.literal .text .literal.* .text.*)
*libzephyr.a:spi_flash_hal_iram.*(.literal .text .literal.* .text.*)
*libzephyr.a:spi_flash_encrypt_hal_iram.*(.literal .text .literal.* .text.*)