diff options
Diffstat (limited to 'drivers/usb/core/usb.c')
-rw-r--r-- | drivers/usb/core/usb.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/usb/core/usb.c b/drivers/usb/core/usb.c index 77e4c9bc0ab1..ebb29caa3fe4 100644 --- a/drivers/usb/core/usb.c +++ b/drivers/usb/core/usb.c | |||
@@ -311,7 +311,13 @@ static int usb_dev_uevent(struct device *dev, struct kobj_uevent_env *env) | |||
311 | 311 | ||
312 | static int usb_dev_prepare(struct device *dev) | 312 | static int usb_dev_prepare(struct device *dev) |
313 | { | 313 | { |
314 | return 0; /* Implement eventually? */ | 314 | struct usb_device *udev = to_usb_device(dev); |
315 | |||
316 | /* Return 0 if the current wakeup setting is wrong, otherwise 1 */ | ||
317 | if (udev->do_remote_wakeup != device_may_wakeup(dev)) | ||
318 | return 0; | ||
319 | |||
320 | return 1; | ||
315 | } | 321 | } |
316 | 322 | ||
317 | static void usb_dev_complete(struct device *dev) | 323 | static void usb_dev_complete(struct device *dev) |