diff options
Diffstat (limited to 'include/linux/thermal.h')
-rw-r--r-- | include/linux/thermal.h | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/include/linux/thermal.h b/include/linux/thermal.h index 796f1ff0388c..6eaf9146c847 100644 --- a/include/linux/thermal.h +++ b/include/linux/thermal.h | |||
@@ -58,6 +58,8 @@ struct thermal_zone_device_ops { | |||
58 | enum thermal_trip_type *); | 58 | enum thermal_trip_type *); |
59 | int (*get_trip_temp) (struct thermal_zone_device *, int, | 59 | int (*get_trip_temp) (struct thermal_zone_device *, int, |
60 | unsigned long *); | 60 | unsigned long *); |
61 | int (*set_trip_temp) (struct thermal_zone_device *, int, | ||
62 | unsigned long); | ||
61 | int (*get_crit_temp) (struct thermal_zone_device *, unsigned long *); | 63 | int (*get_crit_temp) (struct thermal_zone_device *, unsigned long *); |
62 | int (*notify) (struct thermal_zone_device *, int, | 64 | int (*notify) (struct thermal_zone_device *, int, |
63 | enum thermal_trip_type); | 65 | enum thermal_trip_type); |
@@ -85,10 +87,17 @@ struct thermal_cooling_device { | |||
85 | ((long)t-2732+5)/10 : ((long)t-2732-5)/10) | 87 | ((long)t-2732+5)/10 : ((long)t-2732-5)/10) |
86 | #define CELSIUS_TO_KELVIN(t) ((t)*10+2732) | 88 | #define CELSIUS_TO_KELVIN(t) ((t)*10+2732) |
87 | 89 | ||
90 | struct thermal_attr { | ||
91 | struct device_attribute attr; | ||
92 | char name[THERMAL_NAME_LENGTH]; | ||
93 | }; | ||
94 | |||
88 | struct thermal_zone_device { | 95 | struct thermal_zone_device { |
89 | int id; | 96 | int id; |
90 | char type[THERMAL_NAME_LENGTH]; | 97 | char type[THERMAL_NAME_LENGTH]; |
91 | struct device device; | 98 | struct device device; |
99 | struct thermal_attr *trip_temp_attrs; | ||
100 | struct thermal_attr *trip_type_attrs; | ||
92 | void *devdata; | 101 | void *devdata; |
93 | int trips; | 102 | int trips; |
94 | int tc1; | 103 | int tc1; |
@@ -137,9 +146,9 @@ enum { | |||
137 | }; | 146 | }; |
138 | #define THERMAL_GENL_CMD_MAX (__THERMAL_GENL_CMD_MAX - 1) | 147 | #define THERMAL_GENL_CMD_MAX (__THERMAL_GENL_CMD_MAX - 1) |
139 | 148 | ||
140 | struct thermal_zone_device *thermal_zone_device_register(char *, int, void *, | 149 | struct thermal_zone_device *thermal_zone_device_register(char *, int, int, |
141 | const struct thermal_zone_device_ops *, int tc1, int tc2, | 150 | void *, const struct thermal_zone_device_ops *, int tc1, |
142 | int passive_freq, int polling_freq); | 151 | int tc2, int passive_freq, int polling_freq); |
143 | void thermal_zone_device_unregister(struct thermal_zone_device *); | 152 | void thermal_zone_device_unregister(struct thermal_zone_device *); |
144 | 153 | ||
145 | int thermal_zone_bind_cooling_device(struct thermal_zone_device *, int, | 154 | int thermal_zone_bind_cooling_device(struct thermal_zone_device *, int, |