Skip to content

Commit 26818ee

Browse files
Raffael Rostagnodanieldegrasse
authored andcommitted
drivers: clock_control: esp32c6: Fix clock init at JTAG reset
Peripheral clocks are currently not being disabled for JTAG reset condition, which causes driver init failures when debugging the SoC with JTAG. Fix by disabling all clocks for this reset type. Signed-off-by: Raffael Rostagno <[email protected]>
1 parent 9207749 commit 26818ee

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

drivers/clock_control/clock_control_esp32.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,8 +105,7 @@ static void esp32_clock_perip_init(void)
105105
soc_reset_reason_t rst_reason = esp_rom_get_reset_reason(0);
106106

107107
if ((rst_reason != RESET_REASON_CPU0_MWDT0) && (rst_reason != RESET_REASON_CPU0_MWDT1) &&
108-
(rst_reason != RESET_REASON_CPU0_SW) && (rst_reason != RESET_REASON_CPU0_RTC_WDT) &&
109-
(rst_reason != RESET_REASON_CPU0_JTAG)) {
108+
(rst_reason != RESET_REASON_CPU0_SW) && (rst_reason != RESET_REASON_CPU0_RTC_WDT)) {
110109

111110
periph_ll_disable_clk_set_rst(PERIPH_UART1_MODULE);
112111
periph_ll_disable_clk_set_rst(PERIPH_I2C0_MODULE);

0 commit comments

Comments
 (0)