diff options
author | Alan Stern <stern@rowland.harvard.edu> | 2007-05-04 11:54:28 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2007-07-12 16:29:46 -0700 |
commit | f3fd77cd2f4499f3e2ef9a1e6d5e4f4349d556c3 (patch) | |
tree | 71cb2e01dfe006c5904ac01d002226b8b6cb04f2 /drivers/usb/core | |
parent | 8adb4786789c25007f39b4d00dd03cc83bdcb896 (diff) | |
download | linux-f3fd77cd2f4499f3e2ef9a1e6d5e4f4349d556c3.tar.gz linux-f3fd77cd2f4499f3e2ef9a1e6d5e4f4349d556c3.tar.bz2 linux-f3fd77cd2f4499f3e2ef9a1e6d5e4f4349d556c3.zip |
USB: remove references to dev.power.power_state
This revised patch (as891b) removes two unnecessary references to
intf->dev.power.power_state from usb-storage, and replaces a reference
to root_hub->dev.power.power_state with a check of hcd->state. This
is in preparation for the removal of dev.power.power_state, which is
already deprecated.
Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/core')
-rw-r--r-- | drivers/usb/core/hcd-pci.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/usb/core/hcd-pci.c b/drivers/usb/core/hcd-pci.c index edf4300a3f7a..5cf6d5f9acbd 100644 --- a/drivers/usb/core/hcd-pci.c +++ b/drivers/usb/core/hcd-pci.c @@ -207,7 +207,8 @@ int usb_hcd_pci_suspend (struct pci_dev *dev, pm_message_t message) * We must ignore the FREEZE vs SUSPEND distinction here, because * otherwise the swsusp will save (and restore) garbage state. */ - if (hcd->self.root_hub->dev.power.power_state.event == PM_EVENT_ON) + if (!(hcd->state == HC_STATE_SUSPENDED || + hcd->state == HC_STATE_HALT)) return -EBUSY; if (hcd->driver->suspend) { |