]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - drivers/tty/serial/clps711x.c
TTY: switch tty_flip_buffer_push
[karo-tx-linux.git] / drivers / tty / serial / clps711x.c
index 3fd2526d121eef6eb70c14dc7dbc4a003841e245..bfb17968c8dbbe86ad91902c94f02a824c0a81c3 100644 (file)
@@ -85,12 +85,8 @@ static void uart_clps711x_enable_ms(struct uart_port *port)
 static irqreturn_t uart_clps711x_int_rx(int irq, void *dev_id)
 {
        struct uart_port *port = dev_id;
-       struct tty_struct *tty = tty_port_tty_get(&port->state->port);
        unsigned int status, ch, flg;
 
-       if (!tty)
-               return IRQ_HANDLED;
-
        for (;;) {
                status = clps_readl(SYSFLG(port));
                if (status & SYSFLG_URXFE)
@@ -130,9 +126,7 @@ static irqreturn_t uart_clps711x_int_rx(int irq, void *dev_id)
                uart_insert_char(port, status, UARTDR_OVERR, ch, flg);
        }
 
-       tty_flip_buffer_push(tty);
-
-       tty_kref_put(tty);
+       tty_flip_buffer_push(&port->state->port);
 
        return IRQ_HANDLED;
 }