From 46f5a40291f2bb0748a3a0d013a79cea16d776d8 Mon Sep 17 00:00:00 2001 From: Krisztian Litkey Date: Thu, 20 Jun 2024 09:47:59 +0300 Subject: [PATCH] cpuallocator: fix CPU cluster discovery. Use the correct die ID instead of the incorrect package ID when querying per package CPU clusters during CPU cluster discovery. Signed-off-by: Krisztian Litkey --- pkg/cpuallocator/allocator.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/cpuallocator/allocator.go b/pkg/cpuallocator/allocator.go index 00cea7e36..4748e79c7 100644 --- a/pkg/cpuallocator/allocator.go +++ b/pkg/cpuallocator/allocator.go @@ -946,7 +946,7 @@ func (c *topologyCache) discoverCPUClusters(sys sysfs.System) { pkg := sys.Package(id) clusters := []*cpuCluster{} for _, die := range pkg.DieIDs() { - for _, cl := range pkg.LogicalDieClusterIDs(id) { + for _, cl := range pkg.LogicalDieClusterIDs(die) { if cpus := pkg.LogicalDieClusterCPUSet(die, cl); cpus.Size() > 0 { clusters = append(clusters, &cpuCluster{ pkg: id,