aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/tty/serial/pch_uart.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/drivers/tty/serial/pch_uart.c b/drivers/tty/serial/pch_uart.c
index 0c95051fa0a4..da0ba0fa2b99 100644
--- a/drivers/tty/serial/pch_uart.c
+++ b/drivers/tty/serial/pch_uart.c
@@ -636,8 +636,7 @@ static void pch_dma_tx_complete(void *arg)
636 priv->tx_dma_use = 0; 636 priv->tx_dma_use = 0;
637 priv->nent = 0; 637 priv->nent = 0;
638 kfree(priv->sg_tx_p); 638 kfree(priv->sg_tx_p);
639 if (uart_circ_chars_pending(xmit)) 639 pch_uart_hal_enable_interrupt(priv, PCH_UART_HAL_TX_INT);
640 pch_uart_hal_enable_interrupt(priv, PCH_UART_HAL_TX_INT);
641} 640}
642 641
643static int pop_tx(struct eg20t_port *priv, int size) 642static int pop_tx(struct eg20t_port *priv, int size)
@@ -793,6 +792,14 @@ static unsigned int dma_handle_tx(struct eg20t_port *priv)
793 return 0; 792 return 0;
794 } 793 }
795 794
795 if (priv->tx_dma_use) {
796 dev_dbg(priv->port.dev, "%s:Tx is not completed. (%lu)\n",
797 __func__, jiffies);
798 pch_uart_hal_disable_interrupt(priv, PCH_UART_HAL_TX_INT);
799 priv->tx_empty = 1;
800 return 0;
801 }
802
796 fifo_size = max(priv->fifo_size, 1); 803 fifo_size = max(priv->fifo_size, 1);
797 tx_empty = 1; 804 tx_empty = 1;
798 if (pop_tx_x(priv, xmit->buf)) { 805 if (pop_tx_x(priv, xmit->buf)) {