diff options
| author | Tejun Heo <tj@kernel.org> | 2026-10-17 15:59:50 -1000 |
|---|---|---|
| committer | Tejun Heo <tj@kernel.org> | 2026-10-19 10:59:07 -1000 |
| commit | f89d11642c1b573356382f031e3e5eb4fe87166a (patch) | |
| tree | 19caffbb27cd71799ad11c615fcd42fc7ade0f95 /include/linux | |
| parent | 47769db146d90e33107e43e12ca7fc1e2dafbc32 (diff) | |
sched_ext: Deliver ecaps only while the root has the cpu online
A sub-scheduler's ecaps ops run in dispatch context, and ops.cpu_online()
and ops.cpu_offline() document that the cpu doesn't call ops.dispatch()
outside them. The reseed of a cpu coming back is queued before the root's
ops.cpu_online(), so the ops of a sub-scheduler and its parent can run for a
cpu the root still considers offline.
Add SCX_RQ_OPS_ONLINE, set while the root considers the cpu online, from its
ops.cpu_online() or its enable until its ops.cpu_offline(). A sync outside
that span leaves the ecaps alone, and the reseed, now queued after
ops.cpu_online(), reports the net change. SCX_RQ_ONLINE can't be used, as
the core changes it ahead of the root's view on both edges.
A cpu going offline still drops its caps without a report.
While at it, fix the SCX_RQ_ONLINE comments, which claimed that the flag
tracks ops.cpu_online() and ops.cpu_offline().
v2: Fix the SCX_RQ_ONLINE comments.
Signed-off-by: Tejun Heo <tj@kernel.org>
Reviewed-by: Andrea Righi <arighi@nvidia.com>
Diffstat (limited to 'include/linux')
0 files changed, 0 insertions, 0 deletions
