Commit 9a10c5a9 authored by Vaibhav Gupta's avatar Vaibhav Gupta

software: kernel: hwmon: Export correct value of temp

The temperature retrieved from the sensor is scaled up by 16. Also, the
linux hwmon framework expects the value to be in milli.
Signed-off-by: 's avatarVaibhav Gupta <vaibhav.gupta@cern.ch>
parent e391c471
......@@ -30,7 +30,7 @@ static int ft_hwmon_temp_read(struct device *dev, enum hwmon_sensor_types type,
if(ret < 0)
dev_err(dev, "Could not read temperature: %d", ret);
else
*val = (long)value;
*val = (long)value * 1000 / 16;
return 0;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment