diff options
author | Chanwoo Choi <cw00.choi@samsung.com> | 2013-02-12 06:44:19 -0500 |
---|---|---|
committer | Chanwoo Choi <cw00.choi@samsung.com> | 2013-02-13 17:53:42 -0500 |
commit | e3e5bc02d2365d3e09164fd9a559011399ca2a4f (patch) | |
tree | 491a0532982f0731d8de14c9599817e68c5bc479 /include/linux/mfd/max8997-private.h | |
parent | 45d4a4e6f5e5dcdd00b7c9d370cfb9694358e4e9 (diff) |
extcon: max8997: Move defined constant to header file
This patch move defined constants to header file(max77693-private.h)
because of mask/unmask selectively interrupt of MUIC device according
to attribute of H/W board.
Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
Signed-off-by: Myungjoo Ham <myungjoo.ham@samsung.com>
Diffstat (limited to 'include/linux/mfd/max8997-private.h')
-rw-r--r-- | include/linux/mfd/max8997-private.h | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/include/linux/mfd/max8997-private.h b/include/linux/mfd/max8997-private.h index 6ae21bf47d64..acf42e960320 100644 --- a/include/linux/mfd/max8997-private.h +++ b/include/linux/mfd/max8997-private.h | |||
@@ -194,6 +194,55 @@ enum max8997_muic_reg { | |||
194 | MAX8997_MUIC_REG_END = 0xf, | 194 | MAX8997_MUIC_REG_END = 0xf, |
195 | }; | 195 | }; |
196 | 196 | ||
197 | /* MAX8997-MUIC STATUS1 register */ | ||
198 | #define STATUS1_ADC_SHIFT 0 | ||
199 | #define STATUS1_ADCLOW_SHIFT 5 | ||
200 | #define STATUS1_ADCERR_SHIFT 6 | ||
201 | #define STATUS1_ADC_MASK (0x1f << STATUS1_ADC_SHIFT) | ||
202 | #define STATUS1_ADCLOW_MASK (0x1 << STATUS1_ADCLOW_SHIFT) | ||
203 | #define STATUS1_ADCERR_MASK (0x1 << STATUS1_ADCERR_SHIFT) | ||
204 | |||
205 | /* MAX8997-MUIC STATUS2 register */ | ||
206 | #define STATUS2_CHGTYP_SHIFT 0 | ||
207 | #define STATUS2_CHGDETRUN_SHIFT 3 | ||
208 | #define STATUS2_DCDTMR_SHIFT 4 | ||
209 | #define STATUS2_DBCHG_SHIFT 5 | ||
210 | #define STATUS2_VBVOLT_SHIFT 6 | ||
211 | #define STATUS2_CHGTYP_MASK (0x7 << STATUS2_CHGTYP_SHIFT) | ||
212 | #define STATUS2_CHGDETRUN_MASK (0x1 << STATUS2_CHGDETRUN_SHIFT) | ||
213 | #define STATUS2_DCDTMR_MASK (0x1 << STATUS2_DCDTMR_SHIFT) | ||
214 | #define STATUS2_DBCHG_MASK (0x1 << STATUS2_DBCHG_SHIFT) | ||
215 | #define STATUS2_VBVOLT_MASK (0x1 << STATUS2_VBVOLT_SHIFT) | ||
216 | |||
217 | /* MAX8997-MUIC STATUS3 register */ | ||
218 | #define STATUS3_OVP_SHIFT 2 | ||
219 | #define STATUS3_OVP_MASK (0x1 << STATUS3_OVP_SHIFT) | ||
220 | |||
221 | /* MAX8997-MUIC CONTROL1 register */ | ||
222 | #define COMN1SW_SHIFT 0 | ||
223 | #define COMP2SW_SHIFT 3 | ||
224 | #define COMN1SW_MASK (0x7 << COMN1SW_SHIFT) | ||
225 | #define COMP2SW_MASK (0x7 << COMP2SW_SHIFT) | ||
226 | #define CONTROL1_SW_MASK (COMP2SW_MASK | COMN1SW_MASK) | ||
227 | |||
228 | #define CONTROL1_SW_USB ((1 << COMP2SW_SHIFT) \ | ||
229 | | (1 << COMN1SW_SHIFT)) | ||
230 | #define CONTROL1_SW_AUDIO ((2 << COMP2SW_SHIFT) \ | ||
231 | | (2 << COMN1SW_SHIFT)) | ||
232 | #define CONTROL1_SW_UART ((3 << COMP2SW_SHIFT) \ | ||
233 | | (3 << COMN1SW_SHIFT)) | ||
234 | #define CONTROL1_SW_OPEN ((0 << COMP2SW_SHIFT) \ | ||
235 | | (0 << COMN1SW_SHIFT)) | ||
236 | |||
237 | #define MAX8997_ADC_GROUND 0x00 | ||
238 | #define MAX8997_ADC_MHL 0x01 | ||
239 | #define MAX8997_ADC_JIG_USB_1 0x18 | ||
240 | #define MAX8997_ADC_JIG_USB_2 0x19 | ||
241 | #define MAX8997_ADC_DESKDOCK 0x1a | ||
242 | #define MAX8997_ADC_JIG_UART 0x1c | ||
243 | #define MAX8997_ADC_CARDOCK 0x1d | ||
244 | #define MAX8997_ADC_OPEN 0x1f | ||
245 | |||
197 | enum max8997_haptic_reg { | 246 | enum max8997_haptic_reg { |
198 | MAX8997_HAPTIC_REG_GENERAL = 0x00, | 247 | MAX8997_HAPTIC_REG_GENERAL = 0x00, |
199 | MAX8997_HAPTIC_REG_CONF1 = 0x01, | 248 | MAX8997_HAPTIC_REG_CONF1 = 0x01, |