summaryrefslogtreecommitdiff
path: root/arch/arm/mach-ux500/pm/pm.c
diff options
context:
space:
mode:
authorPhilippe Langlais <philippe.langlais@linaro.org>2011-07-07 13:39:47 +0200
committerUlf Hansson <ulf.hansson@stericsson.com>2011-09-19 15:15:43 +0200
commit31470a483d96caf4d439fe41e8144bde728cf286 (patch)
tree05d860463de00efee669d4630c2bf0d7150f8303 /arch/arm/mach-ux500/pm/pm.c
parentf39ddd4052704c60a950c055b6f18f5aeed0c40e (diff)
ux500: align u5500 PRCMU & CPUFREQ management with u8500 (multiple commits in one)
Signed-off-by: Philippe Langlais <philippe.langlais@linaro.org> Merge of following commits too: u5500: add support for sysclk basic sysclk support added in PRCMU driver and clock framework driver updated. Signed-off-by: Shreshtha Kumar Sahu <shreshthakumar.sahu@stericsson.com> U5500: Support for ESRAM12 EPOD in PRCMU driver Signed-off-by: Vijaya Kumar Kilari <vijay.kilari@stericsson.com> ux500: regulator: handle different base offset of ePOD ID 5500 ePOD ids are offseted for some reason in the PRCMU driver. Adjust the ids to index the local arrays to avoid memory corruption. Signed-off-by: Rabin Vincent <rabin.vincent@stericsson.com> ux500: pm: support PRCMU status check on 5500 This also removes unused 8500v1 code. Signed-off-by: Rabin Vincent <rabin.vincent@stericsson.com> arm: ux500: prcmu_ac_wake_req workaround This patch adds a check in prcmu_ac_wake_req that the modem is awake (in terms of the value in the PRCM_MOD_AWAKE_STATUS register) after the AC_WAKE_ACK has been received from the PRCMU FW. If the check fails, a retry is made. This seems to be necessary, since the modem can generate an AC_WAKE_ACK, and then still go to sleep. Signed-off-by: Mattias Nilsson <mattias.i.nilsson@stericsson.com> U5500: Add support for PRCMU Mailbox0 Add PRCMU mailbox 0 support for irq wakeup enable and disable Signed-off-by: Vijaya Kumar K <vijay.kilari@stericsson.com> U5500: Add support for power state transition PRCMU driver is updated to provide API for system power state transition Signed-off-by: Vijaya Kumar K <vijay.kilari@stericsson.com> ARM: ux500: prcmu: Add A9 watchdog interface Signed-off-by: Jonas Aaberg <jonas.aberg@stericsson.com> U5500 : ab5500 core interrupt hander update AB5500 interrupts will be now handled by PRCMU and then routed to AB5500 core driver.AB5500 irq handler will no more read the latch registers to find the interrupt reason.Instead PRCMU will read the latch registers and provide the values to core driver. Signed-off-by: Bibek Basu <bibek.basu@stericsson.com> ARM: ux500: prcmu-dbg: Tiny code clean-up Signed-off-by: Jonas Aaberg <jonas.aberg@stericsson.com> u5500: add mailbox1 and related function support Add cpufreq-db5500.c file for db5500 CPUfreq support. PRCMU mailbox1 and related functions' support is added. List of functions implemented: - prcmu_get/set_arm_opp - read_mailbox_1 Signed-off-by: Shreshtha Kumar Sahu <shreshthakumar.sahu@stericsson.com> Fix for PRCMU u5500: PRCMU IRQ should be NO_SUSPEND As on 8500. Signed-off-by: Rabin Vincent <rabin.vincent@stericsson.com> ARM: u5500: PRCMU reset API Added API for rebooting the board and for getting the last reboot code. Signed-off-by: Pawel Szyszuk <pawel.szyszuk@stericsson.com>
Diffstat (limited to 'arch/arm/mach-ux500/pm/pm.c')
-rw-r--r--arch/arm/mach-ux500/pm/pm.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/arch/arm/mach-ux500/pm/pm.c b/arch/arm/mach-ux500/pm/pm.c
index 5324d715274..b6442212324 100644
--- a/arch/arm/mach-ux500/pm/pm.c
+++ b/arch/arm/mach-ux500/pm/pm.c
@@ -185,18 +185,21 @@ bool ux500_pm_other_cpu_wfi(void)
return false;
}
-#define PRCMU_STATUS_REGISTER_V1 0x8015fe08
-#define PRCMU_STATUS_REGISTER_V2 0x801b8e08
+/* PRCM_ACK_MB0_AP_PWRSTTR_STATUS */
+#define DB8500_PRCMU_STATUS_REGISTER 0x801b8e08
+#define DB5500_PRCMU_STATUS_REGISTER 0x80168f38
enum prcmu_idle_stat ux500_pm_prcmu_idle_stat(void)
{
u32 val;
void __iomem *prcmu_status_reg;
- if (cpu_is_u8500v20_or_later())
- prcmu_status_reg = (void *)IO_ADDRESS(PRCMU_STATUS_REGISTER_V2);
+ if (cpu_is_u8500())
+ prcmu_status_reg = __io_address(DB8500_PRCMU_STATUS_REGISTER);
+ else if (cpu_is_u5500())
+ prcmu_status_reg = __io_address(DB5500_PRCMU_STATUS_REGISTER);
else
- prcmu_status_reg = (void *)IO_ADDRESS(PRCMU_STATUS_REGISTER_V1);
+ ux500_unknown_soc();
val = readl(prcmu_status_reg) & 0xff;