USB / Hub: Do not call device_set_wakeup_capable() under spinlock
authorRafael J. Wysocki <rjw@sisk.pl>
Tue, 8 Feb 2011 22:25:48 +0000 (23:25 +0100)
committerRafael J. Wysocki <rjw@sisk.pl>
Mon, 14 Mar 2011 23:43:14 +0000 (00:43 +0100)
commit4681b17154b3fd81f898802262985f662344e6ed
tree5670e6668fe43dad7bb19dd91e227d2d09dbd066
parent0295a34d61f14522fddb26856191520d2e1d7e77
USB / Hub: Do not call device_set_wakeup_capable() under spinlock

A subsequent patch will modify device_set_wakeup_capable() in such
a way that it will call functions which may sleep and therefore it
shouldn't be called under spinlocks.  In preparation to that, modify
usb_set_device_state() to avoid calling device_set_wakeup_capable()
under device_state_lock.

Tested-by: Minchan Kim <minchan.kim@gmail.com>
Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Acked-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/usb/core/hub.c