soc: arm: st_stm32: add driver lptimer management to stm32wb series

This patch introduces the support of the Low Power Timer
     for the STM32WBxx from STMicroelectronics.

Signed-off-by: Francois Ramu <francois.ramu@st.com>
This commit is contained in:
Francois Ramu 2019-10-23 14:03:55 +02:00 committed by Kumar Gala
commit 91884302bf
3 changed files with 24 additions and 0 deletions

View file

@ -277,6 +277,18 @@
reg = <0x40003000 0x400>;
label = "IWDG";
};
lptim1: timers@40007c00 {
compatible = "st,stm32-timers";
clocks = <&rcc STM32_CLOCK_BUS_APB1 0x80000000>;
#address-cells = <1>;
#size-cells = <0>;
reg = <0x40007c00 0x400>;
interrupts = <47 0>;
interrupt-names = "wakeup";
status = "disabled";
label = "LPTIM_1";
};
};
};

View file

@ -164,4 +164,11 @@
#define DT_WWDT_0_CLOCK_BITS DT_INST_0_ST_STM32_WINDOW_WATCHDOG_CLOCK_BITS
#define DT_WWDT_0_CLOCK_BUS DT_INST_0_ST_STM32_WINDOW_WATCHDOG_CLOCK_BUS
#define DT_LPTIM_1_BASE_ADDRESS DT_ST_STM32_TIMERS_40007C00_BASE_ADDRESS
#define DT_LPTIM_1_IRQ DT_ST_STM32_TIMERS_40007C00_IRQ_0
#define DT_LPTIM_1_IRQ_PRI DT_ST_STM32_TIMERS_40007C00_IRQ_0_PRIORITY
#define DT_LPTIM_1_NAME DT_ST_STM32_TIMERS_40007C00_LABEL
#define DT_LPTIM_1_CLOCK_BITS DT_ST_STM32_TIMERS_40007C00_CLOCK_BITS_0
#define DT_LPTIM_1_CLOCK_BUS DT_ST_STM32_TIMERS_40007C00_CLOCK_BUS_0
/* End of SoC Level DTS fixup file */

View file

@ -73,6 +73,11 @@
#include <stm32wbxx_ll_wwdg.h>
#endif
#ifdef CONFIG_STM32_LPTIM_TIMER
#include <stm32wbxx_ll_lptim.h>
#include <stm32wbxx_ll_system.h>
#endif
#endif /* !_ASMLANGUAGE */
#endif /* _STM32WBX_SOC_H_ */