>>> On Sat, Nov 17, 2007 at 1:21 AM, in message <20071117062404.672976284@goodmis.org>, Steven Rostedt wrote: > -/* > - * wake_idle() will wake a task on an idle cpu if task->cpu is > - * not idle and an idle cpu is available. The span of cpus to > - * search starts with cpus closest then further out as needed, > - * so we always favor a closer, idle cpu. > - * > - * Returns the CPU we should wake onto. > - */ > -#if defined(ARCH_HAS_SCHED_WAKE_IDLE) > -static int wake_idle(int cpu, struct task_struct *p) > -{ > - cpumask_t tmp; > - struct sched_domain *sd; > - int i; > - > - /* > - * If it is idle, then it is the best cpu to run this task. > - * > - * This cpu is also the best, if it has more than one task already. > - * Siblings must be also busy(in most cases) as they didn't already > - * pickup the extra load from this cpu and hence we need not check > - * sibling runqueue info. This will avoid the checks and cache miss > - * penalities associated with that. > - */ > - if (idle_cpu(cpu) || cpu_rq(cpu)->nr_running > 1) > - return cpu; > - > - for_each_domain(cpu, sd) { > - if (sd->flags & SD_WAKE_IDLE) { > - cpus_and(tmp, sd->span, p->cpus_allowed); > - for_each_cpu_mask(i, tmp) { > - if (idle_cpu(i)) { > - if (i != task_cpu(p)) { > - schedstat_inc(p, > - se.nr_wakeups_idle); ^^^^^^^^^^^^^^^^^^^^^ [...] > --- linux-compile.git.orig/kernel/sched_fair.c 2007-11-16 11:16:38.000000000 -0500 > +++ linux-compile.git/kernel/sched_fair.c 2007-11-16 22:23:39.000000000 -0500 > @@ -564,6 +564,137 @@ dequeue_entity(struct cfs_rq *cfs_rq, st > } > > /* > + * wake_idle() will wake a task on an idle cpu if task->cpu is > + * not idle and an idle cpu is available. The span of cpus to > + * search starts with cpus closest then further out as needed, > + * so we always favor a closer, idle cpu. > + * > + * Returns the CPU we should wake onto. > + */ > +#if defined(ARCH_HAS_SCHED_WAKE_IDLE) > +static int wake_idle(int cpu, struct task_struct *p) > +{ > + cpumask_t tmp; > + struct sched_domain *sd; > + int i; > + > + /* > + * If it is idle, then it is the best cpu to run this task. > + * > + * This cpu is also the best, if it has more than one task already. > + * Siblings must be also busy(in most cases) as they didn't already > + * pickup the extra load from this cpu and hence we need not check > + * sibling runqueue info. This will avoid the checks and cache miss > + * penalities associated with that. > + */ > + if (idle_cpu(cpu) || cpu_rq(cpu)->nr_running > 1) > + return cpu; > + > + for_each_domain(cpu, sd) { > + if (sd->flags & SD_WAKE_IDLE) { > + cpus_and(tmp, sd->span, p->cpus_allowed); > + for_each_cpu_mask(i, tmp) { > + if (idle_cpu(i)) > + return i; ^^^^^^^^^^^^^^^^ Looks like some stuff that was added in 24 was inadvertently lost in the move when you merged the patches up from 23.1-rt11. The attached patch is updated to move the new logic as well. Regards, -Greg