[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250617083059.GL1613376@noisy.programming.kicks-ass.net>
Date: Tue, 17 Jun 2025 10:30:59 +0200
From: Peter Zijlstra <peterz@...radead.org>
To: Tejun Heo <tj@...nel.org>
Cc: David Vernet <void@...ifault.com>, Andrea Righi <arighi@...dia.com>,
Changwoo Min <changwoo@...lia.com>, linux-kernel@...r.kernel.org,
Ingo Molnar <mingo@...hat.com>
Subject: Re: [PATCH 2/2 sched_ext/for-6.16-fixes] sched_ext, sched/core:
Don't call scx_group_set_weight() prematurely from sched_create_group()
On Fri, Jun 13, 2025 at 01:25:56PM -1000, Tejun Heo wrote:
> During task_group creation, sched_create_group() calls
> scx_group_set_weight() with CGROUP_WEIGHT_DFL to initialize the sched_ext
> portion. This is premature and ends up calling ops.cgroup_set_weight() with
> an incorrect @cgrp before ops.cgroup_init() is called.
>
> sched_create_group() should just initialize SCX related fields in the new
> task_group. Fix it by factoring out scx_tg_init() from sched_init() and
> making sched_create_group() call that function instead of
> scx_group_set_weight().
>
> Signed-off-by: Tejun Heo <tj@...nel.org>
> Fixes: 819513666966 ("sched_ext: Add cgroup support")
> Cc: stable@...r.kernel.org # v6.12+
> ---
> Ingo, Peter, while this touches kernel/sched/core.c, the changes are trivial
> and only affect sched_ext. I'm planning to route it through
> sched_ext/for-6.14-fixes. Please holler if you want it routed through tip.
Seems fine, go ahead and take it.
Powered by blists - more mailing lists