diff options
author | Mattias Nilsson <mattias.i.nilsson@stericsson.com> | 2012-01-13 10:20:10 -0500 |
---|---|---|
committer | Samuel Ortiz <sameo@linux.intel.com> | 2012-03-06 12:46:31 -0500 |
commit | b58d12fe6ccd16030e1a69b5c443075f7bed0f6d (patch) | |
tree | 13d9d0047374df218c92ed9f6080c20f1410f321 /include/linux/mfd | |
parent | c72fe851df21603cd149320df49064eb2f903707 (diff) |
mfd: Function for obtaining the db8500 prcmu firmware version
This patch exports a function that can be used to tell which
version of the DB8500 PRCMU firmware is available, and revamps the
firmware detection code a bit.
Reviewed-by: Bengt Jonsson <bengt.g.jonsson@stericsson.com>
Reviewed-by: Jonas Aberg <jonas.aberg@stericsson.com>
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')
-rw-r--r-- | include/linux/mfd/db8500-prcmu.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/include/linux/mfd/db8500-prcmu.h b/include/linux/mfd/db8500-prcmu.h index 0dc9017272bc..18959171f446 100644 --- a/include/linux/mfd/db8500-prcmu.h +++ b/include/linux/mfd/db8500-prcmu.h | |||
@@ -493,6 +493,18 @@ struct prcmu_auto_pm_config { | |||
493 | u8 sva_policy; | 493 | u8 sva_policy; |
494 | }; | 494 | }; |
495 | 495 | ||
496 | #define PRCMU_FW_PROJECT_U8500 2 | ||
497 | #define PRCMU_FW_PROJECT_U9500 4 | ||
498 | #define PRCMU_FW_PROJECT_U8500_C2 7 | ||
499 | #define PRCMU_FW_PROJECT_U9500_C2 11 | ||
500 | |||
501 | struct prcmu_fw_version { | ||
502 | u8 project; | ||
503 | u8 api_version; | ||
504 | u8 func_version; | ||
505 | u8 errata; | ||
506 | }; | ||
507 | |||
496 | #ifdef CONFIG_MFD_DB8500_PRCMU | 508 | #ifdef CONFIG_MFD_DB8500_PRCMU |
497 | 509 | ||
498 | void db8500_prcmu_early_init(void); | 510 | void db8500_prcmu_early_init(void); |
@@ -502,6 +514,7 @@ enum ap_pwrst prcmu_get_xp70_current_state(void); | |||
502 | bool prcmu_has_arm_maxopp(void); | 514 | bool prcmu_has_arm_maxopp(void); |
503 | int prcmu_set_ape_opp(u8 opp); | 515 | int prcmu_set_ape_opp(u8 opp); |
504 | int prcmu_get_ape_opp(void); | 516 | int prcmu_get_ape_opp(void); |
517 | struct prcmu_fw_version *prcmu_get_fw_version(void); | ||
505 | int prcmu_request_ape_opp_100_voltage(bool enable); | 518 | int prcmu_request_ape_opp_100_voltage(bool enable); |
506 | int prcmu_release_usb_wakeup_state(void); | 519 | int prcmu_release_usb_wakeup_state(void); |
507 | int prcmu_set_ddr_opp(u8 opp); | 520 | int prcmu_set_ddr_opp(u8 opp); |
@@ -573,6 +586,11 @@ static inline bool prcmu_has_arm_maxopp(void) | |||
573 | return false; | 586 | return false; |
574 | } | 587 | } |
575 | 588 | ||
589 | static inline struct prcmu_fw_version *prcmu_get_fw_version(void) | ||
590 | { | ||
591 | return NULL; | ||
592 | } | ||
593 | |||
576 | static inline int prcmu_set_ape_opp(u8 opp) | 594 | static inline int prcmu_set_ape_opp(u8 opp) |
577 | { | 595 | { |
578 | return 0; | 596 | return 0; |