[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <5d6c6bd7-2bbd-4040-9a8a-369ec8c2a3a3@intel.com>
Date: Wed, 21 Jan 2026 23:17:39 +0800
From: "Chen, Yu C" <yu.c.chen@...el.com>
To: K Prateek Nayak <kprateek.nayak@....com>
CC: 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>, Shrikanth Hegde
<sshegde@...ux.ibm.com>, "Gautham R. Shenoy" <gautham.shenoy@....com>, "Ingo
Molnar" <mingo@...hat.com>, Peter Zijlstra <peterz@...radead.org>, Juri Lelli
<juri.lelli@...hat.com>, Vincent Guittot <vincent.guittot@...aro.org>,
<linux-kernel@...r.kernel.org>, Tim Chen <tim.c.chen@...el.com>
Subject: Re: [PATCH v3 2/8] sched/topology: Allocate per-CPU
sched_domain_shared in s_data
On 1/20/2026 7:32 PM, K Prateek Nayak wrote:
> The "sched_domain_shared" object is allocated for every topology level
> in __sdt_alloc() and is freed post sched domain rebuild if they aren't
> assigned during sd_init().
>
> "sd->shared" is only assigned for SD_SHARE_LLC domains and out of all
> the assigned objects, only "sd_llc_shared" is ever used by the
> scheduler.
>
> Since only "sd_llc_shared" is ever used, and since SD_SHARE_LLC domains
> never overlap, allocate only a single range of per-CPU
> "sched_domain_shared" object with s_data instead of doing it per
> topology level.
>
> The subsequent commit uses the degeneration path to correctly assign the
> "sd->shared" to the topmost SD_SHARE_LLC domain.
>
> No functional changes are expected at this point.
>
The sched_domain_shared is allocated in s_data and then
immediately released because per_cpu_ptr(d->sds, j) is
not NULL. I guess this is the reason why you mentioned
"No functional changes".
For the cluster domain that shares L2, I suppose we can bring
it back if there is a need in the future.
From my understanding,
Reviewed-by: Chen Yu <yu.c.chen@...el.com>
thanks,
Chenyu
Powered by blists - more mailing lists