arch/arm/src/stm32l4/stm32l4x6xx_rcc.c: This fix is needed if HSI clock is selected. Otherwise when waking up from STOP mode, the MSI clock is selected instead of the HSI clock.

This commit is contained in:
Matias N 2019-11-07 14:14:09 -06:00 committed by Gregory Nutt
parent d31411189e
commit 853e3e0086

View File

@ -968,6 +968,14 @@ static void stm32l4_stdclockconfig(void)
stm32l4_rcc_enablelsi();
#endif
#if defined(STM32L4_BOARD_USEHSI)
/* Enable wake-up to HSI from Stop modes */
regval = getreg32(STM32L4_RCC_CFGR);
regval |= RCC_CFGR_STOPWUCK_HSI;
putreg32(regval, STM32L4_RCC_CFGR);
#endif
#if defined(STM32L4_USE_LSE)
/* Low speed external clock source LSE
*