diff options
author | Mattias Nilsson <mattias.i.nilsson@stericsson.com> | 2012-01-13 10:20:20 -0500 |
---|---|---|
committer | Samuel Ortiz <sameo@linux.intel.com> | 2012-03-06 12:46:32 -0500 |
commit | 0508901ca794d411efb09befb88b8194d8387428 (patch) | |
tree | 44539901a5db5a28955cf62c03860d073fa8a82d /include/linux/mfd/db8500-prcmu.h | |
parent | b58d12fe6ccd16030e1a69b5c443075f7bed0f6d (diff) |
mfd: Update abstract dbx500 interface
This prefixes a number of accessor functions with db8500_* since
they are DB8500-specific and we need to move to this naming
scheme.
We also replace numerous instances of machine_is() with cpu_is()
which covers the right type of ASICs rather than entire machines
i.e. boards.
Signed-off-by: Mattias Nilsson <mattias.i.nilsson@stericsson.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Diffstat (limited to 'include/linux/mfd/db8500-prcmu.h')
-rw-r--r-- | include/linux/mfd/db8500-prcmu.h | 61 |
1 files changed, 30 insertions, 31 deletions
diff --git a/include/linux/mfd/db8500-prcmu.h b/include/linux/mfd/db8500-prcmu.h index 18959171f446..c5028f1246fc 100644 --- a/include/linux/mfd/db8500-prcmu.h +++ b/include/linux/mfd/db8500-prcmu.h | |||
@@ -512,13 +512,9 @@ int prcmu_set_rc_a2p(enum romcode_write); | |||
512 | enum romcode_read prcmu_get_rc_p2a(void); | 512 | enum romcode_read prcmu_get_rc_p2a(void); |
513 | enum ap_pwrst prcmu_get_xp70_current_state(void); | 513 | enum ap_pwrst prcmu_get_xp70_current_state(void); |
514 | bool prcmu_has_arm_maxopp(void); | 514 | bool prcmu_has_arm_maxopp(void); |
515 | int prcmu_set_ape_opp(u8 opp); | ||
516 | int prcmu_get_ape_opp(void); | ||
517 | struct prcmu_fw_version *prcmu_get_fw_version(void); | 515 | struct prcmu_fw_version *prcmu_get_fw_version(void); |
518 | int prcmu_request_ape_opp_100_voltage(bool enable); | 516 | int prcmu_request_ape_opp_100_voltage(bool enable); |
519 | int prcmu_release_usb_wakeup_state(void); | 517 | int prcmu_release_usb_wakeup_state(void); |
520 | int prcmu_set_ddr_opp(u8 opp); | ||
521 | int prcmu_get_ddr_opp(void); | ||
522 | /* NOTE! Use regulator framework instead */ | 518 | /* NOTE! Use regulator framework instead */ |
523 | int prcmu_set_hwacc(u16 hw_acc_dev, u8 state); | 519 | int prcmu_set_hwacc(u16 hw_acc_dev, u8 state); |
524 | void prcmu_configure_auto_pm(struct prcmu_auto_pm_config *sleep, | 520 | void prcmu_configure_auto_pm(struct prcmu_auto_pm_config *sleep, |
@@ -527,24 +523,24 @@ bool prcmu_is_auto_pm_enabled(void); | |||
527 | 523 | ||
528 | int prcmu_config_clkout(u8 clkout, u8 source, u8 div); | 524 | int prcmu_config_clkout(u8 clkout, u8 source, u8 div); |
529 | int prcmu_set_clock_divider(u8 clock, u8 divider); | 525 | int prcmu_set_clock_divider(u8 clock, u8 divider); |
530 | int prcmu_config_hotdog(u8 threshold); | 526 | int db8500_prcmu_config_hotdog(u8 threshold); |
531 | int prcmu_config_hotmon(u8 low, u8 high); | 527 | int db8500_prcmu_config_hotmon(u8 low, u8 high); |
532 | int prcmu_start_temp_sense(u16 cycles32k); | 528 | int db8500_prcmu_start_temp_sense(u16 cycles32k); |
533 | int prcmu_stop_temp_sense(void); | 529 | int db8500_prcmu_stop_temp_sense(void); |
534 | int prcmu_abb_read(u8 slave, u8 reg, u8 *value, u8 size); | 530 | int prcmu_abb_read(u8 slave, u8 reg, u8 *value, u8 size); |
535 | int prcmu_abb_write(u8 slave, u8 reg, u8 *value, u8 size); | 531 | int prcmu_abb_write(u8 slave, u8 reg, u8 *value, u8 size); |
536 | 532 | ||
537 | void prcmu_ac_wake_req(void); | 533 | void prcmu_ac_wake_req(void); |
538 | void prcmu_ac_sleep_req(void); | 534 | void prcmu_ac_sleep_req(void); |
539 | void prcmu_modem_reset(void); | 535 | void db8500_prcmu_modem_reset(void); |
540 | void prcmu_enable_spi2(void); | 536 | void prcmu_enable_spi2(void); |
541 | void prcmu_disable_spi2(void); | 537 | void prcmu_disable_spi2(void); |
542 | 538 | ||
543 | int prcmu_config_a9wdog(u8 num, bool sleep_auto_off); | 539 | int db8500_prcmu_config_a9wdog(u8 num, bool sleep_auto_off); |
544 | int prcmu_enable_a9wdog(u8 id); | 540 | int db8500_prcmu_enable_a9wdog(u8 id); |
545 | int prcmu_disable_a9wdog(u8 id); | 541 | int db8500_prcmu_disable_a9wdog(u8 id); |
546 | int prcmu_kick_a9wdog(u8 id); | 542 | int db8500_prcmu_kick_a9wdog(u8 id); |
547 | int prcmu_load_a9wdog(u8 id, u32 val); | 543 | int db8500_prcmu_load_a9wdog(u8 id, u32 val); |
548 | 544 | ||
549 | void db8500_prcmu_system_reset(u16 reset_code); | 545 | void db8500_prcmu_system_reset(u16 reset_code); |
550 | int db8500_prcmu_set_power_state(u8 state, bool keep_ulp_clk, bool keep_ap_pll); | 546 | int db8500_prcmu_set_power_state(u8 state, bool keep_ulp_clk, bool keep_ap_pll); |
@@ -561,6 +557,10 @@ u16 db8500_prcmu_get_reset_code(void); | |||
561 | bool db8500_prcmu_is_ac_wake_requested(void); | 557 | bool db8500_prcmu_is_ac_wake_requested(void); |
562 | int db8500_prcmu_set_arm_opp(u8 opp); | 558 | int db8500_prcmu_set_arm_opp(u8 opp); |
563 | int db8500_prcmu_get_arm_opp(void); | 559 | int db8500_prcmu_get_arm_opp(void); |
560 | int db8500_prcmu_set_ape_opp(u8 opp); | ||
561 | int db8500_prcmu_get_ape_opp(void); | ||
562 | int db8500_prcmu_set_ddr_opp(u8 opp); | ||
563 | int db8500_prcmu_get_ddr_opp(void); | ||
564 | 564 | ||
565 | #else /* !CONFIG_MFD_DB8500_PRCMU */ | 565 | #else /* !CONFIG_MFD_DB8500_PRCMU */ |
566 | 566 | ||
@@ -591,12 +591,12 @@ static inline struct prcmu_fw_version *prcmu_get_fw_version(void) | |||
591 | return NULL; | 591 | return NULL; |
592 | } | 592 | } |
593 | 593 | ||
594 | static inline int prcmu_set_ape_opp(u8 opp) | 594 | static inline int db8500_prcmu_set_ape_opp(u8 opp) |
595 | { | 595 | { |
596 | return 0; | 596 | return 0; |
597 | } | 597 | } |
598 | 598 | ||
599 | static inline int prcmu_get_ape_opp(void) | 599 | static inline int db8500_prcmu_get_ape_opp(void) |
600 | { | 600 | { |
601 | return APE_100_OPP; | 601 | return APE_100_OPP; |
602 | } | 602 | } |
@@ -611,12 +611,12 @@ static inline int prcmu_release_usb_wakeup_state(void) | |||
611 | return 0; | 611 | return 0; |
612 | } | 612 | } |
613 | 613 | ||
614 | static inline int prcmu_set_ddr_opp(u8 opp) | 614 | static inline int db8500_prcmu_set_ddr_opp(u8 opp) |
615 | { | 615 | { |
616 | return 0; | 616 | return 0; |
617 | } | 617 | } |
618 | 618 | ||
619 | static inline int prcmu_get_ddr_opp(void) | 619 | static inline int db8500_prcmu_get_ddr_opp(void) |
620 | { | 620 | { |
621 | return DDR_100_OPP; | 621 | return DDR_100_OPP; |
622 | } | 622 | } |
@@ -625,7 +625,6 @@ static inline int prcmu_set_hwacc(u16 hw_acc_dev, u8 state) | |||
625 | { | 625 | { |
626 | return 0; | 626 | return 0; |
627 | } | 627 | } |
628 | |||
629 | static inline void prcmu_configure_auto_pm(struct prcmu_auto_pm_config *sleep, | 628 | static inline void prcmu_configure_auto_pm(struct prcmu_auto_pm_config *sleep, |
630 | struct prcmu_auto_pm_config *idle) | 629 | struct prcmu_auto_pm_config *idle) |
631 | { | 630 | { |
@@ -646,22 +645,22 @@ static inline int prcmu_set_clock_divider(u8 clock, u8 divider) | |||
646 | return 0; | 645 | return 0; |
647 | } | 646 | } |
648 | 647 | ||
649 | static inline int prcmu_config_hotdog(u8 threshold) | 648 | static inline int db8500_prcmu_config_hotdog(u8 threshold) |
650 | { | 649 | { |
651 | return 0; | 650 | return 0; |
652 | } | 651 | } |
653 | 652 | ||
654 | static inline int prcmu_config_hotmon(u8 low, u8 high) | 653 | static inline int db8500_prcmu_config_hotmon(u8 low, u8 high) |
655 | { | 654 | { |
656 | return 0; | 655 | return 0; |
657 | } | 656 | } |
658 | 657 | ||
659 | static inline int prcmu_start_temp_sense(u16 cycles32k) | 658 | static inline int db8500_prcmu_start_temp_sense(u16 cycles32k) |
660 | { | 659 | { |
661 | return 0; | 660 | return 0; |
662 | } | 661 | } |
663 | 662 | ||
664 | static inline int prcmu_stop_temp_sense(void) | 663 | static inline int db8500_prcmu_stop_temp_sense(void) |
665 | { | 664 | { |
666 | return 0; | 665 | return 0; |
667 | } | 666 | } |
@@ -680,7 +679,9 @@ static inline void prcmu_ac_wake_req(void) {} | |||
680 | 679 | ||
681 | static inline void prcmu_ac_sleep_req(void) {} | 680 | static inline void prcmu_ac_sleep_req(void) {} |
682 | 681 | ||
683 | static inline void prcmu_modem_reset(void) {} | 682 | static inline void db8500_prcmu_modem_reset(void) {} |
683 | |||
684 | static inline void db8500_prcmu_system_reset(u16 reset_code) {} | ||
684 | 685 | ||
685 | static inline int prcmu_enable_spi2(void) | 686 | static inline int prcmu_enable_spi2(void) |
686 | { | 687 | { |
@@ -692,8 +693,6 @@ static inline int prcmu_disable_spi2(void) | |||
692 | return 0; | 693 | return 0; |
693 | } | 694 | } |
694 | 695 | ||
695 | static inline void db8500_prcmu_system_reset(u16 reset_code) {} | ||
696 | |||
697 | static inline int db8500_prcmu_set_power_state(u8 state, bool keep_ulp_clk, | 696 | static inline int db8500_prcmu_set_power_state(u8 state, bool keep_ulp_clk, |
698 | bool keep_ap_pll) | 697 | bool keep_ap_pll) |
699 | { | 698 | { |
@@ -741,27 +740,27 @@ static inline u16 db8500_prcmu_get_reset_code(void) | |||
741 | return 0; | 740 | return 0; |
742 | } | 741 | } |
743 | 742 | ||
744 | static inline int prcmu_config_a9wdog(u8 num, bool sleep_auto_off) | 743 | static inline int db8500_prcmu_config_a9wdog(u8 num, bool sleep_auto_off) |
745 | { | 744 | { |
746 | return 0; | 745 | return 0; |
747 | } | 746 | } |
748 | 747 | ||
749 | static inline int prcmu_enable_a9wdog(u8 id) | 748 | static inline int db8500_prcmu_enable_a9wdog(u8 id) |
750 | { | 749 | { |
751 | return 0; | 750 | return 0; |
752 | } | 751 | } |
753 | 752 | ||
754 | static inline int prcmu_disable_a9wdog(u8 id) | 753 | static inline int db8500_prcmu_disable_a9wdog(u8 id) |
755 | { | 754 | { |
756 | return 0; | 755 | return 0; |
757 | } | 756 | } |
758 | 757 | ||
759 | static inline int prcmu_kick_a9wdog(u8 id) | 758 | static inline int db8500_prcmu_kick_a9wdog(u8 id) |
760 | { | 759 | { |
761 | return 0; | 760 | return 0; |
762 | } | 761 | } |
763 | 762 | ||
764 | static inline int prcmu_load_a9wdog(u8 id, u32 val) | 763 | static inline int db8500_prcmu_load_a9wdog(u8 id, u32 val) |
765 | { | 764 | { |
766 | return 0; | 765 | return 0; |
767 | } | 766 | } |