This is an automated email from the ASF dual-hosted git repository. antmerlino pushed a commit to branch stm32h747xi in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git
commit 5d62e49eae458d967e4acc74d79cbfe60c851df2 Author: Anthony Merlino <[email protected]> AuthorDate: Sun Mar 7 22:10:13 2021 -0500 stm32h7x7xx: Setup UART1 and UART6 clocks as part of APB2 bringup if enabled. --- arch/arm/src/stm32h7/stm32h7x7xx_rcc.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/arch/arm/src/stm32h7/stm32h7x7xx_rcc.c b/arch/arm/src/stm32h7/stm32h7x7xx_rcc.c index f1c6821..35d4f50 100644 --- a/arch/arm/src/stm32h7/stm32h7x7xx_rcc.c +++ b/arch/arm/src/stm32h7/stm32h7x7xx_rcc.c @@ -492,6 +492,18 @@ static inline void rcc_enableapb2(void) regval |= RCC_APB2ENR_SDMMC2EN; #endif +#ifdef CONFIG_STM32H7_USART1 + /* USART1 clock enable */ + + regval |= RCC_APB2ENR_USART1EN; +#endif + +#ifdef CONFIG_STM32H7_USART6 + /* USART1 clock enable */ + + regval |= RCC_APB2ENR_USART6EN; +#endif + putreg32(regval, STM32_RCC_APB2ENR); /* Enable peripherals */ }
