diff options
| author | Tejun Heo <tj@kernel.org> | 2026-10-05 07:52:12 -1000 |
|---|---|---|
| committer | Tejun Heo <tj@kernel.org> | 2026-10-06 14:34:40 -1000 |
| commit | 457fff158adcd2a60f2a908957e193cb78649dbf (patch) | |
| tree | c831ecf9f022535f2a4d26b255412b047f21af39 /tools/perf/scripts/python/bin | |
| parent | a546831dff38b624240a90a6ff6d2b43d9226d51 (diff) | |
sched_ext: Add ops.sub_cid_sched_updated() to report the sched running on a cid
A parent sched that delegates cpus to sub-scheds has no way of telling how
much each delegatee is using them. A parent that sizes its delegations by
demand cannot measure it, and one that wants to hand a cid from one sub to
another cannot see which sub it would take the cid from.
Add ops.sub_cid_sched_updated(), invoked on a sched when what it sees
running on a cid changes: NONE when no task of its subtree runs there, SELF
for its own task, or a direct child's cgroup id. Changes inside a child's
subtree are not reported.
The op costs one pointer compare per context switch when the sched does not
change, a notification reaches only the scheds that see a change, and the
whole mechanism sits behind a static key that is on only while a loaded
sched implements the op. After a sched's tasks are gone, its disable closes
every rq session still pointing at it, so nothing refers to it once it is
freed.
The op is cid-form only like the other sub ops and runs with the rq lock
held on the context switch path.
Signed-off-by: Tejun Heo <tj@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/bin')
0 files changed, 0 insertions, 0 deletions
