ARM: pm: allow suspend finisher to return error codes
authorRussell King <rmk+kernel@arm.linux.org.uk>
Sat, 2 Jul 2011 08:54:01 +0000 (09:54 +0100)
committerJason Kridner <jdk@ti.com>
Sat, 17 Sep 2011 13:14:17 +0000 (09:14 -0400)
commit813ef690a6b7b14d2b553d340681594293a3e3da
treee032d709fcc51d4e2f739d98b54dde48618645e9
parent339c57122f74fa4e4dcb20107dbf8655f484d2d3
ARM: pm: allow suspend finisher to return error codes

There are SoCs where attempting to enter a low power state is ignored,
and the CPU continues executing instructions with all state preserved.
It is over-complex at that point to disable the MMU just to call the
resume path.

Instead, allow the suspend finisher to return error codes to abort
suspend in this circumstance, where the cpu_suspend internals will then
unwind the saved state on the stack.  Also omit the tlb flush as no
changes to the page tables will have happened.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
12 files changed:
arch/arm/include/asm/suspend.h
arch/arm/kernel/sleep.S
arch/arm/mach-exynos4/pm.c
arch/arm/mach-omap2/pm34xx.c
arch/arm/mach-pxa/include/mach/pm.h
arch/arm/mach-pxa/pxa3xx.c
arch/arm/mach-s3c2412/pm.c
arch/arm/mach-s3c2416/pm.c
arch/arm/mach-s3c64xx/pm.c
arch/arm/mach-sa1100/pm.c
arch/arm/plat-samsung/include/plat/pm.h
arch/arm/plat-samsung/pm.c