diff options
author | Jaecheol Lee <jc.lee@samsung.com> | 2011-07-18 19:21:41 +0900 |
---|---|---|
committer | Kukjin Kim <kgene.kim@samsung.com> | 2011-07-20 23:38:32 +0900 |
commit | 12974e9f707888044a3af3a12ebdebf0a509a1fa (patch) | |
tree | 18ba5046909df069b350f2de76778004bb42442e /arch/arm/mach-exynos4 | |
parent | e240ab1cfbf8e341c38847fe9aee8579a01ed303 (diff) |
ARM: EXYNOS4: Move S5P_CENTRAL_SEQ_CONFIGURATION setting for PM
We need to balance between set and check S5P_CENTRAL_SEQ_CONFIGURATION
register in syscore_ops suspend/resume function when failure in enter
suspend mode. Moved this register setting for PM for the purpose of balancing.
Signed-off-by: Jaecheol Lee <jc.lee@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Diffstat (limited to 'arch/arm/mach-exynos4')
-rw-r--r-- | arch/arm/mach-exynos4/pm.c | 22 |
1 files changed, 14 insertions, 8 deletions
diff --git a/arch/arm/mach-exynos4/pm.c b/arch/arm/mach-exynos4/pm.c index 1ff290f73837..aa27b90068c0 100644 --- a/arch/arm/mach-exynos4/pm.c +++ b/arch/arm/mach-exynos4/pm.c @@ -209,14 +209,6 @@ static struct sleep_save exynos4_l2cc_save[] = { void exynos4_cpu_suspend(void) { - unsigned long tmp; - - /* Setting Central Sequence Register for power down mode */ - - tmp = __raw_readl(S5P_CENTRAL_SEQ_CONFIGURATION); - tmp &= ~(S5P_CENTRAL_LOWPWR_CFG); - __raw_writel(tmp, S5P_CENTRAL_SEQ_CONFIGURATION); - outer_flush_all(); /* issue the standby signal into the pm unit. */ @@ -299,6 +291,19 @@ static __init int exynos4_pm_drvinit(void) } arch_initcall(exynos4_pm_drvinit); +static int exynos4_pm_suspend(void) +{ + unsigned long tmp; + + /* Setting Central Sequence Register for power down mode */ + + tmp = __raw_readl(S5P_CENTRAL_SEQ_CONFIGURATION); + tmp &= ~S5P_CENTRAL_LOWPWR_CFG; + __raw_writel(tmp, S5P_CENTRAL_SEQ_CONFIGURATION); + + return 0; +} + static void exynos4_pm_resume(void) { unsigned long tmp; @@ -343,6 +348,7 @@ early_wakeup: } static struct syscore_ops exynos4_pm_syscore_ops = { + .suspend = exynos4_pm_suspend, .resume = exynos4_pm_resume, }; |