summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJiada Wang <jiada_wang@mentor.com>2014-12-09 18:11:35 +0900
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2015-01-09 14:23:59 -0800
commit7e2fb5aa8d819e8cc0b6815ad627b7e911fabfd9 (patch)
tree6e12de6e01b2dfa754835766cbbb1a1d2b983302
parent6f026d6b7cb6e019b6352ed7fb71497c787fd6d7 (diff)
downloadop-kernel-dev-7e2fb5aa8d819e8cc0b6815ad627b7e911fabfd9.zip
op-kernel-dev-7e2fb5aa8d819e8cc0b6815ad627b7e911fabfd9.tar.gz
serial: imx: Fix issue in software flow control
After send out x_char in UART driver, x_char needs to be cleared by UART driver itself, otherwise data in TXFIFO can no longer be sent out. Also tx counter needs to be increased to keep track of correct number of transmitted data. Signed-off-by: Jiada Wang <jiada_wang@mentor.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/tty/serial/imx.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/tty/serial/imx.c b/drivers/tty/serial/imx.c
index 79f485b..5a7da01 100644
--- a/drivers/tty/serial/imx.c
+++ b/drivers/tty/serial/imx.c
@@ -471,6 +471,8 @@ static inline void imx_transmit_buffer(struct imx_port *sport)
if (sport->port.x_char) {
/* Send next char */
writel(sport->port.x_char, sport->port.membase + URTX0);
+ sport->port.icount.tx++;
+ sport->port.x_char = 0;
return;
}
OpenPOWER on IntegriCloud