From 561d9a969455cb009bb15b63e1d925dc527e7a9d Mon Sep 17 00:00:00 2001 From: "Rafael J. Wysocki" Date: Mon, 3 Dec 2007 18:01:50 +0100 Subject: HWMON: coretemp, suspend fix MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit It's not permitted to unregister a device after devices have been suspended. It causes deadlocks to appear on systems with coretemp hwmon loaded.  To avoid this, we can make coretemp_cpu_callback() do nothing if the _FROZEN bit is set in action.   Also, in other cases it's generally too late to unregister the coretemp device if the CPU is already dead, so it should be unregistered on CPU_DOWN_PREPARE.   Signed-off-by: Rafael J. Wysocki Acked-by: Mark M. Hoffman Cc: Jiri Slaby Cc: Andrew Morton Signed-off-by: Len Brown --- drivers/hwmon/coretemp.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/hwmon/coretemp.c b/drivers/hwmon/coretemp.c index 5c82ec7f8bb..3ee60d26e3a 100644 --- a/drivers/hwmon/coretemp.c +++ b/drivers/hwmon/coretemp.c @@ -337,11 +337,10 @@ static int coretemp_cpu_callback(struct notifier_block *nfb, switch (action) { case CPU_ONLINE: - case CPU_ONLINE_FROZEN: + case CPU_DOWN_FAILED: coretemp_device_add(cpu); break; - case CPU_DEAD: - case CPU_DEAD_FROZEN: + case CPU_DOWN_PREPARE: coretemp_device_remove(cpu); break; } -- cgit v1.2.3 From e136e769d471e7f3d24a8f6bf9c91dcb372bd0ab Mon Sep 17 00:00:00 2001 From: "Rafael J. Wysocki" Date: Tue, 4 Dec 2007 01:11:09 +0100 Subject: Freezer: Fix JFFS2 garbage collector freezing issue (rev. 2) Fix breakage caused by commit d5d8c5976d6adeddb8208c240460411e2198b393 "freezer: do not send signals to kernel threads" in jffs2_garbage_collect_thread() that assumed it would be sent signals by the freezer. Signed-off-by: Rafael J. Wysocki Cc: David Woodhouse Cc: Pete MacKay Signed-off-by: Len Brown --- fs/jffs2/background.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/jffs2/background.c b/fs/jffs2/background.c index d568ae84674..8adebd3e43c 100644 --- a/fs/jffs2/background.c +++ b/fs/jffs2/background.c @@ -105,7 +105,7 @@ static int jffs2_garbage_collect_thread(void *_c) /* Put_super will send a SIGKILL and then wait on the sem. */ - while (signal_pending(current)) { + while (signal_pending(current) || freezing(current)) { siginfo_t info; unsigned long signr; -- cgit v1.2.3 From 74d0f3338fbb3c69894968df1fedaf10c88cd0e4 Mon Sep 17 00:00:00 2001 From: Pavel Machek Date: Thu, 6 Dec 2007 09:50:40 +0100 Subject: ACPI: suspend: old debugging hacks sneaked back Old debugging hack sneaked back during x86 merge, this removes it. Signed-off-by: Pavel Machek Acked-by: Rafael J. Wysocki Signed-off-by: Len Brown --- arch/x86/kernel/acpi/wakeup_32.S | 4 ---- 1 file changed, 4 deletions(-) diff --git a/arch/x86/kernel/acpi/wakeup_32.S b/arch/x86/kernel/acpi/wakeup_32.S index a97313b1270..1e931aaf2ef 100644 --- a/arch/x86/kernel/acpi/wakeup_32.S +++ b/arch/x86/kernel/acpi/wakeup_32.S @@ -35,10 +35,6 @@ wakeup_code: wakeup_code_start = . .code16 - movw $0xb800, %ax - movw %ax,%fs - movw $0x0e00 + 'L', %fs:(0x10) - cli cld -- cgit v1.2.3