summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@linutronix.de>2010-07-15 08:29:00 (GMT)
committerScott Wood <scottwood@freescale.com>2014-04-10 00:18:41 (GMT)
commit9761c77c68f2aa54d23a1e76c73667af330e8379 (patch)
tree3e7f77543795f29001e7d07fb5a70193dd5769ef /include
parent875e6cc6106b93960edc0241748315a3fcde6b66 (diff)
downloadlinux-fsl-qoriq-9761c77c68f2aa54d23a1e76c73667af330e8379.tar.xz
suspend: Prevent might sleep splats
timekeeping suspend/resume calls read_persistant_clock() which takes rtc_lock. That results in might sleep warnings because at that point we run with interrupts disabled. We cannot convert rtc_lock to a raw spinlock as that would trigger other might sleep warnings. As a temporary workaround we disable the might sleep warnings by setting system_state to SYSTEM_SUSPEND before calling sysdev_suspend() and restoring it to SYSTEM_RUNNING afer sysdev_resume(). Needs to be revisited. Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'include')
-rw-r--r--include/linux/kernel.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/kernel.h b/include/linux/kernel.h
index 672ddc4..c34e608 100644
--- a/include/linux/kernel.h
+++ b/include/linux/kernel.h
@@ -412,6 +412,7 @@ extern enum system_states {
SYSTEM_HALT,
SYSTEM_POWER_OFF,
SYSTEM_RESTART,
+ SYSTEM_SUSPEND,
} system_state;
#define TAINT_PROPRIETARY_MODULE 0