summaryrefslogtreecommitdiffstats
path: root/kernel/power
diff options
context:
space:
mode:
authorIngo Molnar <mingo@kernel.org>2016-07-08 17:27:47 +0200
committerIngo Molnar <mingo@kernel.org>2016-07-08 17:27:47 +0200
commit9e7f7f5425e6d1492109a537ee88c99b29580655 (patch)
tree81f9d68abb5b793aadaf80bd6940af04e3c16eb9 /kernel/power
parent6daa2ec0b3e3808c55329d12de3c157cf38b17b0 (diff)
parentf80fd3a5fff88a9ace7e8cd11d07cf874a63ea9f (diff)
downloadlinux-9e7f7f5425e6d1492109a537ee88c99b29580655.tar.bz2
Merge branch 'x86/mm' into x86/boot, to pick up dependencies
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'kernel/power')
-rw-r--r--kernel/power/process.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/kernel/power/process.c b/kernel/power/process.c
index df058bed53ce..0c2ee9761d57 100644
--- a/kernel/power/process.c
+++ b/kernel/power/process.c
@@ -146,6 +146,18 @@ int freeze_processes(void)
if (!error && !oom_killer_disable())
error = -EBUSY;
+ /*
+ * There is a hard to fix race between oom_reaper kernel thread
+ * and oom_killer_disable. oom_reaper calls exit_oom_victim
+ * before the victim reaches exit_mm so try to freeze all the tasks
+ * again and catch such a left over task.
+ */
+ if (!error) {
+ pr_info("Double checking all user space processes after OOM killer disable... ");
+ error = try_to_freeze_tasks(true);
+ pr_cont("\n");
+ }
+
if (error)
thaw_processes();
return error;