summaryrefslogtreecommitdiff
path: root/drivers/tty/serial/vt8500_serial.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/tty/serial/vt8500_serial.c')
-rw-r--r--drivers/tty/serial/vt8500_serial.c12
1 files changed, 1 insertions, 11 deletions
diff --git a/drivers/tty/serial/vt8500_serial.c b/drivers/tty/serial/vt8500_serial.c
index 7f4112423f3d..f1a398c672fa 100644
--- a/drivers/tty/serial/vt8500_serial.c
+++ b/drivers/tty/serial/vt8500_serial.c
@@ -137,15 +137,6 @@ static void vt8500_enable_ms(struct uart_port *port)
static void handle_rx(struct uart_port *port)
{
struct tty_port *tport = &port->state->port;
- struct tty_struct *tty = tty_port_tty_get(tport);
- if (!tty) {
- /* Discard data: no tty available */
- int count = (vt8500_read(port, VT8500_URFIDX) & 0x1f00) >> 8;
- u16 ch;
- while (count--)
- ch = readw(port->membase + VT8500_RXFIFO);
- return;
- }
/*
* Handle overrun
@@ -178,8 +169,7 @@ static void handle_rx(struct uart_port *port)
tty_insert_flip_char(tport, c, flag);
}
- tty_flip_buffer_push(tty);
- tty_kref_put(tty);
+ tty_flip_buffer_push(tport);
}
static void handle_tx(struct uart_port *port)