Re: [PATCH v5 20/29] cgroup/cpuset: Give back the bandwidth an attach did not move

From: Juri Lelli

Date: Fri Nov 13 2026 - 12:59:27 EST


On 13/11/26 08:12, Mathieu Desnoyers wrote:

...

> Three new patches keep a deadline task in the root domain that counts
> its bandwidth:
> - Where a CPU is picked for the task, a CPU of that root domain is
> tried first. This covers a CPU offline, a mask change, a wakeup and
> a rebuild.
> - A CPU offline fails with EBUSY if it takes the last CPU the task has
> in that root domain.
> - A write to cpuset.cpus fails with EBUSY if it leaves the task no CPU
> in that root domain. cpuset makes a partition root that would do the
> same invalid.

Makes sense to me.

> The bandwidth of a task then goes to another root domain only by a
> cpuset attach, which asks for room.
>
> With admission control off, nothing is refused, and patch 23 still
> moves the bandwidth. So an administrator gets past a refusal by writing
> -1 to sched_rt_runtime_us. The two refusals are new behaviour for
> user-space. I would like your opinion on them, and on whether that knob
> is enough or a dedicated one is wanted.

I believe we already have (maybe broken in-kernel) EBUSY on trying to
hotplug last cpu with bw standing?

About a potential dedicate knob, Sebastian is proposing it as well [1],
so maybe it's time we move to that. Need to sync with him I guess. :)

Thanks,
Juri

1 - https://lore.kernel.org/lkml/20261113-sched_dl-v3-5-a76ffa1cdeee@xxxxxxxxxxxxx/