Commit 56a1df46 authored by Johan Hovold's avatar Johan Hovold Committed by Greg Kroah-Hartman

USB: serial: add special case for processing of empty read urbs

Return immediately from generic process_read_urb if urb is empty.
Signed-off-by: default avatarJohan Hovold <jhovold@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent c0f631d1
......@@ -324,6 +324,9 @@ void usb_serial_generic_process_read_urb(struct urb *urb)
char *ch = (char *)urb->transfer_buffer;
int i;
if (!urb->actual_length)
return;
tty = tty_port_tty_get(&port->port);
if (!tty)
return;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment