* [PATCH] thermal: Prevent polling from happening during system suspend
@ 2011-08-14 21:30 Rafael J. Wysocki
0 siblings, 0 replies; only message in thread
From: Rafael J. Wysocki @ 2011-08-14 21:30 UTC (permalink / raw)
To: Len Brown; +Cc: LKML, ACPI Devel Mailing List, Linux PM mailing list
From: Rafael J. Wysocki <rjw@sisk.pl>
The thermal driver should use a freezable workqueue to schedule
polling to prevent thermal_zone_device_update() from being run
during system suspend, when the devices it relies on may be inactive.
Make it use the system freezable workqueue for this purpose.
Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
---
drivers/thermal/thermal_sys.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
Index: linux/drivers/thermal/thermal_sys.c
===================================================================
--- linux.orig/drivers/thermal/thermal_sys.c
+++ linux/drivers/thermal/thermal_sys.c
@@ -678,10 +678,10 @@ static void thermal_zone_device_set_poll
return;
if (delay > 1000)
- schedule_delayed_work(&(tz->poll_queue),
+ queue_delayed_work(system_freezable_wq, &(tz->poll_queue),
round_jiffies(msecs_to_jiffies(delay)));
else
- schedule_delayed_work(&(tz->poll_queue),
+ queue_delayed_work(system_freezable_wq, &(tz->poll_queue),
msecs_to_jiffies(delay));
}
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2011-08-14 21:29 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-08-14 21:30 [PATCH] thermal: Prevent polling from happening during system suspend Rafael J. Wysocki
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox