提交 af9f251b 编写于 作者: D Daniel Lezcano 提交者: Daniel Lezcano

thermal/of: Remove the device node pointer for thermal_trip

The device node pointer is no longer needed in the thermal trip
structure, remove it.

Cc: Alexandre Bailon <abailon@baylibre.com>
Cc: Kevin Hilman <khilman@baylibre.com>
Signed-off-by: NDaniel Lezcano <daniel.lezcano@linexp.org>
Reviewed-by: NLukasz Luba <lukasz.luba@arm.com>
Link: https://lore.kernel.org/r/20220722200007.1839356-4-daniel.lezcano@linexp.orgSigned-off-by: NDaniel Lezcano <daniel.lezcano@linaro.org>
上级 a3193edc
......@@ -70,13 +70,11 @@ void __thermal_cdev_update(struct thermal_cooling_device *cdev);
/**
* struct thermal_trip - representation of a point in temperature domain
* @np: pointer to struct device_node that this trip point was created from
* @temperature: temperature value in miliCelsius
* @hysteresis: relative hysteresis in miliCelsius
* @type: trip point type
*/
struct thermal_trip {
struct device_node *np;
int temperature;
int hysteresis;
enum thermal_trip_type type;
......
......@@ -867,10 +867,6 @@ static int thermal_of_populate_trip(struct device_node *np,
return ret;
}
/* Required for cooling map matching */
trip->np = np;
of_node_get(np);
return 0;
}
......@@ -1001,8 +997,6 @@ __init *thermal_of_build_thermal_zone(struct device_node *np)
kfree(tz->tbps);
free_trips:
for (i = 0; i < tz->ntrips; i++)
of_node_put(tz->trips[i].np);
kfree(tz->trips);
of_node_put(trips);
of_node_put(gchild);
......@@ -1028,8 +1022,6 @@ static __init void of_thermal_free_zone(struct __thermal_zone *tz)
}
kfree(tz->tbps);
for (i = 0; i < tz->ntrips; i++)
of_node_put(tz->trips[i].np);
kfree(tz->trips);
kfree(tz);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册