From: Sudeep Holla <sudeep.holla@arm.com>
To: Dietmar Eggemann <dietmar.eggemann@arm.com>
Cc: linux-kernel@vger.kernel.org, Atish Patra <atishp@atishpatra.org>,
Atish Patra <atishp@rivosinc.com>,
Vincent Guittot <vincent.guittot@linaro.org>,
Morten Rasmussen <morten.rasmussen@arm.com>,
Qing Wang <wangqing@vivo.com>,
linux-arm-kernel@lists.infradead.org,
linux-riscv@lists.infradead.org, Rob Herring <robh+dt@kernel.org>
Subject: Re: [PATCH v3 07/16] arch_topology: Use the last level cache information from the cacheinfo
Date: Mon, 6 Jun 2022 10:54:15 +0100 [thread overview]
Message-ID: <20220606095415.n26cugm2bo7d3rud@bogus> (raw)
In-Reply-To: <0bf199a0-251d-323c-974a-bfd4e26f4cce@arm.com>
On Thu, Jun 02, 2022 at 04:26:00PM +0200, Dietmar Eggemann wrote:
> On 25/05/2022 10:14, Sudeep Holla wrote:
> > The cacheinfo is now initialised early along with the CPU topology
> > initialisation. Instead of relying on the LLC ID information parsed
> > separately only with ACPI PPTT elsewhere, migrate to use the similar
> > information from the cacheinfo.
> >
> > This is generic for both DT and ACPI systems. The ACPI LLC ID information
> > parsed separately can now be removed from arch specific code.
> >
> > Signed-off-by: Sudeep Holla <sudeep.holla@arm.com>
> > ---
> > drivers/base/arch_topology.c | 5 +++--
> > 1 file changed, 3 insertions(+), 2 deletions(-)
> >
> > diff --git a/drivers/base/arch_topology.c b/drivers/base/arch_topology.c
> > index 765723448b10..4c486e4e6f2f 100644
> > --- a/drivers/base/arch_topology.c
> > +++ b/drivers/base/arch_topology.c
> > @@ -663,7 +663,8 @@ const struct cpumask *cpu_coregroup_mask(int cpu)
> > /* not numa in package, lets use the package siblings */
> > core_mask = &cpu_topology[cpu].core_sibling;
> > }
> > - if (cpu_topology[cpu].llc_id != -1) {
> > +
> > + if (last_level_cache_is_valid(cpu)) {
> > if (cpumask_subset(&cpu_topology[cpu].llc_sibling, core_mask))
> > core_mask = &cpu_topology[cpu].llc_sibling;
> > }
> > @@ -694,7 +695,7 @@ void update_siblings_masks(unsigned int cpuid)
> > for_each_online_cpu(cpu) {
> > cpu_topo = &cpu_topology[cpu];
> >
> > - if (cpu_topo->llc_id != -1 && cpuid_topo->llc_id == cpu_topo->llc_id) {
> > + if (last_level_cache_is_shared(cpu, cpuid)) {
> > cpumask_set_cpu(cpu, &cpuid_topo->llc_sibling);
> > cpumask_set_cpu(cpuid, &cpu_topo->llc_sibling);
> > }
>
> I tested v3 on a Kunpeng920 (w/o CONFIG_NUMA) and it looks
> like that last_level_cache_is_shared() isn't working as
> expected.
>
Thanks a lot for detailed instrumentation, I am unable to identify why it is
not working though. I will take a deeper look later.
--
Regards,
Sudeep
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2022-06-06 9:56 UTC|newest]
Thread overview: 51+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-25 8:14 [PATCH v3 00/16] arch_topology: Updates to add socket support and fix cluster ids Sudeep Holla
2022-05-25 8:14 ` [PATCH v3 01/16] cacheinfo: Use of_cpu_device_node_get instead cpu_dev->of_node Sudeep Holla
2022-05-25 8:14 ` [PATCH v3 02/16] cacheinfo: Add helper to access any cache index for a given CPU Sudeep Holla
2022-05-25 8:14 ` [PATCH v3 03/16] cacheinfo: Move cache_leaves_are_shared out of CONFIG_OF Sudeep Holla
2022-05-25 8:14 ` [PATCH v3 04/16] cacheinfo: Add support to check if last level cache(LLC) is valid or shared Sudeep Holla
2022-05-25 8:14 ` [PATCH v3 05/16] cacheinfo: Allow early detection and population of cache attributes Sudeep Holla
2022-05-25 8:14 ` [PATCH v3 06/16] arch_topology: Add support to parse and detect " Sudeep Holla
2022-05-25 8:14 ` [PATCH v3 07/16] arch_topology: Use the last level cache information from the cacheinfo Sudeep Holla
2022-05-25 8:14 ` [PATCH v3 08/16] arm64: topology: Remove redundant setting of llc_id in CPU topology Sudeep Holla
2022-05-25 8:14 ` [PATCH v3 09/16] arch_topology: Drop LLC identifier stash from the " Sudeep Holla
2022-05-25 8:14 ` [PATCH v3 10/16] arch_topology: Set thread sibling cpumask only within the cluster Sudeep Holla
2022-05-25 8:14 ` [PATCH v3 11/16] arch_topology: Check for non-negative value rather than -1 for IDs validity Sudeep Holla
2022-05-25 8:14 ` [PATCH v3 12/16] arch_topology: Avoid parsing through all the CPUs once a outlier CPU is found Sudeep Holla
2022-05-25 8:14 ` [PATCH v3 13/16] arch_topology: Don't set cluster identifier as physical package identifier Sudeep Holla
2022-05-25 8:14 ` [PATCH v3 14/16] arch_topology: Drop unnecessary check for uninitialised package_id Sudeep Holla
2022-05-25 8:14 ` [PATCH v3 15/16] arch_topology: Set cluster identifier in each core/thread from /cpu-map Sudeep Holla
2022-05-25 8:14 ` [PATCH v3 16/16] arch_topology: Add support for parsing sockets in /cpu-map Sudeep Holla
2022-06-03 12:30 ` [PATCH v3 15/16] arch_topology: Set cluster identifier in each core/thread from /cpu-map Dietmar Eggemann
2022-06-06 10:21 ` Sudeep Holla
2022-06-10 10:08 ` Vincent Guittot
2022-06-10 10:27 ` Sudeep Holla
2022-06-13 9:19 ` Dietmar Eggemann
2022-06-13 11:17 ` Sudeep Holla
2022-06-16 16:02 ` Dietmar Eggemann
2022-06-17 11:16 ` Sudeep Holla
2022-06-20 13:27 ` Dietmar Eggemann
2022-06-21 16:00 ` Sudeep Holla
2022-06-14 17:59 ` Vincent Guittot
2022-06-15 17:00 ` Sudeep Holla
2022-06-15 22:44 ` Vincent Guittot
2022-06-15 22:45 ` Vincent Guittot
2022-06-01 3:40 ` [PATCH v3 12/16] arch_topology: Avoid parsing through all the CPUs once a outlier CPU is found Gavin Shan
2022-06-01 3:38 ` [PATCH v3 11/16] arch_topology: Check for non-negative value rather than -1 for IDs validity Gavin Shan
2022-06-01 3:36 ` [PATCH v3 10/16] arch_topology: Set thread sibling cpumask only within the cluster Gavin Shan
2022-06-01 3:35 ` [PATCH v3 09/16] arch_topology: Drop LLC identifier stash from the CPU topology Gavin Shan
2022-06-01 12:06 ` Sudeep Holla
2022-06-02 6:44 ` Gavin Shan
2022-06-02 6:42 ` Gavin Shan
2022-06-02 6:42 ` [PATCH v3 08/16] arm64: topology: Remove redundant setting of llc_id in " Gavin Shan
2022-06-01 3:31 ` [PATCH v3 07/16] arch_topology: Use the last level cache information from the cacheinfo Gavin Shan
2022-06-02 14:26 ` Dietmar Eggemann
2022-06-06 9:54 ` Sudeep Holla [this message]
2022-06-01 3:29 ` [PATCH v3 06/16] arch_topology: Add support to parse and detect cache attributes Gavin Shan
2022-06-01 3:25 ` [PATCH v3 05/16] cacheinfo: Allow early detection and population of " Gavin Shan
2022-06-01 3:20 ` [PATCH v3 04/16] cacheinfo: Add support to check if last level cache(LLC) is valid or shared Gavin Shan
2022-06-01 2:51 ` [PATCH v3 03/16] cacheinfo: Move cache_leaves_are_shared out of CONFIG_OF Gavin Shan
2022-06-01 2:44 ` [PATCH v3 02/16] cacheinfo: Add helper to access any cache index for a given CPU Gavin Shan
2022-06-01 12:45 ` Sudeep Holla
2022-06-01 2:45 ` [PATCH v3 01/16] cacheinfo: Use of_cpu_device_node_get instead cpu_dev->of_node Gavin Shan
2022-06-01 3:49 ` [PATCH v3 00/16] arch_topology: Updates to add socket support and fix cluster ids Gavin Shan
2022-06-01 12:03 ` Sudeep Holla
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=20220606095415.n26cugm2bo7d3rud@bogus \
--to=sudeep.holla@arm.com \
--cc=atishp@atishpatra.org \
--cc=atishp@rivosinc.com \
--cc=dietmar.eggemann@arm.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-riscv@lists.infradead.org \
--cc=morten.rasmussen@arm.com \
--cc=robh+dt@kernel.org \
--cc=vincent.guittot@linaro.org \
--cc=wangqing@vivo.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