Commit dfc9dc29 authored by Derek Nguyen's avatar Derek Nguyen Committed by sanglipeng
Browse files

hwmon: (ltc2947) fix temperature scaling

stable inclusion
from stable-v5.10.158
commit 984fcd3ec1aafe3cb5a50b3ca2f9b7c97fdc4e1e
category: bugfix
bugzilla: https://gitee.com/openeuler/kernel/issues/I7NTXH

Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=984fcd3ec1aafe3cb5a50b3ca2f9b7c97fdc4e1e



--------------------------------

[ Upstream commit 07e06193 ]

The LTC2947 datasheet (Rev. B) calls out in the section "Register
Description: Non-Accumulated Result Registers" (pg. 30) that "To
calculate temperature, multiply the TEMP register value by 0.204°C
and add 5.5°C". Fix to add 5.5C and not 0.55C.

Fixes: 9f90fd65 ("hwmon: Add support for ltc2947")
Signed-off-by: default avatarDerek Nguyen <derek.nguyen@collins.com>
Signed-off-by: default avatarBrandon Maier <brandon.maier@collins.com>
Link: https://lore.kernel.org/r/20221110192108.20624-1-brandon.maier@collins.com


Signed-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
Signed-off-by: default avatarsanglipeng <sanglipeng1@jd.com>
parent b3981aeb
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment