提交 585463f0 编写于 作者: V Valentin Schneider 提交者: Yury Norov

sched/core: Merge cpumask_andnot()+for_each_cpu() into for_each_cpu_andnot()

This removes the second use of the sched_core_mask temporary mask.
Suggested-by: NYury Norov <yury.norov@gmail.com>
Signed-off-by: NValentin Schneider <vschneid@redhat.com>
上级 49937cd1
......@@ -360,10 +360,7 @@ static void __sched_core_flip(bool enabled)
/*
* Toggle the offline CPUs.
*/
cpumask_copy(&sched_core_mask, cpu_possible_mask);
cpumask_andnot(&sched_core_mask, &sched_core_mask, cpu_online_mask);
for_each_cpu(cpu, &sched_core_mask)
for_each_cpu_andnot(cpu, cpu_possible_mask, cpu_online_mask)
cpu_rq(cpu)->core_enabled = enabled;
cpus_read_unlock();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册