diff options
Diffstat (limited to 'drivers/usb/serial/kobil_sct.c')
-rw-r--r-- | drivers/usb/serial/kobil_sct.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/drivers/usb/serial/kobil_sct.c b/drivers/usb/serial/kobil_sct.c index b747ba615d0b..903d938e174b 100644 --- a/drivers/usb/serial/kobil_sct.c +++ b/drivers/usb/serial/kobil_sct.c @@ -324,7 +324,6 @@ static void kobil_read_int_callback(struct urb *urb) { int result; struct usb_serial_port *port = urb->context; - struct tty_struct *tty; unsigned char *data = urb->transfer_buffer; int status = urb->status; @@ -333,8 +332,7 @@ static void kobil_read_int_callback(struct urb *urb) return; } - tty = tty_port_tty_get(&port->port); - if (tty && urb->actual_length) { + if (urb->actual_length) { /* BEGIN DEBUG */ /* @@ -353,10 +351,9 @@ static void kobil_read_int_callback(struct urb *urb) */ /* END DEBUG */ - tty_insert_flip_string(tty, data, urb->actual_length); - tty_flip_buffer_push(tty); + tty_insert_flip_string(&port->port, data, urb->actual_length); + tty_flip_buffer_push(&port->port); } - tty_kref_put(tty); result = usb_submit_urb(port->interrupt_in_urb, GFP_ATOMIC); dev_dbg(&port->dev, "%s - Send read URB returns: %i\n", __func__, result); |