summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorRam Chandrasekar <rkumbako@codeaurora.org>2013-10-02 12:23:27 -0600
committerDavid Keitel <dkeitel@codeaurora.org>2016-03-22 11:08:20 -0700
commit9e0b2db23b67a3d98004a1d68f0dc3a950da93bd (patch)
tree68e263a1a6137589f88672fe52861a8116bc580c /include/linux
parent6ed698c7593abb1fcc8f4ad96110a0eaaf8154fd (diff)
thermal: Add Support for enabling and disabling tsens trip
Add new API to enable or disable the kernel client's trip threshold request. The enable or disable trip threshold requests from different kernel clients and userspace client will activate/deactivate the corresponding clients threshold request. Modify thermal sys framework to include only the active thresholds from clients to determine the current trip thresholds for tsens. CRs-Fixed: 561775 Change-Id: I304ac00daa8a0a1a68b60153c29ee6cb5c3507b1 Signed-off-by: Ram Chandrasekar <rkumbako@codeaurora.org> [joshc: drop msm_thermal chunk] Signed-off-by: Josh Cartwright <joshc@codeaurora.org>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/thermal.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/linux/thermal.h b/include/linux/thermal.h
index 2bab7a26db20..89de2ca82974 100644
--- a/include/linux/thermal.h
+++ b/include/linux/thermal.h
@@ -158,6 +158,7 @@ struct sensor_threshold {
enum thermal_trip_type trip;
int (*notify)(enum thermal_trip_type type, int temp, void *data);
void *data;
+ uint8_t active;
struct list_head list;
};
@@ -449,6 +450,8 @@ void thermal_notify_framework(struct thermal_zone_device *, int);
int sensor_get_id(char *name);
int sensor_set_trip(uint32_t sensor_id, struct sensor_threshold *threshold);
int sensor_cancel_trip(uint32_t sensor_id, struct sensor_threshold *threshold);
+int sensor_activate_trip(uint32_t sensor_id, struct sensor_threshold *threshold,
+ bool enable);
int thermal_sensor_trip(struct thermal_zone_device *tz,
enum thermal_trip_type trip, long temp);