diff options
author | Srivatsa Vaddagiri <vatsa@linux.vnet.ibm.com> | 2007-10-17 10:55:11 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2007-10-17 10:55:11 -0400 |
commit | b9dca1e0fcb696716840a3bc8f20a6941b484dbf (patch) | |
tree | 1fb2198b192b35382756e288ba33df6f37fcf6d4 /kernel/sched.c | |
parent | b1a8c172c318534b96d0f0f1aecdad3898118b98 (diff) |
sched: fix new task startup crash
Child task may be added on a different cpu that the one on which parent
is running. In which case, task_new_fair() should check whether the new
born task's parent entity should be added as well on the cfs_rq.
Patch below fixes the problem in task_new_fair.
This could fix the put_prev_task_fair() crashes reported.
Reported-by: Kamalesh Babulal <kamalesh@linux.vnet.ibm.com>
Reported-by: Andy Whitcroft <apw@shadowen.org>
Signed-off-by: Srivatsa Vaddagiri <vatsa@linux.vnet.ibm.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel/sched.c')
-rw-r--r-- | kernel/sched.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/sched.c b/kernel/sched.c index 975436435b42..0ec9521a8e70 100644 --- a/kernel/sched.c +++ b/kernel/sched.c | |||
@@ -1712,7 +1712,7 @@ void fastcall wake_up_new_task(struct task_struct *p, unsigned long clone_flags) | |||
1712 | 1712 | ||
1713 | p->prio = effective_prio(p); | 1713 | p->prio = effective_prio(p); |
1714 | 1714 | ||
1715 | if (!p->sched_class->task_new || !current->se.on_rq || !rq->cfs.curr) { | 1715 | if (!p->sched_class->task_new || !current->se.on_rq) { |
1716 | activate_task(rq, p, 0); | 1716 | activate_task(rq, p, 0); |
1717 | } else { | 1717 | } else { |
1718 | /* | 1718 | /* |