]> git.hungrycats.org Git - linux/commitdiff
sched/core: Remove false-positive warning from wake_up_process()
authorSasha Levin <sasha.levin@oracle.com>
Tue, 1 Dec 2015 01:34:20 +0000 (20:34 -0500)
committerJiri Slaby <jslaby@suse.cz>
Thu, 3 Mar 2016 11:45:58 +0000 (12:45 +0100)
commit 119d6f6a3be8b424b200dcee56e74484d5445f7e upstream.

Because wakeups can (fundamentally) be late, a task might not be in
the expected state. Therefore testing against a task's state is racy,
and can yield false positives.

Signed-off-by: Sasha Levin <sasha.levin@oracle.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Acked-by: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: oleg@redhat.com
Fixes: 9067ac85d533 ("wake_up_process() should be never used to wakeup a TASK_STOPPED/TRACED task")
Link: http://lkml.kernel.org/r/1448933660-23082-1-git-send-email-sasha.levin@oracle.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
kernel/sched/core.c

index e7de9175e5863eab6e59edf4996c157d3a5d7e0a..3800316d7424b8d7a4deda13b141e3d21683733f 100644 (file)
@@ -1590,7 +1590,6 @@ out:
  */
 int wake_up_process(struct task_struct *p)
 {
-       WARN_ON(task_is_stopped_or_traced(p));
        return try_to_wake_up(p, TASK_NORMAL, 0);
 }
 EXPORT_SYMBOL(wake_up_process);