summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHuang Shijie <b32955@freescale.com>2011-12-05 18:53:47 +0800
committerHuang Shijie <b32955@freescale.com>2011-12-05 19:01:30 +0800
commitb92265a274f0fec27567e86b995424ef8823499f (patch)
treecd17fd923853ba824f1d0f7bda8edf0fadcf8c7c
parentd04b6aa162334fffb09bd25f8a19a1832af42ee6 (diff)
ENGR00169433 IMX/UART : fix a bug in UART RX
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>
-rw-r--r--drivers/tty/serial/imx.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/tty/serial/imx.c b/drivers/tty/serial/imx.c
index 0a90122fe6db..094ce699f9eb 100644
--- a/drivers/tty/serial/imx.c
+++ b/drivers/tty/serial/imx.c
@@ -743,7 +743,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);
}
/*