summaryrefslogtreecommitdiffstats
path: root/include/linux/thermal.h
diff options
context:
space:
mode:
authorDaniel Lezcano <daniel.lezcano@linexp.org>2022-07-22 22:00:01 +0200
committerDaniel Lezcano <daniel.lezcano@linaro.org>2022-07-28 17:29:54 +0200
commit646274ddaf756dc549fc98cc581fc1ce4fef517a (patch)
tree270b9f7242029a089ebc20dfe81ecb40232c442f /include/linux/thermal.h
parentaf9f251b8e396eca8355904ad8a4361a95af4e61 (diff)
downloadlinux-stable-646274ddaf756dc549fc98cc581fc1ce4fef517a.tar.gz
linux-stable-646274ddaf756dc549fc98cc581fc1ce4fef517a.tar.bz2
linux-stable-646274ddaf756dc549fc98cc581fc1ce4fef517a.zip
thermal/of: Move thermal_trip structure to thermal.h
The structure thermal_trip is now generic and will be usable by the different sensor drivers in place of their own structure. Move its definition to thermal.h to make it accessible. Cc: Alexandre Bailon <abailon@baylibre.com> Cc: Kevin Hilman <khilman@baylibre.com> Signed-off-by: Daniel Lezcano <daniel.lezcano@linexp.org> Reviewed-by: Lukasz Luba <lukasz.luba@arm.com> Link: https://lore.kernel.org/r/20220722200007.1839356-5-daniel.lezcano@linexp.org Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
Diffstat (limited to 'include/linux/thermal.h')
-rw-r--r--include/linux/thermal.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/include/linux/thermal.h b/include/linux/thermal.h
index 231bac2768fb..7e66970f0464 100644
--- a/include/linux/thermal.h
+++ b/include/linux/thermal.h
@@ -78,6 +78,18 @@ struct thermal_zone_device_ops {
void (*critical)(struct thermal_zone_device *);
};
+/**
+ * struct thermal_trip - representation of a point in temperature domain
+ * @temperature: temperature value in miliCelsius
+ * @hysteresis: relative hysteresis in miliCelsius
+ * @type: trip point type
+ */
+struct thermal_trip {
+ int temperature;
+ int hysteresis;
+ enum thermal_trip_type type;
+};
+
struct thermal_cooling_device_ops {
int (*get_max_state) (struct thermal_cooling_device *, unsigned long *);
int (*get_cur_state) (struct thermal_cooling_device *, unsigned long *);