diff options
author | Peter Hurley <peter@hurleysoftware.com> | 2014-09-03 01:39:17 +0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-09-09 03:22:42 +0400 |
commit | 98f8b83d6a504615f52a095acf92a2bdad985ae0 (patch) | |
tree | 8ae27402b9c4bac86e48597ec823ff119f75c165 /drivers/tty/serial/sunsab.c | |
parent | 16f404e3666718917b2541503240cf8430aa49ff (diff) | |
download | linux-98f8b83d6a504615f52a095acf92a2bdad985ae0.tar.xz |
serial: sunsab: Don't enable tx if tx stopped
The serial core may call the UART driver's start_tx() even if
tx is stopped; the UART driver must verify tx should be enabled
before transmitting.
Reported-by: Sam Ravnborg <sam@ravnborg.org>
cc: David S. Miller <davem@davemloft.net>
cc: <sparclinux@vger.kernel.org>
Signed-off-by: Peter Hurley <peter@hurleysoftware.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty/serial/sunsab.c')
-rw-r--r-- | drivers/tty/serial/sunsab.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/tty/serial/sunsab.c b/drivers/tty/serial/sunsab.c index 0af75f8b98a4..b339fe4811cd 100644 --- a/drivers/tty/serial/sunsab.c +++ b/drivers/tty/serial/sunsab.c @@ -436,7 +436,7 @@ static void sunsab_start_tx(struct uart_port *port) struct circ_buf *xmit = &up->port.state->xmit; int i; - if (uart_circ_empty(xmit)) + if (uart_circ_empty(xmit) || uart_tx_stopped(port)) return; up->interrupt_mask1 &= ~(SAB82532_IMR1_ALLS|SAB82532_IMR1_XPR); |