aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/class/cdc-wdm.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/class/cdc-wdm.c')
-rw-r--r--drivers/usb/class/cdc-wdm.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/usb/class/cdc-wdm.c b/drivers/usb/class/cdc-wdm.c
index 2b9ff518b509..42f180aca3fb 100644
--- a/drivers/usb/class/cdc-wdm.c
+++ b/drivers/usb/class/cdc-wdm.c
@@ -798,11 +798,11 @@ static int wdm_suspend(struct usb_interface *intf, pm_message_t message)
798 dev_dbg(&desc->intf->dev, "wdm%d_suspend\n", intf->minor); 798 dev_dbg(&desc->intf->dev, "wdm%d_suspend\n", intf->minor);
799 799
800 /* if this is an autosuspend the caller does the locking */ 800 /* if this is an autosuspend the caller does the locking */
801 if (!(message.event & PM_EVENT_AUTO)) 801 if (!PMSG_IS_AUTO(message))
802 mutex_lock(&desc->lock); 802 mutex_lock(&desc->lock);
803 spin_lock_irq(&desc->iuspin); 803 spin_lock_irq(&desc->iuspin);
804 804
805 if ((message.event & PM_EVENT_AUTO) && 805 if (PMSG_IS_AUTO(message) &&
806 (test_bit(WDM_IN_USE, &desc->flags) 806 (test_bit(WDM_IN_USE, &desc->flags)
807 || test_bit(WDM_RESPONDING, &desc->flags))) { 807 || test_bit(WDM_RESPONDING, &desc->flags))) {
808 spin_unlock_irq(&desc->iuspin); 808 spin_unlock_irq(&desc->iuspin);
@@ -815,7 +815,7 @@ static int wdm_suspend(struct usb_interface *intf, pm_message_t message)
815 kill_urbs(desc); 815 kill_urbs(desc);
816 cancel_work_sync(&desc->rxwork); 816 cancel_work_sync(&desc->rxwork);
817 } 817 }
818 if (!(message.event & PM_EVENT_AUTO)) 818 if (!PMSG_IS_AUTO(message))
819 mutex_unlock(&desc->lock); 819 mutex_unlock(&desc->lock);
820 820
821 return rv; 821 return rv;