From 791ead7abac8ce120b5808d6e8b15dc5122a6fd6 Mon Sep 17 00:00:00 2001 From: Vic Yang Date: Thu, 23 Oct 2014 16:00:44 -0700 Subject: stm32: Fix UART Rx DMA for USART2 and above This modifies the stray hard-coded DMA channel for UART Rx to the correct config flag. BRANCH=None BUG=chrome-os-partner:32660 TEST=On Ryu, enable UART Rx DMA and check console is still responsive Change-Id: Icec2de6ad4d34c6e0f8df2a1d51d9fefd982c9f4 Signed-off-by: Vic Yang Reviewed-on: https://chromium-review.googlesource.com/225239 Reviewed-by: Vincent Palatin --- chip/stm32/uart.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/chip/stm32/uart.c b/chip/stm32/uart.c index f98b9138ff..de4047a1bc 100644 --- a/chip/stm32/uart.c +++ b/chip/stm32/uart.c @@ -130,7 +130,7 @@ void uart_rx_dma_start(char *dest, int len) int uart_rx_dma_head(void) { - return dma_bytes_done(dma_get_channel(STM32_DMAC_USART1_RX), + return dma_bytes_done(dma_get_channel(CONFIG_UART_RX_DMA_CH), dma_rx_len); } -- cgit v1.2.1