From c9cbc6d03ccc14ff728b02f14988a36439cbbede Mon Sep 17 00:00:00 2001 From: Stefan Kerkmann Date: Thu, 25 Mar 2021 22:11:49 +0100 Subject: [PATCH] No DMA for UART4 --- os/hal/ports/GD/GD32VF103/USART/hal_uart_lld.h | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/os/hal/ports/GD/GD32VF103/USART/hal_uart_lld.h b/os/hal/ports/GD/GD32VF103/USART/hal_uart_lld.h index 7a43545a..c9e0280e 100644 --- a/os/hal/ports/GD/GD32VF103/USART/hal_uart_lld.h +++ b/os/hal/ports/GD/GD32VF103/USART/hal_uart_lld.h @@ -203,6 +203,16 @@ #error "UART4 not present in the selected device" #endif +#if GD32_UART_USE_UART4 +#if !GD32_HAS_UART4 +#error "UART4 not present in the selected device" +#endif + +#if defined(GD32VF103) +#error "UART4 DMA access not supported in this platform" +#endif +#endif /* GD32_UART_USE_UART4 */ + #if !GD32_UART_USE_USART0 && !GD32_UART_USE_USART1 && \ !GD32_UART_USE_USART2 && !GD32_UART_USE_UART3 && \ !GD32_UART_USE_UART4