mirror of
https://github.com/espressif/esp-idf
synced 2025-03-11 10:09:08 -04:00
Merge branch 'bugfix/unstall_other_cpu_on_core_reset' into 'master'
bugfix: unstall other cpu on core reset Closes IDFGH-8902 See merge request espressif/esp-idf!21495
This commit is contained in:
commit
46917a87ba
@ -24,10 +24,19 @@ void IRAM_ATTR esp_restart_noos_dig(void)
|
|||||||
// switch to XTAL (otherwise we will keep running from the PLL)
|
// switch to XTAL (otherwise we will keep running from the PLL)
|
||||||
rtc_clk_cpu_freq_set_xtal();
|
rtc_clk_cpu_freq_set_xtal();
|
||||||
|
|
||||||
#if CONFIG_IDF_TARGET_ESP32
|
// esp_restart_noos_dig() will generates a core reset, which does not reset the
|
||||||
esp_cpu_unstall(PRO_CPU_NUM);
|
// registers of the RTC domain, so the CPU's stall state remains after the reset,
|
||||||
|
// we need to release them here
|
||||||
|
#if !CONFIG_FREERTOS_UNICORE
|
||||||
|
// unstall all other cores
|
||||||
|
int core_id = esp_cpu_get_core_id();
|
||||||
|
for (uint32_t i = 0; i < SOC_CPU_CORES_NUM; i++) {
|
||||||
|
if (i != core_id) {
|
||||||
|
esp_cpu_unstall(i);
|
||||||
|
}
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
// reset the digital part
|
// generate core reset
|
||||||
esp_rom_software_reset_system();
|
esp_rom_software_reset_system();
|
||||||
while (true) {
|
while (true) {
|
||||||
;
|
;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user