lkml.org 
[lkml]   [2022]   [May]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [RFC PATCH] arch_topology: Use llc_id instead of package_id
From
On 13/05/2022 11:03, Sudeep Holla wrote:
> On Fri, May 13, 2022 at 10:34:00AM +0200, Dietmar Eggemann wrote:

[...]

>> @@ -527,7 +528,8 @@ static int __init parse_core(struct device_node *core, int package_id,
>> return -EINVAL;
>> }
>>
>> - cpu_topology[cpu].package_id = package_id;
>> + cpu_topology[cpu].package_id = 0;
>
> While the above looks good and matches with what I am attempting to do
> as well ...
>
>> + cpu_topology[cpu].llc_id = llc_id;
>
> This looks wrong for simple reason that this is derived incorrectly from
> the cpu-map while there is no guarantee that it matches the last level
> cache ID on the system as we didn't parse the cache topology for this.
> So I disagree with this change as it might conflict with the actual and
> correct llc_id.

It might not match the LLC, that's true. Something we have already today
in Android for DynamIQ clusters with big/Little. People using 1. level
clusters to group CPUs according to uArch.

My point is we manage to get:

SMT - cpu_smt_mask()
CLS - cpu_clustergroup_mask()
MC - cpu_coregroup_mask()
DIE - cpu_cpu_mask()

covered in ACPI with the cpu_topology[] structure and if we want CLS on
DT we have to save cluster_id for the 2. level (DT) cluster.

And that's why I proposed to (ab)use llc_id to form the MC mask.

I'm not currently aware of another solution to get CLS somehow elegantly
into a DT system.

\
 
 \ /
  Last update: 2022-05-13 12:43    [W:0.307 / U:0.064 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site