mirror of
https://github.com/espressif/esp-idf
synced 2025-03-13 02:59:13 -04:00
Merge branch 'bugfix/rtc_fast_memory_force_on_in_use_for_heap_backport_v4.2' into 'release/v4.2'
Bugfix/rtc fast memory force on in use for heap (backport v4.2) See merge request espressif/esp-idf!12873
This commit is contained in:
commit
c8d15588e5
@ -668,14 +668,17 @@ static uint32_t get_power_down_flags(void)
|
||||
s_config.pd_options[ESP_PD_DOMAIN_RTC_SLOW_MEM] = ESP_PD_OPTION_ON;
|
||||
}
|
||||
|
||||
// RTC_FAST_MEM is needed for deep sleep stub.
|
||||
// If RTC_FAST_MEM is Auto, keep it powered on, so that deep sleep stub
|
||||
// can run.
|
||||
// In the new chip revision, deep sleep stub will be optional,
|
||||
// and this can be changed.
|
||||
#if !CONFIG_ESP32_ALLOW_RTC_FAST_MEM_AS_HEAP
|
||||
/* RTC_FAST_MEM is needed for deep sleep stub.
|
||||
If RTC_FAST_MEM is Auto, keep it powered on, so that deep sleep stub can run.
|
||||
In the new chip revision, deep sleep stub will be optional, and this can be changed. */
|
||||
if (s_config.pd_options[ESP_PD_DOMAIN_RTC_FAST_MEM] == ESP_PD_OPTION_AUTO) {
|
||||
s_config.pd_options[ESP_PD_DOMAIN_RTC_FAST_MEM] = ESP_PD_OPTION_ON;
|
||||
}
|
||||
#else
|
||||
/* If RTC_FAST_MEM is used for heap, force RTC_FAST_MEM to be powered on. */
|
||||
s_config.pd_options[ESP_PD_DOMAIN_RTC_FAST_MEM] = ESP_PD_OPTION_ON;
|
||||
#endif
|
||||
|
||||
// RTC_PERIPH is needed for EXT0 wakeup and GPIO wakeup.
|
||||
// If RTC_PERIPH is auto, and EXT0/GPIO aren't enabled, power down RTC_PERIPH.
|
||||
|
@ -703,14 +703,17 @@ static uint32_t get_power_down_flags(void)
|
||||
s_config.pd_options[ESP_PD_DOMAIN_RTC_SLOW_MEM] = ESP_PD_OPTION_ON;
|
||||
}
|
||||
|
||||
// RTC_FAST_MEM is needed for deep sleep stub.
|
||||
// If RTC_FAST_MEM is Auto, keep it powered on, so that deep sleep stub
|
||||
// can run.
|
||||
// In the new chip revision, deep sleep stub will be optional,
|
||||
// and this can be changed.
|
||||
#if !CONFIG_ESP32S2_ALLOW_RTC_FAST_MEM_AS_HEAP
|
||||
/* RTC_FAST_MEM is needed for deep sleep stub.
|
||||
If RTC_FAST_MEM is Auto, keep it powered on, so that deep sleep stub can run.
|
||||
In the new chip revision, deep sleep stub will be optional, and this can be changed. */
|
||||
if (s_config.pd_options[ESP_PD_DOMAIN_RTC_FAST_MEM] == ESP_PD_OPTION_AUTO) {
|
||||
s_config.pd_options[ESP_PD_DOMAIN_RTC_FAST_MEM] = ESP_PD_OPTION_ON;
|
||||
}
|
||||
#else
|
||||
/* If RTC_FAST_MEM is used for heap, force RTC_FAST_MEM to be powered on. */
|
||||
s_config.pd_options[ESP_PD_DOMAIN_RTC_FAST_MEM] = ESP_PD_OPTION_ON;
|
||||
#endif
|
||||
|
||||
// RTC_PERIPH is needed for EXT0 wakeup and GPIO wakeup.
|
||||
// If RTC_PERIPH is auto, and EXT0/GPIO aren't enabled, power down RTC_PERIPH.
|
||||
|
Loading…
x
Reference in New Issue
Block a user