aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/thermal
diff options
context:
space:
mode:
authorlan,Tianyu <tianyu.lan@intel.com>2014-01-02 02:47:54 -0500
committerZhang Rui <rui.zhang@intel.com>2014-01-03 09:54:20 -0500
commit800744bf31df54b0cd4d1104ccfa426d3f578f0e (patch)
tree94c3bc56b40804c0e3c13d74d03738bb496f93ae /drivers/thermal
parent7734e3ac89b27caf87d43d264bbbc26240413227 (diff)
Thermal: update thermal zone device after setting emul_temp
This patch is to update thermal zone device after setting emul_temp in order to make governor work according to input temperature immediately. Signed-off-by: Lan Tianyu <tianyu.lan@intel.com> Signed-off-by: Zhang Rui <rui.zhang@intel.com>
Diffstat (limited to 'drivers/thermal')
-rw-r--r--drivers/thermal/thermal_core.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/thermal/thermal_core.c b/drivers/thermal/thermal_core.c
index 30a02add9e2e..45632bc05cc7 100644
--- a/drivers/thermal/thermal_core.c
+++ b/drivers/thermal/thermal_core.c
@@ -777,6 +777,9 @@ emul_temp_store(struct device *dev, struct device_attribute *attr,
777 ret = tz->ops->set_emul_temp(tz, temperature); 777 ret = tz->ops->set_emul_temp(tz, temperature);
778 } 778 }
779 779
780 if (!ret)
781 thermal_zone_device_update(tz);
782
780 return ret ? ret : count; 783 return ret ? ret : count;
781} 784}
782static DEVICE_ATTR(emul_temp, S_IWUSR, NULL, emul_temp_store); 785static DEVICE_ATTR(emul_temp, S_IWUSR, NULL, emul_temp_store);