diff options
author | Russell King <rmk+kernel@arm.linux.org.uk> | 2011-06-21 11:29:30 -0400 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2011-06-24 03:48:45 -0400 |
commit | a9503d2185bbc28e498c435a07f24986c48b5cbe (patch) | |
tree | 86987b72ceccea710fa67085f51c6083a9fc672e /arch/arm/mach-pxa/pxa27x.c | |
parent | 372c0ac8aca7655b6a8920b10bf9563402ac19d8 (diff) |
ARM: pm: pxa: move cpu_suspend into C code
We don't need a veneer for cpu_suspend, it can be called directly from
C code now. Move it into the PXA CPU suspend functions, along with
the accumulator register saving/restoring.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm/mach-pxa/pxa27x.c')
-rw-r--r-- | arch/arm/mach-pxa/pxa27x.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/arch/arm/mach-pxa/pxa27x.c b/arch/arm/mach-pxa/pxa27x.c index 2fecbec58d88..824379d43758 100644 --- a/arch/arm/mach-pxa/pxa27x.c +++ b/arch/arm/mach-pxa/pxa27x.c | |||
@@ -284,6 +284,11 @@ void pxa27x_cpu_pm_restore(unsigned long *sleep_save) | |||
284 | void pxa27x_cpu_pm_enter(suspend_state_t state) | 284 | void pxa27x_cpu_pm_enter(suspend_state_t state) |
285 | { | 285 | { |
286 | extern void pxa_cpu_standby(void); | 286 | extern void pxa_cpu_standby(void); |
287 | #ifndef CONFIG_IWMMXT | ||
288 | u64 acc0; | ||
289 | |||
290 | asm volatile("mra %Q0, %R0, acc0" : "=r" (acc0)); | ||
291 | #endif | ||
287 | 292 | ||
288 | /* ensure voltage-change sequencer not initiated, which hangs */ | 293 | /* ensure voltage-change sequencer not initiated, which hangs */ |
289 | PCFR &= ~PCFR_FVC; | 294 | PCFR &= ~PCFR_FVC; |
@@ -299,7 +304,11 @@ void pxa27x_cpu_pm_enter(suspend_state_t state) | |||
299 | pxa_cpu_standby(); | 304 | pxa_cpu_standby(); |
300 | break; | 305 | break; |
301 | case PM_SUSPEND_MEM: | 306 | case PM_SUSPEND_MEM: |
302 | pxa27x_cpu_suspend(pwrmode, PLAT_PHYS_OFFSET - PAGE_OFFSET); | 307 | cpu_suspend(0, PHYS_OFFSET - PAGE_OFFSET, pwrmode, |
308 | pxa27x_finish_suspend); | ||
309 | #ifndef CONFIG_IWMMXT | ||
310 | asm volatile("mar acc0, %Q0, %R0" : "=r" (acc0)); | ||
311 | #endif | ||
303 | break; | 312 | break; |
304 | } | 313 | } |
305 | } | 314 | } |