Lines Matching +full:0 +full:xff000
10 #define SROT_CTRL_OFF 0x0000
13 #define TM_INT_EN_OFF 0x0000
14 #define TM_Sn_UPPER_LOWER_STATUS_CTRL_OFF 0x0004
15 #define TM_Sn_STATUS_OFF 0x0030
16 #define TM_TRDY_OFF 0x005c
19 #define MSM8916_BASE0_MASK 0x0000007f
20 #define MSM8916_BASE1_MASK 0xfe000000
21 #define MSM8916_BASE0_SHIFT 0
24 #define MSM8916_S0_P1_MASK 0x00000f80
25 #define MSM8916_S1_P1_MASK 0x003e0000
26 #define MSM8916_S2_P1_MASK 0xf8000000
27 #define MSM8916_S3_P1_MASK 0x000003e0
28 #define MSM8916_S4_P1_MASK 0x000f8000
30 #define MSM8916_S0_P2_MASK 0x0001f000
31 #define MSM8916_S1_P2_MASK 0x07c00000
32 #define MSM8916_S2_P2_MASK 0x0000001f
33 #define MSM8916_S3_P2_MASK 0x00007c00
34 #define MSM8916_S4_P2_MASK 0x01f00000
44 #define MSM8916_S2_P2_SHIFT 0
48 #define MSM8916_CAL_SEL_MASK 0xe0000000
52 #define MSM8939_BASE0_MASK 0x000000ff
53 #define MSM8939_BASE1_MASK 0xff000000
54 #define MSM8939_BASE0_SHIFT 0
57 #define MSM8939_S0_P1_MASK 0x000001f8
58 #define MSM8939_S1_P1_MASK 0x001f8000
59 #define MSM8939_S2_P1_MASK_0_4 0xf8000000
60 #define MSM8939_S2_P1_MASK_5 0x00000001
61 #define MSM8939_S3_P1_MASK 0x00001f80
62 #define MSM8939_S4_P1_MASK 0x01f80000
63 #define MSM8939_S5_P1_MASK 0x00003f00
64 #define MSM8939_S6_P1_MASK 0x03f00000
65 #define MSM8939_S7_P1_MASK 0x0000003f
66 #define MSM8939_S8_P1_MASK 0x0003f000
67 #define MSM8939_S9_P1_MASK 0x07e00000
69 #define MSM8939_S0_P2_MASK 0x00007e00
70 #define MSM8939_S1_P2_MASK 0x07e00000
71 #define MSM8939_S2_P2_MASK 0x0000007e
72 #define MSM8939_S3_P2_MASK 0x0007e000
73 #define MSM8939_S4_P2_MASK 0x7e000000
74 #define MSM8939_S5_P2_MASK 0x000fc000
75 #define MSM8939_S6_P2_MASK 0xfc000000
76 #define MSM8939_S7_P2_MASK 0x00000fc0
77 #define MSM8939_S8_P2_MASK 0x00fc0000
78 #define MSM8939_S9_P2_MASK_0_4 0xf8000000
79 #define MSM8939_S9_P2_MASK_5 0x00002000
84 #define MSM8939_S2_P1_SHIFT_5 0
89 #define MSM8939_S7_P1_SHIFT 0
105 #define MSM8939_CAL_SEL_MASK 0x7
106 #define MSM8939_CAL_SEL_SHIFT 0
109 #define BASE1_MASK 0xff
110 #define S0_P1_MASK 0x3f00
111 #define S1_P1_MASK 0xfc000
112 #define S2_P1_MASK 0x3f00000
113 #define S3_P1_MASK 0xfc000000
114 #define S4_P1_MASK 0x3f
115 #define S5_P1_MASK 0xfc0
116 #define S6_P1_MASK 0x3f000
117 #define S7_P1_MASK 0xfc0000
118 #define S8_P1_MASK 0x3f000000
119 #define S8_P1_MASK_BKP 0x3f
120 #define S9_P1_MASK 0x3f
121 #define S9_P1_MASK_BKP 0xfc0
122 #define S10_P1_MASK 0xfc0
123 #define S10_P1_MASK_BKP 0x3f000
124 #define CAL_SEL_0_1 0xc0000000
125 #define CAL_SEL_2 0x40000000
162 #define BASE2_MASK 0xff000
163 #define BASE2_BKP_MASK 0xfc0000
164 #define S0_P2_MASK 0x3f00000
165 #define S0_P2_BKP_MASK 0xfc000000
166 #define S1_P2_MASK 0xfc000000
167 #define S1_P2_BKP_MASK 0x3f
168 #define S2_P2_MASK 0x3f
169 #define S2_P2_BKP_MASK 0xfc0
170 #define S3_P2_MASK 0xfc0
171 #define S3_P2_BKP_MASK 0x3f000
172 #define S4_P2_MASK 0x3f000
173 #define S4_P2_BKP_MASK 0xfc0000
174 #define S5_P2_MASK 0xfc0000
175 #define S5_P2_BKP_MASK 0x3f000000
176 #define S6_P2_MASK 0x3f000000
177 #define S6_P2_BKP_MASK 0x3f
178 #define S7_P2_MASK 0x3f
179 #define S7_P2_BKP_MASK 0xfc0
180 #define S8_P2_MASK 0xfc0
181 #define S8_P2_BKP_MASK 0x3f000
182 #define S9_P2_MASK 0x3f000
183 #define S9_P2_BKP_MASK 0xfc0000
184 #define S10_P2_MASK 0xfc0000
185 #define S10_P2_BKP_MASK 0x3f000000
187 #define BKP_SEL 0x3
188 #define BKP_REDUN_SEL 0xe0000000
191 #define BIT_APPEND 0x3
195 int base0 = 0, base1 = 0, i; in calibrate_8916()
197 int mode = 0; in calibrate_8916()
210 mode = (qfprom_csel[0] & MSM8916_CAL_SEL_MASK) >> MSM8916_CAL_SEL_SHIFT; in calibrate_8916()
216 p2[0] = (qfprom_cdata[0] & MSM8916_S0_P2_MASK) >> MSM8916_S0_P2_SHIFT; in calibrate_8916()
217 p2[1] = (qfprom_cdata[0] & MSM8916_S1_P2_MASK) >> MSM8916_S1_P2_SHIFT; in calibrate_8916()
221 for (i = 0; i < priv->num_sensors; i++) in calibrate_8916()
225 base0 = (qfprom_cdata[0] & MSM8916_BASE0_MASK); in calibrate_8916()
226 p1[0] = (qfprom_cdata[0] & MSM8916_S0_P1_MASK) >> MSM8916_S0_P1_SHIFT; in calibrate_8916()
227 p1[1] = (qfprom_cdata[0] & MSM8916_S1_P1_MASK) >> MSM8916_S1_P1_SHIFT; in calibrate_8916()
228 p1[2] = (qfprom_cdata[0] & MSM8916_S2_P1_MASK) >> MSM8916_S2_P1_SHIFT; in calibrate_8916()
231 for (i = 0; i < priv->num_sensors; i++) in calibrate_8916()
235 for (i = 0; i < priv->num_sensors; i++) { in calibrate_8916()
246 return 0; in calibrate_8916()
251 int base0 = 0, base1 = 0, i; in calibrate_8939()
253 int mode = 0; in calibrate_8939()
262 cdata[0] = qfprom_cdata[12]; in calibrate_8939()
264 cdata[2] = qfprom_cdata[0]; in calibrate_8939()
269 mode = (cdata[0] & MSM8939_CAL_SEL_MASK) >> MSM8939_CAL_SEL_SHIFT; in calibrate_8939()
275 p2[0] = (cdata[0] & MSM8939_S0_P2_MASK) >> MSM8939_S0_P2_SHIFT; in calibrate_8939()
276 p2[1] = (cdata[0] & MSM8939_S1_P2_MASK) >> MSM8939_S1_P2_SHIFT; in calibrate_8939()
286 for (i = 0; i < priv->num_sensors; i++) in calibrate_8939()
291 p1[0] = (cdata[0] & MSM8939_S0_P1_MASK) >> MSM8939_S0_P1_SHIFT; in calibrate_8939()
292 p1[1] = (cdata[0] & MSM8939_S1_P1_MASK) >> MSM8939_S1_P1_SHIFT; in calibrate_8939()
293 p1[2] = (cdata[0] & MSM8939_S2_P1_MASK_0_4) >> MSM8939_S2_P1_SHIFT_0_4; in calibrate_8939()
302 for (i = 0; i < priv->num_sensors; i++) in calibrate_8939()
306 for (i = 0; i < priv->num_sensors; i++) { in calibrate_8939()
316 return 0; in calibrate_8939()
321 int base1 = 0, base2 = 0, i; in calibrate_8974()
323 int mode = 0; in calibrate_8974()
347 p2[0] = (bkp[2] & S0_P2_BKP_MASK) >> S0_P2_BKP_SHIFT; in calibrate_8974()
361 base1 = bkp[0] & BASE1_MASK; in calibrate_8974()
362 p1[0] = (bkp[0] & S0_P1_MASK) >> S0_P1_SHIFT; in calibrate_8974()
363 p1[1] = (bkp[0] & S1_P1_MASK) >> S1_P1_SHIFT; in calibrate_8974()
364 p1[2] = (bkp[0] & S2_P1_MASK) >> S2_P1_SHIFT; in calibrate_8974()
365 p1[3] = (bkp[0] & S3_P1_MASK) >> S3_P1_SHIFT; in calibrate_8974()
382 p2[0] = (calib[2] & S0_P2_MASK) >> S0_P2_SHIFT; in calibrate_8974()
396 base1 = calib[0] & BASE1_MASK; in calibrate_8974()
397 p1[0] = (calib[0] & S0_P1_MASK) >> S0_P1_SHIFT; in calibrate_8974()
398 p1[1] = (calib[0] & S1_P1_MASK) >> S1_P1_SHIFT; in calibrate_8974()
399 p1[2] = (calib[0] & S2_P1_MASK) >> S2_P1_SHIFT; in calibrate_8974()
400 p1[3] = (calib[0] & S3_P1_MASK) >> S3_P1_SHIFT; in calibrate_8974()
414 for (i = 0; i < priv->num_sensors; i++) in calibrate_8974()
418 for (i = 0; i < priv->num_sensors; i++) { in calibrate_8974()
425 for (i = 0; i < priv->num_sensors; i++) { in calibrate_8974()
432 for (i = 0; i < priv->num_sensors; i++) in calibrate_8974()
434 p1[0] = 502; in calibrate_8974()
452 return 0; in calibrate_8974()
459 .crit_int = 0,
470 [TSENS_EN] = REG_FIELD(SROT_CTRL_OFF, 0, 0),
475 [INT_EN] = REG_FIELD(TM_INT_EN_OFF, 0, 0),
478 REG_FIELD_FOR_EACH_SENSOR11(LOW_THRESH, TM_Sn_UPPER_LOWER_STATUS_CTRL_OFF, 0, 9),
488 REG_FIELD_FOR_EACH_SENSOR11(LAST_TEMP, TM_Sn_STATUS_OFF, 0, 9),
497 /* TRDY: 1=ready, 0=in progress */
498 [TRDY] = REG_FIELD(TM_TRDY_OFF, 0, 0),
510 .hw_ids = (unsigned int []){0, 1, 2, 4, 5 },
525 .hw_ids = (unsigned int []){ 0, 1, 2, 4, 5, 6, 7, 8, 9, 10 },