Re: [PATCH v10 16/40] sched/deadline: Keep the last CPU a task has in its root domain
From: Mathieu Desnoyers
Date: Mon Nov 23 2026 - 08:59:38 EST
> When gone is set and p was initially unpopulated with no active CPUs of
> its own, does partition_child_lost() pick the last valid sibling
> partition after gone instead of the first?
Yes. cpuset invalidates the siblings after gone in the order of its
hotplug walk, until one gives p an active CPU. The model picked the last
sibling that covers the CPUs left. With mixed partition types, a
deadline task could then change root domain unadmitted.
Your second, fourth and fifth points come from the same model. So v11
will stop modelling the order of the walk. Take a partition left with
tasks and no CPU, under a parent with no CPU of its own. The parent can
also stay valid with tasks and no CPU. A later hotplug event can then
make it invalid. So v11 will take the topmost partition above that
child that has no CPU of its own. The offline will be refused if a
deadline task is in one of its cpusets. That can refuse an offline that
would be harmless. Three new cases will test it:
hotplug_first_sibling_refused (your first point),
hotplug_nested_partition_refused (your second) and
hotplug_isolated_child_refused (your fourth).
One hole stays. The check sees the deadline tasks present at the
offline. A deadline task can enter such a partition after an accepted
offline. A later hotplug event can then move it to another root domain
with no check for room. v11 will list it as a known limit.
> Can gone cascade upward across an unpopulated parent partition here and
> in cpuset_offline_moves_dl()?
Yes. But that climb refused a real move, by luck. A later hotplug
event can make cpuset invalidate the parent left valid with no CPU. In
v11, cpuset_offline_moves_dl() will climb on purpose, as above.
cpuset_cpus_allowed_without() will climb one level at most.
> Does dl_task_in_cpuset() match sugov kthreads in top_cpuset that do not
> hold root-domain deadline bandwidth?
Yes. In v11, it will skip a task whose bandwidth no root domain counts,
with a new dl_task_holds_bw(). It needs schedutil, so no case will test
it.
> Can deadline tasks in gone change root domain undetected when gone is an
> isolated partition and its parent p is a non-isolated partition?
Yes. The rule above refuses it. hotplug_isolated_child_refused will
test it.
> Does skipping a == lost when neither lost nor p is PRS_ISOLATED hold when
> lost has a valid child partition of its own?
The root domain of p does span lost's exclusive CPUs, not only its
effective ones. But the bandwidth that moves was all admitted on fewer
CPUs, so nothing is overcommitted. The child partitions of lost are
checked on their own. v11 will correct the comment and the message,
which said "the same CPUs".
Thanks,
Mathieu
--
Mathieu Desnoyers
EfficiOS Inc.
https://www.efficios.com