From 4145c83c827eb0fa561f31ef28bbc39c854c2bb8 Mon Sep 17 00:00:00 2001 From: Francois Ramu Date: Fri, 26 Nov 2021 14:44:21 +0100 Subject: [PATCH] drivers: watchdog: stm32MP1 window watchdog during debug This commit is controlling the WWDG during the Stop mode in debug. WWDG1 is frozen while the core is in Debug mode, setting the bit of the DBGMCU APB1 peripheral freeze register (DBGMCU_APB1FZ2) for the stm32MP1 soc devices. Signed-off-by: Francois Ramu --- drivers/watchdog/wdt_wwdg_stm32.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/watchdog/wdt_wwdg_stm32.c b/drivers/watchdog/wdt_wwdg_stm32.c index 61d55a3933a..36ad6c13cd1 100644 --- a/drivers/watchdog/wdt_wwdg_stm32.c +++ b/drivers/watchdog/wdt_wwdg_stm32.c @@ -171,6 +171,8 @@ static int wwdg_stm32_setup(const struct device *dev, uint8_t options) #endif #if defined(CONFIG_SOC_SERIES_STM32H7X) LL_DBGMCU_APB3_GRP1_FreezePeriph(LL_DBGMCU_APB3_GRP1_WWDG1_STOP); +#elif defined(CONFIG_SOC_SERIES_STM32MP1X) + LL_DBGMCU_APB1_GRP1_FreezePeriph(LL_DBGMCU_APB1_GRP1_WWDG1_STOP); #else LL_DBGMCU_APB1_GRP1_FreezePeriph(LL_DBGMCU_APB1_GRP1_WWDG_STOP); #endif /* CONFIG_SOC_SERIES_STM32H7X */