drivers: clock_control: stm32u5: keep reset values of MSI trimming

When MSI trimming values where set to 0,
and MSIS is used as system core clock and MSI > 4 MHz,
it causes uart to fail.
There is no need to set thoses trimming values.
So keep the default reset value. (keep ST Factory calibration)

Signed-off-by: Alexandre Bourdiol <alexandre.bourdiol@st.com>
This commit is contained in:
Alexandre Bourdiol 2021-11-19 15:05:29 +01:00 committed by Christopher Friedt
parent 2d223bdc8f
commit ffb6a31819

View file

@ -242,20 +242,6 @@ static void set_up_clk_msis(void)
LL_RCC_MSIS_SetRange(STM32_MSIS_RANGE << RCC_ICSCR1_MSISRANGE_Pos);
if (STM32_MSIS_RANGE < 4) {
/* MSI clock trimming for ranges 0 to 3 */
LL_RCC_MSI_SetCalibTrimming(0, LL_RCC_MSI_OSCILLATOR_0);
} else if (STM32_MSIS_RANGE < 8) {
/* MSI clock trimming for ranges 4 to 7 */
LL_RCC_MSI_SetCalibTrimming(0, LL_RCC_MSI_OSCILLATOR_1);
} else if (STM32_MSIS_RANGE < 12) {
/* MSI clock trimming for ranges 8 to 11 */
LL_RCC_MSI_SetCalibTrimming(0, LL_RCC_MSI_OSCILLATOR_2);
} else {
/* MSI clock trimming for ranges 12 to 15 */
LL_RCC_MSI_SetCalibTrimming(0, LL_RCC_MSI_OSCILLATOR_3);
}
#if STM32_MSIS_PLL_MODE
#if !STM32_LSE_CLOCK