From b5a4cce385130103c33a5c6be5906f006b501533 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 7a43545a0f..c9e0280efd 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