1
0
Fork 0
mirror of synced 2025-03-06 20:59:54 +01:00

sched_ext: idle: use assign_cpu() to update the idle cpumask

Use the assign_cpu() helper to set or clear the CPU in the idle mask,
based on the idle condition.

Acked-by: Yury Norov <yury.norov@gmail.com>
Signed-off-by: Andrea Righi <arighi@nvidia.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
This commit is contained in:
Andrea Righi 2024-12-28 11:02:50 +01:00 committed by Tejun Heo
parent bc3a116a44
commit 9cf9aceed2

View file

@ -3654,10 +3654,7 @@ void __scx_update_idle(struct rq *rq, bool idle)
return;
}
if (idle)
cpumask_set_cpu(cpu, idle_masks.cpu);
else
cpumask_clear_cpu(cpu, idle_masks.cpu);
assign_cpu(cpu, idle_masks.cpu, idle);
#ifdef CONFIG_SCHED_SMT
if (sched_smt_active()) {