diff --git a/arch/arm/src/stm32/stm32_lowputc.c b/arch/arm/src/stm32/stm32_lowputc.c index ba113bb493..8ace1d6e22 100644 --- a/arch/arm/src/stm32/stm32_lowputc.c +++ b/arch/arm/src/stm32/stm32_lowputc.c @@ -572,9 +572,11 @@ void stm32_lowsetup(void) uint32_t cr; #endif +#if defined(CONFIG_HAVE_CONSOLE) /* Enable USART APB1/2 clock */ modifyreg32(STM32_CONSOLE_APBREG, 0, STM32_CONSOLE_APBEN); +#endif /* Enable the console USART and configure GPIO pins needed for rx/tx. * diff --git a/arch/arm/src/stm32/stm32_serial.c b/arch/arm/src/stm32/stm32_serial.c index d5333de90a..b378654027 100644 --- a/arch/arm/src/stm32/stm32_serial.c +++ b/arch/arm/src/stm32/stm32_serial.c @@ -390,8 +390,6 @@ static const struct uart_ops_s g_uart_ops = .rxavailable = up_rxavailable, #ifdef CONFIG_SERIAL_IFLOWCONTROL .rxflowcontrol = up_rxflowcontrol, -#else - .rxflowcontrol = NULL, #endif .send = up_send, .txint = up_txint,