]> www.infradead.org Git - users/jedix/linux-maple.git/commit
thermal/drivers/tsens: Don't hardcode sensor slope
authorAnsuel Smith <ansuelsmth@gmail.com>
Sun, 4 Apr 2021 14:48:16 +0000 (16:48 +0200)
committerDaniel Lezcano <daniel.lezcano@linaro.org>
Mon, 5 Apr 2021 22:52:48 +0000 (00:52 +0200)
commitca5378665498b8494755876d22ce3fe840e5d0c1
tree083890799d5433f0a7bd4bb66fb405542e28bba0
parenta97f64ea596c31f64e9ced80b6b406ef4b19b874
thermal/drivers/tsens: Don't hardcode sensor slope

Function compute_intercept_slope hardcode the sensor slope to
SLOPE_DEFAULT. Change this and use the default value only if a slope is
not defined. This is needed for tsens VER_0 that has a hardcoded slope
table.

Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
Reviewed-by: Thara Gopinath <thara.gopinath@linaro.org>
Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
Link: https://lore.kernel.org/r/20210404144823.31867-3-ansuelsmth@gmail.com
drivers/thermal/qcom/tsens.c