diff options
author | Durgadoss R <durgadoss.r@intel.com> | 2012-09-18 11:04:55 +0530 |
---|---|---|
committer | Zhang Rui <rui.zhang@intel.com> | 2012-11-05 13:56:32 +0800 |
commit | ef87394791206019e4e4e04cb746865f2dc115ed (patch) | |
tree | 704c497f48469bcdad2c89724d48984c799135d4 /include/linux/thermal.h | |
parent | 9b4298a088907811a4fe5a5d7cd2454da60708c5 (diff) |
Thermal: Add platform level information to thermal.h
This patch adds platform level information to thermal.h
by introducing two structures to hold:
* bind parameters for a thermal zone,
* zone level platform parameters
Signed-off-by: Durgadoss R <durgadoss.r@intel.com>
Signed-off-by: Zhang Rui <rui.zhang@intel.com>
Diffstat (limited to 'include/linux/thermal.h')
-rw-r--r-- | include/linux/thermal.h | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/include/linux/thermal.h b/include/linux/thermal.h index 32af124d23c..4caa32e400b 100644 --- a/include/linux/thermal.h +++ b/include/linux/thermal.h @@ -157,6 +157,7 @@ struct thermal_zone_device { int passive; unsigned int forced_passive; const struct thermal_zone_device_ops *ops; + const struct thermal_zone_params *tzp; struct list_head thermal_instances; struct idr idr; struct mutex lock; /* protect thermal_instances list */ @@ -164,6 +165,34 @@ struct thermal_zone_device { struct delayed_work poll_queue; }; +/* Structure that holds binding parameters for a zone */ +struct thermal_bind_params { + struct thermal_cooling_device *cdev; + + /* + * This is a measure of 'how effectively these devices can + * cool 'this' thermal zone. The shall be determined by platform + * characterization. This is on a 'percentage' scale. + * See Documentation/thermal/sysfs-api.txt for more information. + */ + int weight; + + /* + * This is a bit mask that gives the binding relation between this + * thermal zone and cdev, for a particular trip point. + * See Documentation/thermal/sysfs-api.txt for more information. + */ + int trip_mask; + int (*match) (struct thermal_zone_device *tz, + struct thermal_cooling_device *cdev); +}; + +/* Structure to define Thermal Zone parameters */ +struct thermal_zone_params { + int num_tbps; /* Number of tbp entries */ + struct thermal_bind_params *tbp; +}; + struct thermal_genl_event { u32 orig; enum events event; |