Sched_ext development
 help / color / mirror / Atom feed
From: Andrea Righi <arighi@nvidia.com>
To: Peter Zijlstra <peterz@infradead.org>
Cc: Juri Lelli <juri.lelli@redhat.com>, Tejun Heo <tj@kernel.org>,
	David Vernet <void@manifault.com>,
	Changwoo Min <changwoo@igalia.com>,
	Ingo Molnar <mingo@redhat.com>,
	Vincent Guittot <vincent.guittot@linaro.org>,
	Dietmar Eggemann <dietmar.eggemann@arm.com>,
	Steven Rostedt <rostedt@goodmis.org>,
	Ben Segall <bsegall@google.com>, Mel Gorman <mgorman@suse.de>,
	Valentin Schneider <vschneid@redhat.com>,
	K Prateek Nayak <kprateek.nayak@amd.com>,
	Christian Loehle <christian.loehle@arm.com>,
	Phil Auld <pauld@redhat.com>, Koba Ko <kobak@nvidia.com>,
	Joel Fernandes <joelagnelf@nvidia.com>,
	Richard Cheng <icheng@nvidia.com>,
	Cheng-Yang Chou <yphbchou0911@gmail.com>,
	sched-ext@lists.linux.dev, linux-kernel@vger.kernel.org
Subject: Re: [PATCHSET v3 sched_ext/for-7.2] sched_ext: Auto-manage ext/fair dl_server bandwidth
Date: Thu, 28 May 2026 18:13:10 +0200	[thread overview]
Message-ID: <ahhplv6a6etqcF4p@gpd4> (raw)
In-Reply-To: <20260528113317.GD3493090@noisy.programming.kicks-ass.net>

Hi Peter,

On Thu, May 28, 2026 at 01:33:17PM +0200, Peter Zijlstra wrote:
> On Wed, May 27, 2026 at 02:36:18PM +0200, Juri Lelli wrote:
> > Hi Andrea,
> > 
> > On 26/05/26 18:42, Andrea Righi wrote:
> > > Currently, a fixed bandwidth is reserved at boot for both the fair and ext
> > > deadline servers, and this reservation remains unchanged unless explicitly
> > > modified via debugfs. As a result, both servers permanently contribute to global
> > > bandwidth accounting, regardless of whether a BPF scheduler is active.
> > > 
> > > While unused bandwidth can still be reclaimed at runtime by other classes, this
> > > static reservation prevents RT from fully utilizing available headroom in
> > > situations where one of the sched_ext or fair class is guaranteed to be inactive
> > > (for example, when no BPF scheduler is loaded, or when sched_ext runs in full
> > > mode and replaces fair).
> > > 
> > > As discussed at the VIII OSPM summit in Cambridge [1], a better solution would
> > > be to dynamically register and unregister deadline server bandwidth based on the
> > > active sched_ext state. This allows the kernel to automatically enable bandwidth
> > > accounting only for the scheduling class that is currently active, while
> > > disabling it for inactive ones.
> > > 
> > > This patch series implements this automatic register/unregister logic. Moreover,
> > > the sched_ext total_bw kselftest is also modified to validate the correct
> > > behavior across the different scheduling configurations and ensure that
> > > bandwidth accounting follows the expected state transitions.
> > > 
> > > [1] https://retis.santannapisa.it/ospm-summit/
> > > 
> > > Git tree: git://git.kernel.org/pub/scm/linux/kernel/git/arighi/linux.git dl-server-bw-v3
> > > 
> > > Changes in v3:
> > >  - Don't bypass __dl_overflow() for detached servers in dl_server_apply_params()
> > >    to reject oversized configs up front (reported by Sashiko)
> > >  - A potential divide-by-zero in dl_server_apply_params() reported by Sashiko
> > >    has been fixed in a separate patch (not introduced by this patch set):
> > >    https://lore.kernel.org/all/20260526100502.575774-1-arighi@nvidia.com/
> > >  - Link to v2: https://lore.kernel.org/all/20260526082954.550958-1-arighi@nvidia.com/
> > 
> > This looks now good to me.
> > 
> > Acked-by: Juri Lelli <juri.lelli@redhat.com>
> 
> Thanks!, I've stuck them in queue:sched/core for the robots to chew on.
> There was an absolutely trivial reject in ext.c that I fixed up, so
> something moved around there.

FYI, I re-ran all my tests with queue:sched/core, everything looks good on my
side.

Thanks,
-Andrea

  reply	other threads:[~2026-05-28 16:13 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-05-26 16:42 [PATCHSET v3 sched_ext/for-7.2] sched_ext: Auto-manage ext/fair dl_server bandwidth Andrea Righi
2026-05-26 16:42 ` [PATCH 1/2] sched_ext: Auto-register/unregister dl_server reservations Andrea Righi
2026-05-26 17:14   ` sashiko-bot
2026-05-28 11:36   ` Peter Zijlstra
2026-05-28 16:13     ` Andrea Righi
2026-05-26 16:42 ` [PATCH 2/2] selftests/sched_ext: Validate dl_server attach/detach in total_bw test Andrea Righi
2026-05-26 17:33   ` sashiko-bot
2026-05-27 12:36 ` [PATCHSET v3 sched_ext/for-7.2] sched_ext: Auto-manage ext/fair dl_server bandwidth Juri Lelli
2026-05-28 11:33   ` Peter Zijlstra
2026-05-28 16:13     ` Andrea Righi [this message]
2026-05-28 15:53 ` Tejun Heo
2026-05-29  9:08   ` Peter Zijlstra

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=ahhplv6a6etqcF4p@gpd4 \
    --to=arighi@nvidia.com \
    --cc=bsegall@google.com \
    --cc=changwoo@igalia.com \
    --cc=christian.loehle@arm.com \
    --cc=dietmar.eggemann@arm.com \
    --cc=icheng@nvidia.com \
    --cc=joelagnelf@nvidia.com \
    --cc=juri.lelli@redhat.com \
    --cc=kobak@nvidia.com \
    --cc=kprateek.nayak@amd.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mgorman@suse.de \
    --cc=mingo@redhat.com \
    --cc=pauld@redhat.com \
    --cc=peterz@infradead.org \
    --cc=rostedt@goodmis.org \
    --cc=sched-ext@lists.linux.dev \
    --cc=tj@kernel.org \
    --cc=vincent.guittot@linaro.org \
    --cc=void@manifault.com \
    --cc=vschneid@redhat.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