drivers: counter: stm32: add support for STM32WB0

This commit adds support for the STM32WB0 series to
the existing STM32 timer-based counters driver.

Signed-off-by: Mathieu Choplain <mathieu.choplain@st.com>
This commit is contained in:
Mathieu Choplain 2025-01-08 14:00:35 +01:00 committed by Benjamin Cabé
parent 7e1074631e
commit fc61e64a3a

View file

@ -383,7 +383,10 @@ static int counter_stm32_get_tim_clk(const struct stm32_pclken *pclken, uint32_t
return r;
}
#if defined(CONFIG_SOC_SERIES_STM32H7X)
#if defined(CONFIG_SOC_SERIES_STM32WB0X)
/* Timers are clocked by SYSCLK on STM32WB0 */
apb_psc = 1;
#elif defined(CONFIG_SOC_SERIES_STM32H7X)
if (pclken->bus == STM32_CLOCK_BUS_APB1) {
apb_psc = STM32_D2PPRE1;
} else {