On Saturday, 17 of November 2007, Rafael J. Wysocki wrote:
Actually, not even that one. You're right anyway.
Below is a patch that IMO should fix the issue with apm_ioctl().
Greetings,
Rafael
---
From: Rafael J. Wysocki <rjw@sisk.pl>
The code in apm_ioctl() allows user space tasks waiting for a suspend to
complete to be woken up prematurely as a result of the thawing of tasks carried
out by the freezer. Fix it.
Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
---
drivers/char/apm-emulation.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Index: linux-2.6/drivers/char/apm-emulation.c
===================================================================
--- linux-2.6.orig/drivers/char/apm-emulation.c
+++ linux-2.6/drivers/char/apm-emulation.c
@@ -364,7 +364,7 @@ apm_ioctl(struct inode * inode, struct f
*/
flags = current->flags;
- wait_event_interruptible(apm_suspend_waitqueue,
+ wait_event_freezable(apm_suspend_waitqueue,
as->suspend_state == SUSPEND_DONE);
}
-