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>
Thu, 15 Sep 2011 18:59:00 +0000 (14:59 -0400)
commit2b48193913e7762057fe3dc19196c453caf04963
tree116858f4f6161de6be1bc5f5a93c5c6e7ed899e9
parent07a01af52ab41994991485946796fcb83f7d4669
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