TTY: switch tty_flip_buffer_push
[GitHub/mt8127/android_kernel_alcatel_ttab.git] / drivers / usb / serial / cypress_m8.c
index ac14e3eb95ea1a29b61d39286d3f041694a6fede..8efa19d0e9fba756d37f7ea1f0b0d7e813ab9610 100644 (file)
@@ -1214,10 +1214,10 @@ static void cypress_read_int_callback(struct urb *urb)
                spin_unlock_irqrestore(&priv->lock, flags);
 
        /* process read if there is data other than line status */
-       if (tty && bytes > i) {
+       if (bytes > i) {
                tty_insert_flip_string_fixed_flag(&port->port, data + i,
                                tty_flag, bytes - i);
-               tty_flip_buffer_push(tty);
+               tty_flip_buffer_push(&port->port);
        }
 
        spin_lock_irqsave(&priv->lock, flags);