Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 188775
b: refs/heads/master
c: 62e6685
h: refs/heads/master
i:
  188773: 7a69d5d
  188771: 505607d
  188767: 6a1d903
v: v3
  • Loading branch information
Oliver Neukum authored and Greg Kroah-Hartman committed Mar 19, 2010
1 parent b466207 commit 874434d
Show file tree
Hide file tree
Showing 2 changed files with 5 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: beb1d35f1690fe27694472a010a8e4a9ae11cc50
refs/heads/master: 62e6685470fb04fb7688ecef96c39160498721d5
5 changes: 4 additions & 1 deletion trunk/drivers/usb/class/cdc-wdm.c
Original file line number Diff line number Diff line change
Expand Up @@ -794,14 +794,17 @@ static int wdm_suspend(struct usb_interface *intf, pm_message_t message)
dev_dbg(&desc->intf->dev, "wdm%d_suspend\n", intf->minor);

mutex_lock(&desc->lock);
spin_lock_irq(&desc->iuspin);
#ifdef CONFIG_PM
if ((message.event & PM_EVENT_AUTO) &&
(test_bit(WDM_IN_USE, &desc->flags)
|| test_bit(WDM_RESPONDING, &desc->flags))) {
spin_unlock_irq(&desc->iuspin);
rv = -EBUSY;
} else {
#endif
set_bit(WDM_SUSPENDING, &desc->flags);
spin_unlock_irq(&desc->iuspin);
cancel_work_sync(&desc->rxwork);
kill_urbs(desc);
#ifdef CONFIG_PM
Expand Down Expand Up @@ -831,8 +834,8 @@ static int wdm_resume(struct usb_interface *intf)

dev_dbg(&desc->intf->dev, "wdm%d_resume\n", intf->minor);
mutex_lock(&desc->lock);
rv = recover_from_urb_loss(desc);
clear_bit(WDM_SUSPENDING, &desc->flags);
rv = recover_from_urb_loss(desc);
mutex_unlock(&desc->lock);
return rv;
}
Expand Down

0 comments on commit 874434d

Please sign in to comment.