msm: idle-v7: SMP and AMP mode programming for 8x25 target
Program the Auxiliary Control Regiater(ACTLR.SMP) to switch
from Symmetric MultiProcessing Mode(SMP) to Asymmetric Multi
Processing Mode(AMP) while entering into the GDFS power mode.
This enables the CPU to be taken out of coherency by preventing
the CPU from receiving cache and TLB maintenance operations
broadcast by other CPUs in the system.
Change-Id: I74285e445e86cdb78a85705347550c762e47a0e2
Signed-off-by: Murali Nalajala <mnalajal@codeaurora.org>
diff --git a/arch/arm/mach-msm/pm2.c b/arch/arm/mach-msm/pm2.c
index d87d70f..a5e52be 100644
--- a/arch/arm/mach-msm/pm2.c
+++ b/arch/arm/mach-msm/pm2.c
@@ -1862,6 +1862,7 @@
unsigned int cpu;
#endif
int ret;
+ int val;
#ifdef CONFIG_CPU_V7
pgd_t *pc_pgd;
pmd_t *pmd;
@@ -1925,6 +1926,19 @@
return ret;
}
+ if (cpu_is_msm8625()) {
+ target_type = TARGET_IS_8625;
+ clean_caches((unsigned long)&target_type, sizeof(target_type),
+ virt_to_phys(&target_type));
+
+ /* Override the DBGNOPOWERDN for each cpu in
+ * MPA5_GDFS_CNT_VAL register
+ */
+ val = __raw_readl((MSM_CFG_CTL_BASE + 0x38));
+ val = val | 0x00030000;
+ __raw_writel(val, (MSM_CFG_CTL_BASE + 0x38));
+ }
+
#ifdef CONFIG_MSM_MEMORY_LOW_POWER_MODE
/* The wakeup_reason field is overloaded during initialization time
to signal Modem that Apps will control the low power modes of