Skip to content

Commit 0f510a2

Browse files
Niklas Söderlunddlezcano
authored andcommitted
thermal: rcar_gen3_thermal: Remove temperature bound
The hardware manual states that the operation of the sensor is not guaranteed with temperatures above 125°C, not that the readings are invalid. Remove the bound check and try to deliver temperature readings even if we are outside the guaranteed operation range. Signed-off-by: Niklas Söderlund <[email protected]> Signed-off-by: Daniel Lezcano <[email protected]> Link: https://lore.kernel.org/r/[email protected]
1 parent dff6d4f commit 0f510a2

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

drivers/thermal/rcar_gen3_thermal.c

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -182,9 +182,7 @@ static int rcar_gen3_thermal_get_temp(void *devdata, int *temp)
182182
tsc->coef.a2);
183183
mcelsius = FIXPT_TO_MCELSIUS(val);
184184

185-
/* Make sure we are inside specifications */
186-
if ((mcelsius < MCELSIUS(-40)) || (mcelsius > MCELSIUS(125)))
187-
return -EIO;
185+
/* Guaranteed operating range is -40C to 125C. */
188186

189187
/* Round value to device granularity setting */
190188
*temp = rcar_gen3_thermal_round(mcelsius);

0 commit comments

Comments
 (0)