From ee6921f7d82c765011b1df146cbc1103720ab33b Mon Sep 17 00:00:00 2001 From: Uwe Kleine-Koenig Date: Mon, 12 Jan 2009 23:35:46 +0100 Subject: trivial: fix typo "thier" -> "their" Signed-off-by: Uwe Kleine-Koenig Signed-off-by: Jiri Kosina --- drivers/base/sys.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/base/sys.c') diff --git a/drivers/base/sys.c b/drivers/base/sys.c index cbd36cf59a0f..6206aaac6b08 100644 --- a/drivers/base/sys.c +++ b/drivers/base/sys.c @@ -299,7 +299,7 @@ void sysdev_unregister(struct sys_device *sysdev) * and the class driver. * * Note: The list is iterated in reverse order, so that we shut down - * child devices before we shut down thier parents. The list ordering + * child devices before we shut down their parents. The list ordering * is guaranteed by virtue of the fact that child devices are registered * after their parents. */ -- cgit v1.2.3 From 2ed8d2b3a81bdbb0418301628ccdb008ac9f40b7 Mon Sep 17 00:00:00 2001 From: "Rafael J. Wysocki" Date: Mon, 16 Mar 2009 22:34:06 +0100 Subject: PM: Rework handling of interrupts during suspend-resume Use the functions introduced in by the previous patch, suspend_device_irqs(), resume_device_irqs() and check_wakeup_irqs(), to rework the handling of interrupts during suspend (hibernation) and resume. Namely, interrupts will only be disabled on the CPU right before suspending sysdevs, while device drivers will be prevented from receiving interrupts, with the help of the new helper function, before their "late" suspend callbacks run (and analogously during resume). In addition, since the device interrups are now disabled before the CPU has turned all interrupts off and the CPU will ACK the interrupts setting the IRQ_PENDING bit for them, check in sysdev_suspend() if any wake-up interrupts are pending and abort suspend if that's the case. Signed-off-by: Rafael J. Wysocki Acked-by: Ingo Molnar --- drivers/base/sys.c | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'drivers/base/sys.c') diff --git a/drivers/base/sys.c b/drivers/base/sys.c index cbd36cf59a0f..76ce75bad91e 100644 --- a/drivers/base/sys.c +++ b/drivers/base/sys.c @@ -22,6 +22,7 @@ #include #include #include +#include #include "base.h" @@ -369,6 +370,13 @@ int sysdev_suspend(pm_message_t state) struct sysdev_driver *drv, *err_drv; int ret; + pr_debug("Checking wake-up interrupts\n"); + + /* Return error code if there are any wake-up interrupts pending */ + ret = check_wakeup_irqs(); + if (ret) + return ret; + pr_debug("Suspending System Devices\n"); list_for_each_entry_reverse(cls, &system_kset->list, kset.kobj.entry) { -- cgit v1.2.3