Re: [RFC PATCH v7 00/29] Hierarchical Constant Bandwidth Server

From: luca abeni

Date: Fri Nov 27 2026 - 09:29:04 EST


On Thu, 26 Nov 2026 17:33:57 +0100
Juri Lelli <juri.lelli@xxxxxxxxxx> wrote:
[...]
> > > The mixed config ends up on P because of _delegation_. P's
> > > cpu.rt.max belongs to whoever delegated P, and it's what bounds
> > > how much the container can reserve. The application only arranges
> > > its threads below it. If a cgroup had to be "all or nothing", the
> > > admin would have to give P either zero on CPUs 0-3 (no RT threads
> > > there at all, not very flexible) or a budget there (reserving DL
> > > bandwidth for threads that don't need it).
> >
> > Uhm... In my original "all of nothing" idea, my plan was not to set
> > cpu.rt.max in P, and to set it only in P/crit. In this way, the RT
> > threads in P/nocrit should be served by P's parent (up to the root),
> > while the RT threads in P/crit are directly served by the dl servers
> > configured in P/crit/cpu.rt.max.
> >
> > Would this solution address the requirements of this use-case?
>
> If the admin configures the whole tree, yes, I think so.

Thanks, Juri, this (who is responsible for setting cpu.rt.max) is the
point I was missing... Now I better understand the example and the
requirements.


Luca


> In my understanding, it doesn't if P is delegated, though. Moving
> threads between P/noncrit and P/crit needs write access to P (the
> common ancestor), so P is what the container gets. P's own cpu.rt.max
> then stays with the admin, while P/crit's is the container's to
> write. With P at "max", nothing bounds what the container can reserve
> in P/crit, other than what's left at the nearest configured ancestor
> (or the root).
>
> So the admin has to put the cap on P. If P also had to carry entries
> on CPUs 0-3, P/noncrit would be served by P there: with zero its RT
> threads couldn't run at all, and with a budget they'd use a
> reservation they don't need. Leaving P without entries on 0-3 (i.e.
> the mixed config) is what lets them keep running as plain FIFO, as
> they do today.
>