diff options
| author | Ji-Ze Hong (Peter Hong) <[email protected]> | 2022-04-18 09:07:06 +0000 |
|---|---|---|
| committer | Guenter Roeck <[email protected]> | 2022-04-18 15:15:07 +0000 |
| commit | 4aaaaf0f279836f06d3b9d0ffeec7a1e1a04ceef (patch) | |
| tree | 09d662d70e6e40143b0d6f8eed98c1b54185fb6c /tools/perf/scripts/python/sched-migration.py | |
| parent | dt-bindings: hwmon: ti,tmp421: Fix type for 'ti,n-factor' (diff) | |
| download | kernel-4aaaaf0f279836f06d3b9d0ffeec7a1e1a04ceef.tar.gz kernel-4aaaaf0f279836f06d3b9d0ffeec7a1e1a04ceef.zip | |
hwmon: (f71882fg) Fix negative temperature
All temperature of Fintek superio hwmonitor that using 1-byte reg will use
2's complement.
In show_temp()
temp = data->temp[nr] * 1000;
When data->temp[nr] read as 255, it indicate -1C, but this code will report
255C to userspace. It'll be ok when change to:
temp = ((s8)data->temp[nr]) * 1000;
Signed-off-by: Ji-Ze Hong (Peter Hong) <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Guenter Roeck <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/sched-migration.py')
0 files changed, 0 insertions, 0 deletions
