summaryrefslogtreecommitdiffstats
path: root/drivers/thermal
diff options
context:
space:
mode:
authorFrans Pop <elendil@planet.nl>2009-10-26 08:39:04 +0100
committerLen Brown <len.brown@intel.com>2009-11-05 18:19:01 -0500
commit3767cb54ac718eb049d2a29f7a575ab923550ba5 (patch)
treedbb0cbe06c7523a3096ac11b31f7e8f123e220d3 /drivers/thermal
parente4143b0324a6a468cb00c4341cd20d60cc441252 (diff)
downloadop-kernel-dev-3767cb54ac718eb049d2a29f7a575ab923550ba5.zip
op-kernel-dev-3767cb54ac718eb049d2a29f7a575ab923550ba5.tar.gz
thermal: disable polling if passive_delay and polling_delay are both unset
Otherwise polling will continue for the thermal zone even when it is no longer needed, for example because forced passive cooling was disabled. Signed-off-by: Frans Pop <elendil@planet.nl> Acked-by: Matthew Garrett <mjg@redhat.com> Acked-by: Zhang Rui <rui.zhang@intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/thermal')
-rw-r--r--drivers/thermal/thermal_sys.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/thermal/thermal_sys.c b/drivers/thermal/thermal_sys.c
index 663c2fd..3bc72ea 100644
--- a/drivers/thermal/thermal_sys.c
+++ b/drivers/thermal/thermal_sys.c
@@ -1019,6 +1019,8 @@ void thermal_zone_device_update(struct thermal_zone_device *tz)
thermal_zone_device_set_polling(tz, tz->passive_delay);
else if (tz->polling_delay)
thermal_zone_device_set_polling(tz, tz->polling_delay);
+ else
+ thermal_zone_device_set_polling(tz, 0);
mutex_unlock(&tz->lock);
}
EXPORT_SYMBOL(thermal_zone_device_update);
OpenPOWER on IntegriCloud