From: Tejun Heo <tj@kernel.org>
To: sched-ext@lists.linux.dev
Cc: David Vernet <void@manifault.com>,
Andrea Righi <arighi@nvidia.com>,
Changwoo Min <changwoo@igalia.com>,
Emil Tsalapatis <emil@etsalapatis.com>,
David Dai <david.dai@linux.dev>,
linux-kernel@vger.kernel.org, Tejun Heo <tj@kernel.org>
Subject: [PATCHSET sched_ext/for-7.3-fixes] sched_ext: Fix bypass propagation and the bypass dispatch claim for overlapping bypasses
Date: Sun, 11 Oct 2026 11:40:26 -1000 [thread overview]
Message-ID: <20261011214028.743546-1-tj@kernel.org> (raw)
Hello,
scx_bypass() propagates a bypass to the descendants, and claims bypass
dispatch on the host, only when the scheduler's own depth crosses zero. A
sub-scheduler's own bypass that overlaps an ancestor's then misses both: its
descendants drop out of bypass early, and its claim is leaked or never
taken. A PM suspend over a sub-scheduler's enable trips the WARN_ON_ONCE()
in enable_bypass_dsp() on the next bypass, and one over a disable leaves its
tasks on the parent's bypass DSQs with nobody consuming them.
Patch 1 propagates every depth change so that a descendant's depth is the
sum of its own and its ancestors' bypasses. Patch 2 claims and releases
bypass dispatch for the propagated descendants too.
Verified with a debug patch holding a sub-scheduler's enable bypass open
across PM suspend cycles: every suspend landed inside it, the unfixed kernel
trips the WARN on the following disable and the fixed one does not, with the
sub-scheduler's tasks running after each resume. The claim protocol across
the PM notifier, sub-scheduler enable and disable and root disable was
model-checked with TLC, including the sequences fixed here.
Based on sched_ext/for-7.3-fixes (069403dff337).
This patchset contains the following 2 patches.
0001 sched_ext: Propagate every bypass depth change to the descendants
0002 sched_ext: Fix the bypass dispatch claim for schedulers bypassed by an ancestor
The patchset is also available in the following git branch:
git://git.kernel.org/pub/scm/linux/kernel/git/tj/sched_ext.git bypass-claim-fixes
diffstat follows. Thanks.
kernel/sched/ext/ext.c | 54 ++++++++++++++++++++++++++++++--------------------
1 file changed, 33 insertions(+), 21 deletions(-)
--
tejun
next reply other threads:[~2026-10-11 21:40 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-11 21:40 Tejun Heo [this message]
2026-10-11 21:40 ` [PATCH 1/2] sched_ext: Propagate every bypass depth change to the descendants Tejun Heo
2026-10-11 21:40 ` [PATCH 2/2] sched_ext: Fix the bypass dispatch claim for schedulers bypassed by an ancestor Tejun Heo
2026-10-12 18:11 ` [PATCHSET sched_ext/for-7.3-fixes] sched_ext: Fix bypass propagation and the bypass dispatch claim for overlapping bypasses Andrea Righi
2026-10-12 18:40 ` Tejun Heo
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261011214028.743546-1-tj@kernel.org \
--to=tj@kernel.org \
--cc=arighi@nvidia.com \
--cc=changwoo@igalia.com \
--cc=david.dai@linux.dev \
--cc=emil@etsalapatis.com \
--cc=linux-kernel@vger.kernel.org \
--cc=sched-ext@lists.linux.dev \
--cc=void@manifault.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®