From: Tejun Heo <tj@kernel.org>
To: Cheng-Yang Chou <yphbchou0911@gmail.com>
Cc: sched-ext@lists.linux.dev, David Vernet <void@manifault.com>,
Andrea Righi <arighi@nvidia.com>,
Changwoo Min <changwoo@igalia.com>,
Ching-Chun Huang <jserv@ccns.ncku.edu.tw>,
Chia-Ping Tsai <chia7712@gmail.com>,
chengyang.chou@mediatek.com, stable@vger.kernel.org,
JaeJoon Jung <rgbi3307@gmail.com>
Subject: Re: [PATCH sched_ext/for-7.4-fixes] sched_ext: Don't request private stacks the JIT can't provide
Date: Tue, 24 Nov 2026 04:22:51 -1000 [thread overview]
Message-ID: <c7245b367e0ab9ff71222607749b7b6c@kernel.org> (raw)
In-Reply-To: <20261123145450.12725-2-yphbchou0911@gmail.com>
Applied to sched_ext/for-7.4-fixes with the following changes:
- bpf_scx_check_member() wraps the switch in an if block instead of
returning early, which made the function fragile.
--- a/kernel/sched/ext/ext.c
+++ b/kernel/sched/ext/ext.c
@@ -9308,15 +9308,17 @@ static int bpf_scx_check_member(const struct btf_type *t,
* sub-scheds and sub-scheds themselves but I don't know how to access
* struct_ops from here.
*/
- switch (moff) {
- case offsetof(struct sched_ext_ops, dispatch):
- prog->aux->priv_stack_requested = true;
- prog->aux->recursion_detected = scx_pstack_recursion_on_dispatch;
- break;
- case offsetof(struct sched_ext_ops, sub_caps_updated):
- prog->aux->priv_stack_requested = true;
- prog->aux->recursion_detected = scx_pstack_recursion_on_caps_updated;
- break;
+ if (bpf_jit_supports_private_stack()) {
+ switch (moff) {
+ case offsetof(struct sched_ext_ops, dispatch):
+ prog->aux->priv_stack_requested = true;
+ prog->aux->recursion_detected = scx_pstack_recursion_on_dispatch;
+ break;
+ case offsetof(struct sched_ext_ops, sub_caps_updated):
+ prog->aux->priv_stack_requested = true;
+ prog->aux->recursion_detected = scx_pstack_recursion_on_caps_updated;
+ break;
+ }
}
#endif /* CONFIG_EXT_SUB_SCHED */
Thanks.
--
tejun
prev parent reply other threads:[~2026-11-24 14:22 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-23 14:54 [PATCH sched_ext/for-7.4-fixes] sched_ext: Don't request private stacks the JIT can't provide Cheng-Yang Chou
2026-11-24 9:43 ` Andrea Righi
2026-11-24 14:22 ` Tejun Heo [this message]
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=c7245b367e0ab9ff71222607749b7b6c@kernel.org \
--to=tj@kernel.org \
--cc=arighi@nvidia.com \
--cc=changwoo@igalia.com \
--cc=chengyang.chou@mediatek.com \
--cc=chia7712@gmail.com \
--cc=jserv@ccns.ncku.edu.tw \
--cc=rgbi3307@gmail.com \
--cc=sched-ext@lists.linux.dev \
--cc=stable@vger.kernel.org \
--cc=void@manifault.com \
--cc=yphbchou0911@gmail.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