[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <aN6pU3aBYT5V81jE@jlelli-thinkpadt14gen4.remote.csb>
Date: Thu, 2 Oct 2025 17:33:23 +0100
From: Juri Lelli <juri.lelli@...hat.com>
To: Yuri Andriaccio <yurand2000@...il.com>
Cc: Ingo Molnar <mingo@...hat.com>, Peter Zijlstra <peterz@...radead.org>,
Vincent Guittot <vincent.guittot@...aro.org>,
Dietmar Eggemann <dietmar.eggemann@....com>,
Steven Rostedt <rostedt@...dmis.org>,
Ben Segall <bsegall@...gle.com>, Mel Gorman <mgorman@...e.de>,
Valentin Schneider <vschneid@...hat.com>,
linux-kernel@...r.kernel.org,
Luca Abeni <luca.abeni@...tannapisa.it>,
Yuri Andriaccio <yuri.andriaccio@...tannapisa.it>
Subject: Re: [RFC PATCH v3 07/24] sched/core: Initialize root_task_group
Hello,
On 29/09/25 11:22, Yuri Andriaccio wrote:
> From: luca abeni <luca.abeni@...tannapisa.it>
>
> Add the initialization function for task_group's dl_servers.
> Initialize the default bandwidth for rt-cgroups and the root control group.
> Add utility functions to check (and get) if a rt_rq entity is connected to a
> real-time cgroup.
It's a bit of a nit, but this patch does quite more than $SUBJECT. So,
I'd say please either reword $SUBJECT or consider splitting it further.
...
> @@ -3077,6 +3078,21 @@ static inline struct rq *rq_of_rt_se(struct sched_rt_entity *rt_se)
> WARN_ON(!rt_group_sched_enabled() && rt_rq->tg != &root_task_group);
> return rt_rq->rq;
> }
> +
> +static inline int is_dl_group(struct rt_rq *rt_rq)
> +{
> + return rt_rq->tg != &root_task_group;
> +}
> +
> +/*
> + * Return the scheduling entity of this group of tasks.
> + */
> +static inline struct sched_dl_entity *dl_group_of(struct rt_rq *rt_rq)
> +{
> + BUG_ON(!is_dl_group(rt_rq));
BUG_ON() should generally be avoided, if possible. Could a
WARN_ON_ONCE() plus returning NULL work here?
> +
> + return rt_rq->tg->dl_se[cpu_of(rt_rq->rq)];
> +}
Thanks,
Juri
Powered by blists - more mailing lists