提交 2ad28e3e 编写于 作者: H Huang Shijie 提交者: Greg Kroah-Hartman

serial: imx: always wake up the processes in the TX callback

The current code only wakes up the processes when the circle
buffer has less data then the WAKEUP_CHARS.

But sometimes, the circle buffer may has data more then the WAKEUP_CHARS,
in such case, the processes will hang.

This patch makes it always wakes up the processes in the TX callback.
Signed-off-by: NHuang Shijie <b32955@freescale.com>
Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
上级 c972d806
......@@ -496,8 +496,7 @@ static void dma_tx_callback(void *data)
dev_dbg(sport->port.dev, "we finish the TX DMA.\n");
if (uart_circ_chars_pending(xmit) < WAKEUP_CHARS)
uart_write_wakeup(&sport->port);
uart_write_wakeup(&sport->port);
if (waitqueue_active(&sport->dma_wait)) {
wake_up(&sport->dma_wait);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册