thermal: tsens: Pass register offsets as private data
authorAmit Kucheria <amit.kucheria@linaro.org>
Wed, 12 Sep 2018 09:52:52 +0000 (15:22 +0530)
committerEduardo Valentin <edubezval@gmail.com>
Tue, 23 Oct 2018 00:34:33 +0000 (17:34 -0700)
commitc130a7602e3bc2c6fd896c1d56478fca47a38c02
tree32acd533a49ed8af9cbcbb9903a917c1a10e6fb2
parenta15525b5d9ac37fec559d140b2e24c4ce4defa54
thermal: tsens: Pass register offsets as private data

Registers have moved around across TSENS generations. For example, the
CTRL register was at offset 0x0 in the SROT region on msm8916 but is at
offset 0x4 in newer v2 based TSENS HW blocks.

Allow passing offsets of important registers so that we can continue to
use common functions.

Signed-off-by: Amit Kucheria <amit.kucheria@linaro.org>
Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Signed-off-by: Eduardo Valentin <edubezval@gmail.com>
drivers/thermal/qcom/tsens-8916.c
drivers/thermal/qcom/tsens-8974.c
drivers/thermal/qcom/tsens-v2.c
drivers/thermal/qcom/tsens.c
drivers/thermal/qcom/tsens.h