From: Paul Parsons Date: Fri, 13 May 2011 01:46:03 +0000 (+0100) Subject: apm-emulation: apm_mutex breaks ACK; remove it X-Git-Tag: v3.0-rc1~346^2 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fda5fe19725edd6805f2fd742235d1a0d0ba93f5;p=pandora-kernel.git apm-emulation: apm_mutex breaks ACK; remove it apm_mutex is locked by a process (e.g. apm -s) at the start of apm_ioctl() and remains locked while pm_suspend() is called. Any subsequent process trying to ACK the suspend (e.g. apmd) is then blocked at the start of apm_ioctl(), causing the suspend to be delayed for 5 seconds in apm_suspend_notifier() while the ACK times out. In short, ACKs don't work. The driver's data structures are sufficiently protected by assorted locks. And pm_suspend() has its own mutex to prevent reentrancy. Consequently there is no obvious requirement for apm_mutex, which evolved from earlier BKL calls. So let's remove it. Signed-off-by: Paul Parsons Acked-by: Rafael J. Wysocki Signed-off-by: Jiri Kosina --- Reading git-diff-tree failed