Re: [PATCH 16/18] sched: Avoid overloading CPUs on a preferred NUMA node

From: Hillf Danton
Date: Tue Jul 16 2013 - 11:55:30 EST


On Mon, Jul 15, 2013 at 11:20 PM, Mel Gorman <mgorman@xxxxxxx> wrote:
> +
> +static int task_numa_find_cpu(struct task_struct *p, int nid)
> +{
> + int node_cpu = cpumask_first(cpumask_of_node(nid));
[...]
>
> + /* No harm being optimistic */
> + if (idle_cpu(node_cpu))
> + return node_cpu;
>
[...]
> + for_each_cpu(cpu, cpumask_of_node(nid)) {
> + dst_load = target_load(cpu, idx);
> +
> + /* If the CPU is idle, use it */
> + if (!dst_load)
> + return dst_cpu;
> +
Here you want cpu, instead of dst_cpu, I guess.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/