Re: [PATCH] sparc: populate sysfs cache topology information on sun4v

From: Stian Halseth

Date: Thu Oct 22 2026 - 12:56:53 EST


Hi Jan,

On Thu, 2026-10-22 at 18:17 +0200, Jan Engelhardt wrote:
> I did not even expect this to do anything sensible on V240.
> That is just an accident - and multicore-per-package (MC)
> sun4u are expected to be still misreported. That needs again
> different logic.

Right, so maybe just return -ENOENT on sun4u and leave it as it is? The
lscpu fallback already gets the single-core ones right.

>
> > Maybe it's simpler to just walk the MD directly in
> > init_cache_level()
> > and populate_cache_leaves(), following the same arcs as
> > fill_in_one_cpu(), and add one leaf per cache node?
>
> After some pondering and in anticipation of MC sun4u, I think
> re-walking is sensible. I expect there to be a few savings
> (just 24 per strand) and a bunch of LOC removals.

Sounds good. I'm happy to test v2 on my T4-1, T7-1 and V240 when it's
ready.

/Stian

Attachment: signature.asc
Description: This is a digitally signed message part