aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Lezcano <[email protected]>2022-10-03 11:25:52 +0200
committerDaniel Lezcano <[email protected]>2023-01-06 14:14:47 +0100
commitaacfbf15e0ac2ba1e1b848fc439a9c7c7fd90934 (patch)
tree7278dfc00127a888945349e27e6682f7bb908684
parent810245133eaec213517bad835e394cbf4fb2d6cd (diff)
thermal/of: Remove of_thermal_get_crit_temp()
The generic version of of_thermal_get_crit_temp() can be used. Let's remove this ops which is pointless. Signed-off-by: Daniel Lezcano <[email protected]> Link: https://lore.kernel.org/r/[email protected]
-rw-r--r--drivers/thermal/thermal_of.c15
1 files changed, 0 insertions, 15 deletions
diff --git a/drivers/thermal/thermal_of.c b/drivers/thermal/thermal_of.c
index 2fcdb3e459c0..ff4d12ef51bc 100644
--- a/drivers/thermal/thermal_of.c
+++ b/drivers/thermal/thermal_of.c
@@ -19,20 +19,6 @@
#include "thermal_core.h"
-static int of_thermal_get_crit_temp(struct thermal_zone_device *tz,
- int *temp)
-{
- int i;
-
- for (i = 0; i < tz->num_trips; i++)
- if (tz->trips[i].type == THERMAL_TRIP_CRITICAL) {
- *temp = tz->trips[i].temperature;
- return 0;
- }
-
- return -EINVAL;
-}
-
/*** functions parsing device tree nodes ***/
static int of_find_trip_id(struct device_node *np, struct device_node *trip)
@@ -531,7 +517,6 @@ struct thermal_zone_device *thermal_of_zone_register(struct device_node *sensor,
goto out_kfree_trips;
}
- of_ops->get_crit_temp = of_ops->get_crit_temp ? : of_thermal_get_crit_temp;
of_ops->bind = thermal_of_bind;
of_ops->unbind = thermal_of_unbind;