OSDN Git Service

drivers: thermal: tsens: Move calibration constants to header file
authorAmit Kucheria <amit.kucheria@linaro.org>
Wed, 20 Mar 2019 13:18:03 +0000 (18:48 +0530)
committerEduardo Valentin <edubezval@gmail.com>
Tue, 14 May 2019 14:00:23 +0000 (07:00 -0700)
This will allow calibration routines to correctly include the constants
from anywhere and allow more code sharing.

Signed-off-by: Amit Kucheria <amit.kucheria@linaro.org>
Signed-off-by: Eduardo Valentin <edubezval@gmail.com>
drivers/thermal/qcom/tsens-common.c
drivers/thermal/qcom/tsens.h

index 92747cc..928e8e8 100644 (file)
 #include <linux/regmap.h>
 #include "tsens.h"
 
-#define CAL_DEGC_PT1           30
-#define CAL_DEGC_PT2           120
-#define SLOPE_FACTOR           1000
-#define SLOPE_DEFAULT          3200
-
 char *qfprom_read(struct device *dev, const char *cname)
 {
        struct nvmem_cell *cell;
index d648fba..eefe384 100644 (file)
@@ -9,6 +9,11 @@
 #define ONE_PT_CALIB           0x1
 #define ONE_PT_CALIB2          0x2
 #define TWO_PT_CALIB           0x3
+#define CAL_DEGC_PT1           30
+#define CAL_DEGC_PT2           120
+#define SLOPE_FACTOR           1000
+#define SLOPE_DEFAULT          3200
+
 
 #include <linux/thermal.h>
 #include <linux/regmap.h>