Re: [PATCH 2/4] sched_ext: Make SCX_OPS_ENQ_BLOCKED a hierarchy-wide setting
From: Andrea Righi
Date: Sat Nov 28 2026 - 11:39:53 EST
Hi Tejun,
On Fri, Nov 27, 2026 at 10:29:43AM -1000, Tejun Heo wrote:
> Hello, Andrea.
>
> On Thu, Nov 26, 2026 at 12:13:58PM +0100, Andrea Righi wrote:
> > Mixing proxy donor admission within a hierarchy has no real use, so
> > don't allow it: a sub-scheduler must match the root scheduler's
> > SCX_OPS_ENQ_BLOCKED setting or it fails to load.
>
> Does the match need to go both ways? If the root sets SCX_OPS_ENQ_BLOCKED,
> proxy execution is on and every sub-sched needs the flag too. However, when
> the root doesn't set it, I don't see why a sub-sched which sets it can't be
> loaded. Proxy execution can just stay disabled.
Right, a sub-sched setting SCX_OPS_ENQ_BLOCKED under a root that doesn't
is safe, it would just never see SCX_ENQ_BLOCKED. My concern is that
it'd be silent: a sub-sched that opts in and implements donor handling
would load fine and that code would never run, with no indication why.
Maybe we can accept it and pr_warn() that the flag is ignored?
>
> The root alone would then decide whether blocked donors are admitted, and
> scx_allow_proxy_exec() can become a static key which is determined by the
> root sched.
Agreed, I'll convert scx_allow_proxy_exec() to a static key set at root
enable.
Thanks,
-Andrea