Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 270ba432 authored by Niklas Söderlund's avatar Niklas Söderlund Committed by Eduardo Valentin
Browse files

thermal: rcar_gen3_thermal: update max temperature clamp



Change the upper limit to clamp the high temperature value to 120C when
setting trip points.

Signed-off-by: default avatarNiklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
Reviewed-by: default avatarSimon Horman <horms+renesas@verge.net.au>
Signed-off-by: default avatarEduardo Valentin <edubezval@gmail.com>
parent fc66ddff
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -207,8 +207,8 @@ static int rcar_gen3_thermal_set_trips(void *devdata, int low, int high)
{
	struct rcar_gen3_thermal_tsc *tsc = devdata;

	low = clamp_val(low, -40000, 125000);
	high = clamp_val(high, -40000, 125000);
	low = clamp_val(low, -40000, 120000);
	high = clamp_val(high, -40000, 120000);

	rcar_gen3_thermal_write(tsc, REG_GEN3_IRQTEMP1,
				rcar_gen3_thermal_mcelsius_to_temp(tsc, low));