PM: Do not acquire device semaphores upfront during suspend
authorRafael J. Wysocki <rjw@sisk.pl>
Sun, 24 Feb 2008 23:35:04 +0000 (00:35 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 4 Mar 2008 22:47:05 +0000 (14:47 -0800)
commit7a8d37a37380e2b1500592d40b7ec384dbebe7a0
tree9a23b48e49ffc3303e5998f20498c994da2788c1
parenta4573c488dd531c6e2d308ce8a7413c4a2646207
PM: Do not acquire device semaphores upfront during suspend

Remove the code that acquires all device semaphores from the suspend
code path as it causes multiple problems to appear (most notably,
http://bugzilla.kernel.org/show_bug.cgi?id=10030) and revert the
change introduced by commit 4145ed6dc597a9bea5f6ae8c574653b2de10620f
depending on the code being removed.

Remove pm_sleep_lock()/pm_sleep_unlock() from device_add() to avoid
the issue reported at http://bugzilla.kernel.org/show_bug.cgi?id=9874.

It should fix the regreesions reported at:
http://bugzilla.kernel.org/show_bug.cgi?id=9874
http://bugzilla.kernel.org/show_bug.cgi?id=10030

Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/base/core.c
drivers/base/power/main.c
drivers/usb/core/usb.c