Commit-ID: 658ec71827f6ebacd12e2f0c6d723084980651e0 Gitweb: http://git.kernel.org/tip/658ec71827f6ebacd12e2f0c6d723084980651e0 Author: Peter Zijlstra <peterz@xxxxxxxxxxxxx> AuthorDate: Thu, 21 Jan 2010 16:34:27 +0100 Committer: Ingo Molnar <mingo@xxxxxxx> CommitDate: Wed, 27 Jan 2010 08:34:39 +0100 sched: Fix incorrect sanity check We moved to migrate on wakeup, which means that sleeping tasks could still be present on offline cpus. Amend the check to only test running tasks. Reported-by: Heiko Carstens <heiko.carstens@xxxxxxxxxx> Signed-off-by: Peter Zijlstra <a.p.zijlstra@xxxxxxxxx> Signed-off-by: Ingo Molnar <mingo@xxxxxxx> --- kernel/cpu.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/kernel/cpu.c b/kernel/cpu.c index 1c8ddd6..08e54e7 100644 --- a/kernel/cpu.c +++ b/kernel/cpu.c @@ -151,7 +151,7 @@ static inline void check_for_tasks(int cpu) write_lock_irq(&tasklist_lock); for_each_process(p) { - if (task_cpu(p) == cpu && + if (task_cpu(p) == cpu && p->state == TASK_RUNNING && (!cputime_eq(p->utime, cputime_zero) || !cputime_eq(p->stime, cputime_zero))) printk(KERN_WARNING "Task %s (pid = %d) is on cpu %d\ -- To unsubscribe from this list: send the line "unsubscribe linux-tip-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html
![]() |