diff --git a/components/esp_driver_spi/Kconfig b/components/esp_driver_spi/Kconfig index a62838aec3..b2a106fed1 100644 --- a/components/esp_driver_spi/Kconfig +++ b/components/esp_driver_spi/Kconfig @@ -24,7 +24,6 @@ menu "ESP-Driver:SPI Configurations" default y depends on !HEAP_PLACE_FUNCTION_INTO_FLASH select PERIPH_CTRL_FUNC_IN_IRAM - select HAL_SPI_MASTER_FUNC_IN_IRAM select ESP_SPI_BUS_LOCK_ISR_FUNCS_IN_IRAM select GDMA_CTRL_FUNC_IN_IRAM if SOC_GDMA_SUPPORTED help @@ -54,7 +53,6 @@ menu "ESP-Driver:SPI Configurations" bool "Place SPI slave ISR function into IRAM" default y select PERIPH_CTRL_FUNC_IN_IRAM - select HAL_SPI_SLAVE_FUNC_IN_IRAM select GDMA_CTRL_FUNC_IN_IRAM if SOC_GDMA_SUPPORTED help Place the SPI slave ISR in to IRAM to avoid possible cache miss. diff --git a/components/esp_driver_spi/linker.lf b/components/esp_driver_spi/linker.lf index 450934d495..b14233c458 100644 --- a/components/esp_driver_spi/linker.lf +++ b/components/esp_driver_spi/linker.lf @@ -8,3 +8,11 @@ entries: if SOC_SPI_SUPPORT_SLAVE_HD_VER2 = y: spi_dma: spi_dma_get_eof_desc (noflash) + +[mapping:gpspi_hal] +archive: libhal.a +entries: + if SPI_MASTER_ISR_IN_IRAM = y: + spi_hal_iram (noflash) + if SPI_SLAVE_ISR_IN_IRAM = y: + spi_slave_hal_iram (noflash) diff --git a/components/hal/Kconfig b/components/hal/Kconfig index 2c8e44d657..74fb4bc022 100644 --- a/components/hal/Kconfig +++ b/components/hal/Kconfig @@ -91,18 +91,6 @@ menu "Hardware Abstraction Layer (HAL) and Low Level (LL)" features will be added and bugs will be fixed in the IDF source but cannot be synced to ROM. - config HAL_SPI_MASTER_FUNC_IN_IRAM - bool - depends on SPI_MASTER_ISR_IN_IRAM - help - Enable this option to place SPI master hal layer functions into IRAM. - - config HAL_SPI_SLAVE_FUNC_IN_IRAM - bool - depends on SPI_SLAVE_ISR_IN_IRAM - help - Enable this option to place SPI slave hal layer functions into IRAM. - config HAL_ECDSA_GEN_SIG_CM bool "Enable countermeasure for ECDSA signature generation" depends on IDF_TARGET_ESP32H2 diff --git a/components/hal/linker.lf b/components/hal/linker.lf index 952f3ff1a7..24a32cefd6 100644 --- a/components/hal/linker.lf +++ b/components/hal/linker.lf @@ -9,11 +9,6 @@ entries: cache_hal_esp32 (noflash) else: cache_hal (noflash) - if SOC_GPSPI_SUPPORTED = y: - if HAL_SPI_MASTER_FUNC_IN_IRAM = y: - spi_hal_iram (noflash) - if HAL_SPI_SLAVE_FUNC_IN_IRAM = y: - spi_slave_hal_iram (noflash) if SOC_I2C_SUPPORTED = y: i2c_hal_iram (noflash) if HAL_WDT_USE_ROM_IMPL = n: