ACK: [SRU][M:raspi][PATCH] Fix hysteresis support in gov_step_wise.c (#5736)
Agathe Porte
agathe.porte at canonical.com
Mon Nov 27 10:14:13 UTC 2023
2023-11-24 19:49 CET, Juerg Haefliger:
> From: Jürgen Kreileder <jk at blackdown.de>
>
> BugLink: https://bugs.launchpad.net/bugs/2044341
>
> Fix hysteresis support in gov_step_wise.c
>
> Directly get hyst value instead of going through an
> optional and, now, unimplemented function.
>
> Signed-off-by: Jürgen Kreileder <jk at blackdown.de>
> (cherry picked from commit d3668f4e7e2747f38d7f680df231f02dd33d3a13 rpi-6.5.y)
> Signed-off-by: Juerg Haefliger <juerg.haefliger at canonical.com>
> ---
> drivers/thermal/gov_step_wise.c | 7 ++-----
> 1 file changed, 2 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/thermal/gov_step_wise.c b/drivers/thermal/gov_step_wise.c
> index eefeb6407d0f..8b83fbb933db 100644
> --- a/drivers/thermal/gov_step_wise.c
> +++ b/drivers/thermal/gov_step_wise.c
> @@ -98,11 +98,8 @@ static void thermal_zone_trip_update(struct thermal_zone_device *tz, int trip_id
> trace_thermal_zone_trip(tz, trip_id, trip.type);
> }
>
> - hyst_temp = trip_temp = trip.temperature;
> - if (tz->ops->get_trip_hyst) {
> - tz->ops->get_trip_hyst(tz, trip_id, &hyst_temp);
> - hyst_temp = trip_temp - hyst_temp;
> - }
> + trip_temp = trip.temperature;
> + hyst_temp = trip_temp - trip.hysteresis;
> trip_type = trip.type;
>
> dev_dbg(&tz->device,
Acked-by: Agathe Porte <agathe.porte at canonical.com>
More information about the kernel-team
mailing list