summaryrefslogtreecommitdiff
path: root/arch/arm/mach-tegra/board-enterprise-sensors.c
diff options
context:
space:
mode:
authorJoshua Primero <jprimero@nvidia.com>2011-12-18 15:44:25 -0800
committerVarun Wadekar <vwadekar@nvidia.com>2011-12-22 11:31:16 +0530
commit32ff2dc25622e3a0367326729c5b483c64ae2f29 (patch)
tree33418ae37cf65ee5138d2f83381ee93501bc1209 /arch/arm/mach-tegra/board-enterprise-sensors.c
parent29a18b43d3bfeaf240094c54cb7946ba6b4975c0 (diff)
arm: tegra: thermal: Low temp to therm algorithm
Instead of using 0C as default low temp in thermal algorithm, query the thermal device driver for lowest supported temperature. Change-Id: Id1f70380ba476dec80e36ce79b42ab6f24a5d5ba Signed-off-by: Joshua Primero <jprimero@nvidia.com> Reviewed-on: http://git-master/r/70935 Reviewed-by: Rohan Somvanshi <rsomvanshi@nvidia.com> Tested-by: Rohan Somvanshi <rsomvanshi@nvidia.com>
Diffstat (limited to 'arch/arm/mach-tegra/board-enterprise-sensors.c')
-rw-r--r--arch/arm/mach-tegra/board-enterprise-sensors.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/arch/arm/mach-tegra/board-enterprise-sensors.c b/arch/arm/mach-tegra/board-enterprise-sensors.c
index 889348d4a1c6..68544692bcee 100644
--- a/arch/arm/mach-tegra/board-enterprise-sensors.c
+++ b/arch/arm/mach-tegra/board-enterprise-sensors.c
@@ -58,6 +58,12 @@ static int nct_get_temp(void *_data, long *temp)
return nct1008_thermal_get_temp(data, temp);
}
+static int nct_get_temp_low(void *_data, long *temp)
+{
+ struct nct1008_data *data = _data;
+ return nct1008_thermal_get_temp_low(data, temp);
+}
+
static int nct_set_limits(void *_data,
long lo_limit_milli,
long hi_limit_milli)
@@ -98,6 +104,7 @@ static void nct1008_probe_callback(struct nct1008_data *data)
thermal_device->data = data;
thermal_device->offset = TDIODE_OFFSET;
thermal_device->get_temp = nct_get_temp;
+ thermal_device->get_temp_low = nct_get_temp_low;
thermal_device->set_limits = nct_set_limits;
thermal_device->set_alert = nct_set_alert;
thermal_device->set_shutdown_temp = nct_set_shutdown_temp;