diff options
author | Zhang Rui <rui.zhang@intel.com> | 2012-06-27 14:13:04 +0800 |
---|---|---|
committer | Zhang Rui <rui.zhang@intel.com> | 2012-09-24 14:44:37 +0800 |
commit | ce119f83257aae29b84a5bfad0669e8348437b18 (patch) | |
tree | 82ef036b21cc958beed8a0c7def6fbe50ab3ca1b /include/linux/thermal.h | |
parent | b5e4ae620b06274981781aeadc2aea50b507f7fb (diff) | |
download | lwn-ce119f83257aae29b84a5bfad0669e8348437b18.tar.gz lwn-ce119f83257aae29b84a5bfad0669e8348437b18.zip |
Thermal: Introduce simple arbitrator for setting device cooling state
This fixes the problem that a cooling device may be referenced by
by multiple trip points in multiple thermal zones.
With this patch, we have two stages for updating a thermal zone,
1. check if a thermal_instance needs to be updated or not
2. update the cooling device, based on the target cooling state
of all its instances.
Note that, currently, the cooling device is set to the deepest
cooling state required.
Signed-off-by: Zhang Rui <rui.zhang@intel.com>
Reviewed-by: Rafael J. Wysocki <rjw@sisk.pl>
Reviewed-by: Eduardo Valentin <eduardo.valentin@ti.com>
Diffstat (limited to 'include/linux/thermal.h')
-rw-r--r-- | include/linux/thermal.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/thermal.h b/include/linux/thermal.h index 9ae378a4a555..de0515a96f9f 100644 --- a/include/linux/thermal.h +++ b/include/linux/thermal.h @@ -94,6 +94,7 @@ struct thermal_cooling_device { struct device device; void *devdata; const struct thermal_cooling_device_ops *ops; + bool updated; /* true if the cooling device does not need update */ struct list_head thermal_instances; struct list_head node; }; |