diff options
author | Linus Walleij <linus.walleij@linaro.org> | 2011-06-09 17:57:45 -0400 |
---|---|---|
committer | Samuel Ortiz <sameo@linux.intel.com> | 2011-07-31 17:28:23 -0400 |
commit | 6af75ecd5772eee4d7be974a881fd5a25f218b0b (patch) | |
tree | 327b4250438b1090d10a416a7ce180ddeb2fa3d5 /drivers/mfd | |
parent | 5cef8df5e335a5bc9147c5cafdce348981f5c5b5 (diff) |
mfd: Update ab8500 subdevice list
This synchronize the subdevice entries for the AB8500 MFD driver
with the latest development of subdrivers for things like battery
charging and temperature monitoring.
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Diffstat (limited to 'drivers/mfd')
-rw-r--r-- | drivers/mfd/ab8500-core.c | 215 |
1 files changed, 166 insertions, 49 deletions
diff --git a/drivers/mfd/ab8500-core.c b/drivers/mfd/ab8500-core.c index 1fc6be8cb850..387705e494b9 100644 --- a/drivers/mfd/ab8500-core.c +++ b/drivers/mfd/ab8500-core.c | |||
@@ -417,20 +417,47 @@ static struct resource __devinitdata ab8500_poweronkey_db_resources[] = { | |||
417 | }, | 417 | }, |
418 | }; | 418 | }; |
419 | 419 | ||
420 | static struct resource __devinitdata ab8500_bm_resources[] = { | 420 | static struct resource __devinitdata ab8500_av_acc_detect_resources[] = { |
421 | { | 421 | { |
422 | .name = "MAIN_EXT_CH_NOT_OK", | 422 | .name = "ACC_DETECT_1DB_F", |
423 | .start = AB8500_INT_MAIN_EXT_CH_NOT_OK, | 423 | .start = AB8500_INT_ACC_DETECT_1DB_F, |
424 | .end = AB8500_INT_MAIN_EXT_CH_NOT_OK, | 424 | .end = AB8500_INT_ACC_DETECT_1DB_F, |
425 | .flags = IORESOURCE_IRQ, | 425 | .flags = IORESOURCE_IRQ, |
426 | }, | 426 | }, |
427 | { | 427 | { |
428 | .name = "BATT_OVV", | 428 | .name = "ACC_DETECT_1DB_R", |
429 | .start = AB8500_INT_BATT_OVV, | 429 | .start = AB8500_INT_ACC_DETECT_1DB_R, |
430 | .end = AB8500_INT_BATT_OVV, | 430 | .end = AB8500_INT_ACC_DETECT_1DB_R, |
431 | .flags = IORESOURCE_IRQ, | 431 | .flags = IORESOURCE_IRQ, |
432 | }, | ||
433 | { | ||
434 | .name = "ACC_DETECT_21DB_F", | ||
435 | .start = AB8500_INT_ACC_DETECT_21DB_F, | ||
436 | .end = AB8500_INT_ACC_DETECT_21DB_F, | ||
437 | .flags = IORESOURCE_IRQ, | ||
438 | }, | ||
439 | { | ||
440 | .name = "ACC_DETECT_21DB_R", | ||
441 | .start = AB8500_INT_ACC_DETECT_21DB_R, | ||
442 | .end = AB8500_INT_ACC_DETECT_21DB_R, | ||
443 | .flags = IORESOURCE_IRQ, | ||
444 | }, | ||
445 | { | ||
446 | .name = "ACC_DETECT_22DB_F", | ||
447 | .start = AB8500_INT_ACC_DETECT_22DB_F, | ||
448 | .end = AB8500_INT_ACC_DETECT_22DB_F, | ||
449 | .flags = IORESOURCE_IRQ, | ||
432 | }, | 450 | }, |
433 | { | 451 | { |
452 | .name = "ACC_DETECT_22DB_R", | ||
453 | .start = AB8500_INT_ACC_DETECT_22DB_R, | ||
454 | .end = AB8500_INT_ACC_DETECT_22DB_R, | ||
455 | .flags = IORESOURCE_IRQ, | ||
456 | }, | ||
457 | }; | ||
458 | |||
459 | static struct resource __devinitdata ab8500_charger_resources[] = { | ||
460 | { | ||
434 | .name = "MAIN_CH_UNPLUG_DET", | 461 | .name = "MAIN_CH_UNPLUG_DET", |
435 | .start = AB8500_INT_MAIN_CH_UNPLUG_DET, | 462 | .start = AB8500_INT_MAIN_CH_UNPLUG_DET, |
436 | .end = AB8500_INT_MAIN_CH_UNPLUG_DET, | 463 | .end = AB8500_INT_MAIN_CH_UNPLUG_DET, |
@@ -443,27 +470,27 @@ static struct resource __devinitdata ab8500_bm_resources[] = { | |||
443 | .flags = IORESOURCE_IRQ, | 470 | .flags = IORESOURCE_IRQ, |
444 | }, | 471 | }, |
445 | { | 472 | { |
446 | .name = "VBUS_DET_F", | ||
447 | .start = AB8500_INT_VBUS_DET_F, | ||
448 | .end = AB8500_INT_VBUS_DET_F, | ||
449 | .flags = IORESOURCE_IRQ, | ||
450 | }, | ||
451 | { | ||
452 | .name = "VBUS_DET_R", | 473 | .name = "VBUS_DET_R", |
453 | .start = AB8500_INT_VBUS_DET_R, | 474 | .start = AB8500_INT_VBUS_DET_R, |
454 | .end = AB8500_INT_VBUS_DET_R, | 475 | .end = AB8500_INT_VBUS_DET_R, |
455 | .flags = IORESOURCE_IRQ, | 476 | .flags = IORESOURCE_IRQ, |
456 | }, | 477 | }, |
457 | { | 478 | { |
458 | .name = "BAT_CTRL_INDB", | 479 | .name = "VBUS_DET_F", |
459 | .start = AB8500_INT_BAT_CTRL_INDB, | 480 | .start = AB8500_INT_VBUS_DET_F, |
460 | .end = AB8500_INT_BAT_CTRL_INDB, | 481 | .end = AB8500_INT_VBUS_DET_F, |
461 | .flags = IORESOURCE_IRQ, | 482 | .flags = IORESOURCE_IRQ, |
462 | }, | 483 | }, |
463 | { | 484 | { |
464 | .name = "CH_WD_EXP", | 485 | .name = "USB_LINK_STATUS", |
465 | .start = AB8500_INT_CH_WD_EXP, | 486 | .start = AB8500_INT_USB_LINK_STATUS, |
466 | .end = AB8500_INT_CH_WD_EXP, | 487 | .end = AB8500_INT_USB_LINK_STATUS, |
488 | .flags = IORESOURCE_IRQ, | ||
489 | }, | ||
490 | { | ||
491 | .name = "USB_CHARGE_DET_DONE", | ||
492 | .start = AB8500_INT_USB_CHG_DET_DONE, | ||
493 | .end = AB8500_INT_USB_CHG_DET_DONE, | ||
467 | .flags = IORESOURCE_IRQ, | 494 | .flags = IORESOURCE_IRQ, |
468 | }, | 495 | }, |
469 | { | 496 | { |
@@ -473,21 +500,60 @@ static struct resource __devinitdata ab8500_bm_resources[] = { | |||
473 | .flags = IORESOURCE_IRQ, | 500 | .flags = IORESOURCE_IRQ, |
474 | }, | 501 | }, |
475 | { | 502 | { |
476 | .name = "NCONV_ACCU", | 503 | .name = "USB_CH_TH_PROT_R", |
477 | .start = AB8500_INT_CCN_CONV_ACC, | 504 | .start = AB8500_INT_USB_CH_TH_PROT_R, |
478 | .end = AB8500_INT_CCN_CONV_ACC, | 505 | .end = AB8500_INT_USB_CH_TH_PROT_R, |
479 | .flags = IORESOURCE_IRQ, | 506 | .flags = IORESOURCE_IRQ, |
480 | }, | 507 | }, |
481 | { | 508 | { |
482 | .name = "LOW_BAT_F", | 509 | .name = "USB_CH_TH_PROT_F", |
483 | .start = AB8500_INT_LOW_BAT_F, | 510 | .start = AB8500_INT_USB_CH_TH_PROT_F, |
484 | .end = AB8500_INT_LOW_BAT_F, | 511 | .end = AB8500_INT_USB_CH_TH_PROT_F, |
485 | .flags = IORESOURCE_IRQ, | 512 | .flags = IORESOURCE_IRQ, |
486 | }, | 513 | }, |
487 | { | 514 | { |
488 | .name = "LOW_BAT_R", | 515 | .name = "MAIN_EXT_CH_NOT_OK", |
489 | .start = AB8500_INT_LOW_BAT_R, | 516 | .start = AB8500_INT_MAIN_EXT_CH_NOT_OK, |
490 | .end = AB8500_INT_LOW_BAT_R, | 517 | .end = AB8500_INT_MAIN_EXT_CH_NOT_OK, |
518 | .flags = IORESOURCE_IRQ, | ||
519 | }, | ||
520 | { | ||
521 | .name = "MAIN_CH_TH_PROT_R", | ||
522 | .start = AB8500_INT_MAIN_CH_TH_PROT_R, | ||
523 | .end = AB8500_INT_MAIN_CH_TH_PROT_R, | ||
524 | .flags = IORESOURCE_IRQ, | ||
525 | }, | ||
526 | { | ||
527 | .name = "MAIN_CH_TH_PROT_F", | ||
528 | .start = AB8500_INT_MAIN_CH_TH_PROT_F, | ||
529 | .end = AB8500_INT_MAIN_CH_TH_PROT_F, | ||
530 | .flags = IORESOURCE_IRQ, | ||
531 | }, | ||
532 | { | ||
533 | .name = "USB_CHARGER_NOT_OKR", | ||
534 | .start = AB8500_INT_USB_CHARGER_NOT_OK, | ||
535 | .end = AB8500_INT_USB_CHARGER_NOT_OK, | ||
536 | .flags = IORESOURCE_IRQ, | ||
537 | }, | ||
538 | { | ||
539 | .name = "USB_CHARGER_NOT_OKF", | ||
540 | .start = AB8500_INT_USB_CHARGER_NOT_OKF, | ||
541 | .end = AB8500_INT_USB_CHARGER_NOT_OKF, | ||
542 | .flags = IORESOURCE_IRQ, | ||
543 | }, | ||
544 | { | ||
545 | .name = "CH_WD_EXP", | ||
546 | .start = AB8500_INT_CH_WD_EXP, | ||
547 | .end = AB8500_INT_CH_WD_EXP, | ||
548 | .flags = IORESOURCE_IRQ, | ||
549 | }, | ||
550 | }; | ||
551 | |||
552 | static struct resource __devinitdata ab8500_btemp_resources[] = { | ||
553 | { | ||
554 | .name = "BAT_CTRL_INDB", | ||
555 | .start = AB8500_INT_BAT_CTRL_INDB, | ||
556 | .end = AB8500_INT_BAT_CTRL_INDB, | ||
491 | .flags = IORESOURCE_IRQ, | 557 | .flags = IORESOURCE_IRQ, |
492 | }, | 558 | }, |
493 | { | 559 | { |
@@ -503,37 +569,54 @@ static struct resource __devinitdata ab8500_bm_resources[] = { | |||
503 | .flags = IORESOURCE_IRQ, | 569 | .flags = IORESOURCE_IRQ, |
504 | }, | 570 | }, |
505 | { | 571 | { |
506 | .name = "USB_CHARGER_NOT_OKR", | 572 | .name = "BTEMP_LOW_MEDIUM", |
507 | .start = AB8500_INT_USB_CHARGER_NOT_OK, | 573 | .start = AB8500_INT_BTEMP_LOW_MEDIUM, |
508 | .end = AB8500_INT_USB_CHARGER_NOT_OK, | 574 | .end = AB8500_INT_BTEMP_LOW_MEDIUM, |
509 | .flags = IORESOURCE_IRQ, | 575 | .flags = IORESOURCE_IRQ, |
510 | }, | 576 | }, |
511 | { | 577 | { |
512 | .name = "USB_CHARGE_DET_DONE", | 578 | .name = "BTEMP_MEDIUM_HIGH", |
513 | .start = AB8500_INT_USB_CHG_DET_DONE, | 579 | .start = AB8500_INT_BTEMP_MEDIUM_HIGH, |
514 | .end = AB8500_INT_USB_CHG_DET_DONE, | 580 | .end = AB8500_INT_BTEMP_MEDIUM_HIGH, |
515 | .flags = IORESOURCE_IRQ, | 581 | .flags = IORESOURCE_IRQ, |
516 | }, | 582 | }, |
583 | }; | ||
584 | |||
585 | static struct resource __devinitdata ab8500_fg_resources[] = { | ||
517 | { | 586 | { |
518 | .name = "USB_CH_TH_PROT_R", | 587 | .name = "NCONV_ACCU", |
519 | .start = AB8500_INT_USB_CH_TH_PROT_R, | 588 | .start = AB8500_INT_CCN_CONV_ACC, |
520 | .end = AB8500_INT_USB_CH_TH_PROT_R, | 589 | .end = AB8500_INT_CCN_CONV_ACC, |
521 | .flags = IORESOURCE_IRQ, | 590 | .flags = IORESOURCE_IRQ, |
522 | }, | 591 | }, |
523 | { | 592 | { |
524 | .name = "MAIN_CH_TH_PROT_R", | 593 | .name = "BATT_OVV", |
525 | .start = AB8500_INT_MAIN_CH_TH_PROT_R, | 594 | .start = AB8500_INT_BATT_OVV, |
526 | .end = AB8500_INT_MAIN_CH_TH_PROT_R, | 595 | .end = AB8500_INT_BATT_OVV, |
527 | .flags = IORESOURCE_IRQ, | 596 | .flags = IORESOURCE_IRQ, |
528 | }, | 597 | }, |
529 | { | 598 | { |
530 | .name = "USB_CHARGER_NOT_OKF", | 599 | .name = "LOW_BAT_F", |
531 | .start = AB8500_INT_USB_CHARGER_NOT_OKF, | 600 | .start = AB8500_INT_LOW_BAT_F, |
532 | .end = AB8500_INT_USB_CHARGER_NOT_OKF, | 601 | .end = AB8500_INT_LOW_BAT_F, |
602 | .flags = IORESOURCE_IRQ, | ||
603 | }, | ||
604 | { | ||
605 | .name = "LOW_BAT_R", | ||
606 | .start = AB8500_INT_LOW_BAT_R, | ||
607 | .end = AB8500_INT_LOW_BAT_R, | ||
608 | .flags = IORESOURCE_IRQ, | ||
609 | }, | ||
610 | { | ||
611 | .name = "CC_INT_CALIB", | ||
612 | .start = AB8500_INT_CC_INT_CALIB, | ||
613 | .end = AB8500_INT_CC_INT_CALIB, | ||
533 | .flags = IORESOURCE_IRQ, | 614 | .flags = IORESOURCE_IRQ, |
534 | }, | 615 | }, |
535 | }; | 616 | }; |
536 | 617 | ||
618 | static struct resource __devinitdata ab8500_chargalg_resources[] = {}; | ||
619 | |||
537 | static struct resource __devinitdata ab8500_debug_resources[] = { | 620 | static struct resource __devinitdata ab8500_debug_resources[] = { |
538 | { | 621 | { |
539 | .name = "IRQ_FIRST", | 622 | .name = "IRQ_FIRST", |
@@ -580,6 +663,18 @@ static struct resource __devinitdata ab8500_usb_resources[] = { | |||
580 | .end = AB8500_INT_USB_LINK_STATUS, | 663 | .end = AB8500_INT_USB_LINK_STATUS, |
581 | .flags = IORESOURCE_IRQ, | 664 | .flags = IORESOURCE_IRQ, |
582 | }, | 665 | }, |
666 | { | ||
667 | .name = "USB_ADP_PROBE_PLUG", | ||
668 | .start = AB8500_INT_ADP_PROBE_PLUG, | ||
669 | .end = AB8500_INT_ADP_PROBE_PLUG, | ||
670 | .flags = IORESOURCE_IRQ, | ||
671 | }, | ||
672 | { | ||
673 | .name = "USB_ADP_PROBE_UNPLUG", | ||
674 | .start = AB8500_INT_ADP_PROBE_UNPLUG, | ||
675 | .end = AB8500_INT_ADP_PROBE_UNPLUG, | ||
676 | .flags = IORESOURCE_IRQ, | ||
677 | }, | ||
583 | }; | 678 | }; |
584 | 679 | ||
585 | static struct resource __devinitdata ab8500_temp_resources[] = { | 680 | static struct resource __devinitdata ab8500_temp_resources[] = { |
@@ -621,11 +716,33 @@ static struct mfd_cell __devinitdata ab8500_devs[] = { | |||
621 | .resources = ab8500_rtc_resources, | 716 | .resources = ab8500_rtc_resources, |
622 | }, | 717 | }, |
623 | { | 718 | { |
624 | .name = "ab8500-bm", | 719 | .name = "ab8500-charger", |
625 | .num_resources = ARRAY_SIZE(ab8500_bm_resources), | 720 | .num_resources = ARRAY_SIZE(ab8500_charger_resources), |
626 | .resources = ab8500_bm_resources, | 721 | .resources = ab8500_charger_resources, |
722 | }, | ||
723 | { | ||
724 | .name = "ab8500-btemp", | ||
725 | .num_resources = ARRAY_SIZE(ab8500_btemp_resources), | ||
726 | .resources = ab8500_btemp_resources, | ||
727 | }, | ||
728 | { | ||
729 | .name = "ab8500-fg", | ||
730 | .num_resources = ARRAY_SIZE(ab8500_fg_resources), | ||
731 | .resources = ab8500_fg_resources, | ||
732 | }, | ||
733 | { | ||
734 | .name = "ab8500-chargalg", | ||
735 | .num_resources = ARRAY_SIZE(ab8500_chargalg_resources), | ||
736 | .resources = ab8500_chargalg_resources, | ||
737 | }, | ||
738 | { | ||
739 | .name = "ab8500-acc-det", | ||
740 | .num_resources = ARRAY_SIZE(ab8500_av_acc_detect_resources), | ||
741 | .resources = ab8500_av_acc_detect_resources, | ||
742 | }, | ||
743 | { | ||
744 | .name = "ab8500-codec", | ||
627 | }, | 745 | }, |
628 | { .name = "ab8500-codec", }, | ||
629 | { | 746 | { |
630 | .name = "ab8500-usb", | 747 | .name = "ab8500-usb", |
631 | .num_resources = ARRAY_SIZE(ab8500_usb_resources), | 748 | .num_resources = ARRAY_SIZE(ab8500_usb_resources), |