projects
/
GitHub
/
LineageOS
/
android_kernel_samsung_universal7580.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c0f631d
)
USB: serial: add special case for processing of empty read urbs
author
Johan Hovold
<jhovold@gmail.com>
Sat, 15 May 2010 15:53:44 +0000
(17:53 +0200)
committer
Greg Kroah-Hartman
<gregkh@suse.de>
Thu, 20 May 2010 20:21:48 +0000
(13:21 -0700)
Return immediately from generic process_read_urb if urb is empty.
Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/usb/serial/generic.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/usb/serial/generic.c
b/drivers/usb/serial/generic.c
index fcd30b8415598476d0e5fd4cb90228d686fef3a8..a817ced82835addd1be02ed338071e09427b9cca 100644
(file)
--- a/
drivers/usb/serial/generic.c
+++ b/
drivers/usb/serial/generic.c
@@
-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;