Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 26674
b: refs/heads/master
c: df3fccb
h: refs/heads/master
v: v3
  • Loading branch information
Greg Kroah-Hartman committed May 12, 2006
1 parent 04cfe3b commit 6fe248b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 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: 815ddc99dd8108908d14c699a37d0f5974da6def
refs/heads/master: df3fccb14ad02c5fabe095a104a0323c223f2833
12 changes: 6 additions & 6 deletions trunk/drivers/usb/serial/omninet.c
Original file line number Diff line number Diff line change
Expand Up @@ -257,14 +257,14 @@ static int omninet_write (struct usb_serial_port *port, const unsigned char *buf
return (0);
}

spin_lock(&port->lock);
if (port->write_urb_busy) {
spin_unlock(&port->lock);
spin_lock(&wport->lock);
if (wport->write_urb_busy) {
spin_unlock(&wport->lock);
dbg("%s - already writing", __FUNCTION__);
return 0;
}
port->write_urb_busy = 1;
spin_unlock(&port->lock);
wport->write_urb_busy = 1;
spin_unlock(&wport->lock);

count = (count > OMNINET_BULKOUTSIZE) ? OMNINET_BULKOUTSIZE : count;

Expand All @@ -283,7 +283,7 @@ static int omninet_write (struct usb_serial_port *port, const unsigned char *buf
wport->write_urb->dev = serial->dev;
result = usb_submit_urb(wport->write_urb, GFP_ATOMIC);
if (result) {
port->write_urb_busy = 0;
wport->write_urb_busy = 0;
err("%s - failed submitting write urb, error %d", __FUNCTION__, result);
} else
result = count;
Expand Down

0 comments on commit 6fe248b

Please sign in to comment.