]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
ENGR00169433 IMX/UART : fix a bug in UART RX
authorHuang Shijie <b32955@freescale.com>
Mon, 5 Dec 2011 10:53:47 +0000 (18:53 +0800)
committerOliver Wendt <ow@karo-electronics.de>
Mon, 30 Sep 2013 12:10:13 +0000 (14:10 +0200)
The origin code did not check the running situation.
It will cause a NULL pointer issue.

This patch fixes it.

Signed-off-by: Huang Shijie <b32955@freescale.com>
drivers/tty/serial/imx.c

index b9e169417c7b7a173981fff7a0ca358b35188b06..f31fa1e16ca7c3400dfedfc715c46b8ffbc51785 100644 (file)
@@ -741,7 +741,9 @@ static void dma_rx_work(struct work_struct *w)
                tty_flip_buffer_push(tty);
                sport->rx_bytes = 0;
        }
-       start_rx_dma(sport);
+
+       if (sport->dma_is_rxing)
+               start_rx_dma(sport);
 }
 
 /*