Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 195343
b: refs/heads/master
c: ec3ee50
h: refs/heads/master
i:
  195341: 558dcf7
  195339: 9115856
  195335: 1322dba
  195327: 184b646
v: v3
  • Loading branch information
Johan Hovold authored and Greg Kroah-Hartman committed May 20, 2010
1 parent d0ad841 commit 04ef8b6
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 50dbb8528757b1977efd5d270ed9d262cbbef87d
refs/heads/master: ec3ee5086c1e1b883292eaf795b5c1b0c25bcffe
8 changes: 7 additions & 1 deletion trunk/drivers/usb/serial/generic.c
Original file line number Diff line number Diff line change
Expand Up @@ -156,13 +156,19 @@ EXPORT_SYMBOL_GPL(usb_serial_generic_open);
static void generic_cleanup(struct usb_serial_port *port)
{
struct usb_serial *serial = port->serial;
unsigned long flags;

dbg("%s - port %d", __func__, port->number);

if (serial->dev) {
/* shutdown any bulk transfers that might be going on */
if (port->bulk_out_size)
if (port->bulk_out_size) {
usb_kill_urb(port->write_urb);

spin_lock_irqsave(&port->lock, flags);
kfifo_reset_out(&port->write_fifo);
spin_unlock_irqrestore(&port->lock, flags);
}
if (port->bulk_in_size)
usb_kill_urb(port->read_urb);
}
Expand Down

0 comments on commit 04ef8b6

Please sign in to comment.