summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNathan Chancellor <natechancellor@gmail.com>2019-09-26 23:39:10 -0700
committerDavide Garberi <dade.garberi@gmail.com>2021-10-07 20:13:49 +0200
commitccabaecbbeb04a1c2b7775e0043e2df195167a98 (patch)
treebc05de12869039c6ad232b7e1c86fb2831e29479
parent8d97822e58b85e32c14ae4130fc524e4e31d4a68 (diff)
thermal: tsens: Avoid implicit enum conversions in th_state fieldslineage-18.1
Clang warns: ../drivers/thermal/msm-tsens.c:998:41: warning: implicit conversion from enumeration type 'enum thermal_trip_activation_mode' to different enumeration type 'enum thermal_device_mode' [-Wenum-conversion] debug_thr_state_copy.crit_th_state = mode; ~ ^~~~ ../drivers/thermal/msm-tsens.c:1012:41: warning: implicit conversion from enumeration type 'enum thermal_trip_activation_mode' to different enumeration type 'enum thermal_device_mode' [-Wenum-conversion] debug_thr_state_copy.high_th_state = mode; ~ ^~~~ ../drivers/thermal/msm-tsens.c:1028:40: warning: implicit conversion from enumeration type 'enum thermal_trip_activation_mode' to different enumeration type 'enum thermal_device_mode' [-Wenum-conversion] debug_thr_state_copy.low_th_state = mode; ~ ^~~~ ../drivers/thermal/msm-tsens.c:1074:42: warning: implicit conversion from enumeration type 'enum thermal_trip_activation_mode' to different enumeration type 'enum thermal_device_mode' [-Wenum-conversion] debug_thr_state_copy.high_th_state = mode; ~ ^~~~ ../drivers/thermal/msm-tsens.c:1085:41: warning: implicit conversion from enumeration type 'enum thermal_trip_activation_mode' to different enumeration type 'enum thermal_device_mode' [-Wenum-conversion] debug_thr_state_copy.low_th_state = mode; ~ ^~~~ 5 warnings generated. Fixes: 2021d15137a3 ("thermal: tsens: Enable TSENS") Signed-off-by: Nathan Chancellor <natechancellor@gmail.com> Change-Id: Ib06c8a57d7227da64684c4fa21ac2b9828034e28
-rw-r--r--drivers/thermal/msm-tsens.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/thermal/msm-tsens.c b/drivers/thermal/msm-tsens.c
index a9358a807769..44c744272244 100644
--- a/drivers/thermal/msm-tsens.c
+++ b/drivers/thermal/msm-tsens.c
@@ -199,9 +199,9 @@ enum tsens_tm_trip_type {
#define TSENS_TM_WRITABLE_TRIPS_MASK ((1 << TSENS_TM_TRIP_NUM) - 1)
struct tsens_thrshld_state {
- enum thermal_trip_activation_mode high_th_state;
- enum thermal_trip_activation_mode low_th_state;
- enum thermal_trip_activation_mode crit_th_state;
+ int high_th_state;
+ int low_th_state;
+ int crit_th_state;
unsigned int high_adc_code;
unsigned int low_adc_code;
int high_temp;