diff options
| author | Peter Zijlstra <peterz@infradead.org> | 2026-06-26 09:36:52 +0200 |
|---|---|---|
| committer | Peter Zijlstra <peterz@infradead.org> | 2026-06-30 10:56:51 +0200 |
| commit | fa02b2868420d9f33d64ddcb15ef0f96880b2a6d (patch) | |
| tree | 4019d2e6adae97444ef7af81c248ca9344f0bfee /tools/perf/scripts/python | |
| parent | dc59e4fea9d83f03bad6bddf3fa2e52491777482 (diff) | |
sched/core: Fix inter-class wakeup_preempt()
The way wakeup_preempt() works since commit 704069649b5b ("sched/core: Rework
sched_class::wakeup_preempt() and rq_modified_*()") is that it will call
rq->next_class->wakeup_preempt(rq, p) when p is of an equal or higher class,
and raise ->next_class when higher.
This means that:
running idle task
wakeup fair-A
(next_class == idle)
if (sched_class_above(fair, idle)) {
wakeup_preempt_idle(fair-A);
resched_curr(rq);
next_class = fair;
}
wakeup fair-B
(next_class == fair)
if (fair == fair)
wakeup_preempt_fair(fair-B);
(but current is idle)
All wakeup_preempt_$class() methods, except for wakeup_preempt_scx() (for whoem
this was build) ignore cross-class wakeups by testing if @p is of the right
class, but per the above case, it also should check current.
This is mostly harmless in the current form, but will lead to trouble with
later patches.
Fixes: 704069649b5b ("sched/core: Rework sched_class::wakeup_preempt() and rq_modified_*()")
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://patch.msgid.link/20260626074605.GB2568396%40noisy.programming.kicks-ass.net
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions
