fix(esp_hw_support): fix branch predictor access flash after cache disabled

This commit is contained in:
wuzhenghui
2025-01-22 19:24:48 +08:00
parent 473771bc14
commit cfcd8990f6
4 changed files with 40 additions and 17 deletions
+1 -2
View File
@@ -71,6 +71,7 @@
#include "soc/hp_sys_clkrst_reg.h"
#endif
#include "esp_private/cache_utils.h"
#include "esp_private/rtc_clk.h"
#if SOC_INT_CLIC_SUPPORTED
@@ -680,7 +681,6 @@ void IRAM_ATTR call_start_cpu0(void)
#if CONFIG_ESP32S2_DATA_CACHE_WRAP || CONFIG_ESP32S3_DATA_CACHE_WRAP
dcache_wrap_enable = 1;
#endif
extern void esp_enable_cache_wrap(uint32_t icache_wrap_enable, uint32_t dcache_wrap_enable);
esp_enable_cache_wrap(icache_wrap_enable, dcache_wrap_enable);
#endif
@@ -692,7 +692,6 @@ void IRAM_ATTR call_start_cpu0(void)
#if CONFIG_IDF_TARGET_ESP32C2
// TODO : IDF-5020
#if CONFIG_ESP32C2_INSTRUCTION_CACHE_WRAP
extern void esp_enable_cache_wrap(uint32_t icache_wrap_enable);
esp_enable_cache_wrap(1);
#endif
#endif