mirror of
https://github.com/espressif/esp-idf.git
synced 2025-08-08 04:02:27 +00:00
bugfix: fix esp32s3 psram access failed when dfs is enabled
This commit is contained in:
@@ -31,6 +31,10 @@
|
||||
#include "xtensa/core-macros.h"
|
||||
#endif
|
||||
|
||||
#if SOC_SPI_MEM_SUPPORT_TIMING_TUNING
|
||||
#include "esp_private/mspi_timing_tuning.h"
|
||||
#endif
|
||||
|
||||
#include "esp_private/pm_impl.h"
|
||||
#include "esp_private/pm_trace.h"
|
||||
#include "esp_private/esp_timer_private.h"
|
||||
@@ -475,7 +479,17 @@ static void IRAM_ATTR do_switch(pm_mode_t new_mode)
|
||||
if (switch_down) {
|
||||
on_freq_update(old_ticks_per_us, new_ticks_per_us);
|
||||
}
|
||||
rtc_clk_cpu_freq_set_config_fast(&new_config);
|
||||
if (new_config.source == SOC_CPU_CLK_SRC_PLL) {
|
||||
rtc_clk_cpu_freq_set_config_fast(&new_config);
|
||||
#if SOC_SPI_MEM_SUPPORT_TIMING_TUNING
|
||||
mspi_timing_change_speed_mode_cache_safe(false);
|
||||
#endif
|
||||
} else {
|
||||
#if SOC_SPI_MEM_SUPPORT_TIMING_TUNING
|
||||
mspi_timing_change_speed_mode_cache_safe(true);
|
||||
#endif
|
||||
rtc_clk_cpu_freq_set_config_fast(&new_config);
|
||||
}
|
||||
if (!switch_down) {
|
||||
on_freq_update(old_ticks_per_us, new_ticks_per_us);
|
||||
}
|
||||
|
Reference in New Issue
Block a user