aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mfd/wm5110-tables.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/mfd/wm5110-tables.c')
-rw-r--r--drivers/mfd/wm5110-tables.c47
1 files changed, 43 insertions, 4 deletions
diff --git a/drivers/mfd/wm5110-tables.c b/drivers/mfd/wm5110-tables.c
index 3113e39b318e..bf8b3b5ad1fe 100644
--- a/drivers/mfd/wm5110-tables.c
+++ b/drivers/mfd/wm5110-tables.c
@@ -243,6 +243,12 @@ int wm5110_patch(struct arizona *arizona)
243EXPORT_SYMBOL_GPL(wm5110_patch); 243EXPORT_SYMBOL_GPL(wm5110_patch);
244 244
245static const struct regmap_irq wm5110_aod_irqs[ARIZONA_NUM_IRQ] = { 245static const struct regmap_irq wm5110_aod_irqs[ARIZONA_NUM_IRQ] = {
246 [ARIZONA_IRQ_MICD_CLAMP_FALL] = {
247 .mask = ARIZONA_MICD_CLAMP_FALL_EINT1
248 },
249 [ARIZONA_IRQ_MICD_CLAMP_RISE] = {
250 .mask = ARIZONA_MICD_CLAMP_RISE_EINT1
251 },
246 [ARIZONA_IRQ_GP5_FALL] = { .mask = ARIZONA_GP5_FALL_EINT1 }, 252 [ARIZONA_IRQ_GP5_FALL] = { .mask = ARIZONA_GP5_FALL_EINT1 },
247 [ARIZONA_IRQ_GP5_RISE] = { .mask = ARIZONA_GP5_RISE_EINT1 }, 253 [ARIZONA_IRQ_GP5_RISE] = { .mask = ARIZONA_GP5_RISE_EINT1 },
248 [ARIZONA_IRQ_JD_FALL] = { .mask = ARIZONA_JD1_FALL_EINT1 }, 254 [ARIZONA_IRQ_JD_FALL] = { .mask = ARIZONA_JD1_FALL_EINT1 },
@@ -505,6 +511,7 @@ static const struct reg_default wm5110_reg_default[] = {
505 { 0x00000293, 0x0000 }, /* R659 - Accessory Detect Mode 1 */ 511 { 0x00000293, 0x0000 }, /* R659 - Accessory Detect Mode 1 */
506 { 0x0000029B, 0x0020 }, /* R667 - Headphone Detect 1 */ 512 { 0x0000029B, 0x0020 }, /* R667 - Headphone Detect 1 */
507 { 0x0000029C, 0x0000 }, /* R668 - Headphone Detect 2 */ 513 { 0x0000029C, 0x0000 }, /* R668 - Headphone Detect 2 */
514 { 0x000002A2, 0x0000 }, /* R674 - Micd clamp control */
508 { 0x000002A3, 0x1102 }, /* R675 - Mic Detect 1 */ 515 { 0x000002A3, 0x1102 }, /* R675 - Mic Detect 1 */
509 { 0x000002A4, 0x009F }, /* R676 - Mic Detect 2 */ 516 { 0x000002A4, 0x009F }, /* R676 - Mic Detect 2 */
510 { 0x000002A5, 0x0000 }, /* R677 - Mic Detect 3 */ 517 { 0x000002A5, 0x0000 }, /* R677 - Mic Detect 3 */
@@ -592,7 +599,7 @@ static const struct reg_default wm5110_reg_default[] = {
592 { 0x0000043E, 0x0080 }, /* R1086 - DAC Volume Limit 6R */ 599 { 0x0000043E, 0x0080 }, /* R1086 - DAC Volume Limit 6R */
593 { 0x0000043F, 0x0800 }, /* R1087 - Noise Gate Select 6R */ 600 { 0x0000043F, 0x0800 }, /* R1087 - Noise Gate Select 6R */
594 { 0x00000450, 0x0000 }, /* R1104 - DAC AEC Control 1 */ 601 { 0x00000450, 0x0000 }, /* R1104 - DAC AEC Control 1 */
595 { 0x00000458, 0x0001 }, /* R1112 - Noise Gate Control */ 602 { 0x00000458, 0x0000 }, /* R1112 - Noise Gate Control */
596 { 0x00000480, 0x0040 }, /* R1152 - Class W ANC Threshold 1 */ 603 { 0x00000480, 0x0040 }, /* R1152 - Class W ANC Threshold 1 */
597 { 0x00000481, 0x0040 }, /* R1153 - Class W ANC Threshold 2 */ 604 { 0x00000481, 0x0040 }, /* R1153 - Class W ANC Threshold 2 */
598 { 0x00000490, 0x0069 }, /* R1168 - PDM SPK1 CTRL 1 */ 605 { 0x00000490, 0x0069 }, /* R1168 - PDM SPK1 CTRL 1 */
@@ -1204,7 +1211,6 @@ static const struct reg_default wm5110_reg_default[] = {
1204 { 0x00000D1B, 0xFFFF }, /* R3355 - IRQ2 Status 4 Mask */ 1211 { 0x00000D1B, 0xFFFF }, /* R3355 - IRQ2 Status 4 Mask */
1205 { 0x00000D1C, 0xFFFF }, /* R3356 - IRQ2 Status 5 Mask */ 1212 { 0x00000D1C, 0xFFFF }, /* R3356 - IRQ2 Status 5 Mask */
1206 { 0x00000D1F, 0x0000 }, /* R3359 - IRQ2 Control */ 1213 { 0x00000D1F, 0x0000 }, /* R3359 - IRQ2 Control */
1207 { 0x00000D50, 0x0000 }, /* R3408 - AOD wkup and trig */
1208 { 0x00000D53, 0xFFFF }, /* R3411 - AOD IRQ Mask IRQ1 */ 1214 { 0x00000D53, 0xFFFF }, /* R3411 - AOD IRQ Mask IRQ1 */
1209 { 0x00000D54, 0xFFFF }, /* R3412 - AOD IRQ Mask IRQ2 */ 1215 { 0x00000D54, 0xFFFF }, /* R3412 - AOD IRQ Mask IRQ2 */
1210 { 0x00000D56, 0x0000 }, /* R3414 - Jack detect debounce */ 1216 { 0x00000D56, 0x0000 }, /* R3414 - Jack detect debounce */
@@ -1440,6 +1446,7 @@ static bool wm5110_readable_register(struct device *dev, unsigned int reg)
1440 case ARIZONA_ACCESSORY_DETECT_MODE_1: 1446 case ARIZONA_ACCESSORY_DETECT_MODE_1:
1441 case ARIZONA_HEADPHONE_DETECT_1: 1447 case ARIZONA_HEADPHONE_DETECT_1:
1442 case ARIZONA_HEADPHONE_DETECT_2: 1448 case ARIZONA_HEADPHONE_DETECT_2:
1449 case ARIZONA_MICD_CLAMP_CONTROL:
1443 case ARIZONA_MIC_DETECT_1: 1450 case ARIZONA_MIC_DETECT_1:
1444 case ARIZONA_MIC_DETECT_2: 1451 case ARIZONA_MIC_DETECT_2:
1445 case ARIZONA_MIC_DETECT_3: 1452 case ARIZONA_MIC_DETECT_3:
@@ -2291,21 +2298,37 @@ static bool wm5110_readable_register(struct device *dev, unsigned int reg)
2291 case ARIZONA_DSP1_STATUS_1: 2298 case ARIZONA_DSP1_STATUS_1:
2292 case ARIZONA_DSP1_STATUS_2: 2299 case ARIZONA_DSP1_STATUS_2:
2293 case ARIZONA_DSP1_STATUS_3: 2300 case ARIZONA_DSP1_STATUS_3:
2301 case ARIZONA_DSP1_SCRATCH_0:
2302 case ARIZONA_DSP1_SCRATCH_1:
2303 case ARIZONA_DSP1_SCRATCH_2:
2304 case ARIZONA_DSP1_SCRATCH_3:
2294 case ARIZONA_DSP2_CONTROL_1: 2305 case ARIZONA_DSP2_CONTROL_1:
2295 case ARIZONA_DSP2_CLOCKING_1: 2306 case ARIZONA_DSP2_CLOCKING_1:
2296 case ARIZONA_DSP2_STATUS_1: 2307 case ARIZONA_DSP2_STATUS_1:
2297 case ARIZONA_DSP2_STATUS_2: 2308 case ARIZONA_DSP2_STATUS_2:
2298 case ARIZONA_DSP2_STATUS_3: 2309 case ARIZONA_DSP2_STATUS_3:
2310 case ARIZONA_DSP2_SCRATCH_0:
2311 case ARIZONA_DSP2_SCRATCH_1:
2312 case ARIZONA_DSP2_SCRATCH_2:
2313 case ARIZONA_DSP2_SCRATCH_3:
2299 case ARIZONA_DSP3_CONTROL_1: 2314 case ARIZONA_DSP3_CONTROL_1:
2300 case ARIZONA_DSP3_CLOCKING_1: 2315 case ARIZONA_DSP3_CLOCKING_1:
2301 case ARIZONA_DSP3_STATUS_1: 2316 case ARIZONA_DSP3_STATUS_1:
2302 case ARIZONA_DSP3_STATUS_2: 2317 case ARIZONA_DSP3_STATUS_2:
2303 case ARIZONA_DSP3_STATUS_3: 2318 case ARIZONA_DSP3_STATUS_3:
2319 case ARIZONA_DSP3_SCRATCH_0:
2320 case ARIZONA_DSP3_SCRATCH_1:
2321 case ARIZONA_DSP3_SCRATCH_2:
2322 case ARIZONA_DSP3_SCRATCH_3:
2304 case ARIZONA_DSP4_CONTROL_1: 2323 case ARIZONA_DSP4_CONTROL_1:
2305 case ARIZONA_DSP4_CLOCKING_1: 2324 case ARIZONA_DSP4_CLOCKING_1:
2306 case ARIZONA_DSP4_STATUS_1: 2325 case ARIZONA_DSP4_STATUS_1:
2307 case ARIZONA_DSP4_STATUS_2: 2326 case ARIZONA_DSP4_STATUS_2:
2308 case ARIZONA_DSP4_STATUS_3: 2327 case ARIZONA_DSP4_STATUS_3:
2328 case ARIZONA_DSP4_SCRATCH_0:
2329 case ARIZONA_DSP4_SCRATCH_1:
2330 case ARIZONA_DSP4_SCRATCH_2:
2331 case ARIZONA_DSP4_SCRATCH_3:
2309 return true; 2332 return true;
2310 default: 2333 default:
2311 return false; 2334 return false;
@@ -2347,25 +2370,41 @@ static bool wm5110_volatile_register(struct device *dev, unsigned int reg)
2347 case ARIZONA_INTERRUPT_RAW_STATUS_7: 2370 case ARIZONA_INTERRUPT_RAW_STATUS_7:
2348 case ARIZONA_INTERRUPT_RAW_STATUS_8: 2371 case ARIZONA_INTERRUPT_RAW_STATUS_8:
2349 case ARIZONA_IRQ_PIN_STATUS: 2372 case ARIZONA_IRQ_PIN_STATUS:
2373 case ARIZONA_AOD_WKUP_AND_TRIG:
2350 case ARIZONA_AOD_IRQ1: 2374 case ARIZONA_AOD_IRQ1:
2351 case ARIZONA_AOD_IRQ2: 2375 case ARIZONA_AOD_IRQ2:
2376 case ARIZONA_AOD_IRQ_RAW_STATUS:
2352 case ARIZONA_FX_CTRL2: 2377 case ARIZONA_FX_CTRL2:
2353 case ARIZONA_ASRC_STATUS: 2378 case ARIZONA_ASRC_STATUS:
2354 case ARIZONA_DSP_STATUS: 2379 case ARIZONA_DSP_STATUS:
2355 case ARIZONA_DSP1_CONTROL_1:
2356 case ARIZONA_DSP1_CLOCKING_1:
2357 case ARIZONA_DSP1_STATUS_1: 2380 case ARIZONA_DSP1_STATUS_1:
2358 case ARIZONA_DSP1_STATUS_2: 2381 case ARIZONA_DSP1_STATUS_2:
2359 case ARIZONA_DSP1_STATUS_3: 2382 case ARIZONA_DSP1_STATUS_3:
2383 case ARIZONA_DSP1_SCRATCH_0:
2384 case ARIZONA_DSP1_SCRATCH_1:
2385 case ARIZONA_DSP1_SCRATCH_2:
2386 case ARIZONA_DSP1_SCRATCH_3:
2360 case ARIZONA_DSP2_STATUS_1: 2387 case ARIZONA_DSP2_STATUS_1:
2361 case ARIZONA_DSP2_STATUS_2: 2388 case ARIZONA_DSP2_STATUS_2:
2362 case ARIZONA_DSP2_STATUS_3: 2389 case ARIZONA_DSP2_STATUS_3:
2390 case ARIZONA_DSP2_SCRATCH_0:
2391 case ARIZONA_DSP2_SCRATCH_1:
2392 case ARIZONA_DSP2_SCRATCH_2:
2393 case ARIZONA_DSP2_SCRATCH_3:
2363 case ARIZONA_DSP3_STATUS_1: 2394 case ARIZONA_DSP3_STATUS_1:
2364 case ARIZONA_DSP3_STATUS_2: 2395 case ARIZONA_DSP3_STATUS_2:
2365 case ARIZONA_DSP3_STATUS_3: 2396 case ARIZONA_DSP3_STATUS_3:
2397 case ARIZONA_DSP3_SCRATCH_0:
2398 case ARIZONA_DSP3_SCRATCH_1:
2399 case ARIZONA_DSP3_SCRATCH_2:
2400 case ARIZONA_DSP3_SCRATCH_3:
2366 case ARIZONA_DSP4_STATUS_1: 2401 case ARIZONA_DSP4_STATUS_1:
2367 case ARIZONA_DSP4_STATUS_2: 2402 case ARIZONA_DSP4_STATUS_2:
2368 case ARIZONA_DSP4_STATUS_3: 2403 case ARIZONA_DSP4_STATUS_3:
2404 case ARIZONA_DSP4_SCRATCH_0:
2405 case ARIZONA_DSP4_SCRATCH_1:
2406 case ARIZONA_DSP4_SCRATCH_2:
2407 case ARIZONA_DSP4_SCRATCH_3:
2369 return true; 2408 return true;
2370 default: 2409 default:
2371 return false; 2410 return false;