Files
linux/include/linux
Qinyun Tan 594902c986 x86,fs/resctrl: Remove inappropriate references to cacheinfo in the resctrl subsystem
In the resctrl subsystem's Sub-NUMA Cluster (SNC) mode, the rdt_mon_domain
structure representing a NUMA node relies on the cacheinfo interface
(rdt_mon_domain::ci) to store L3 cache information (e.g., shared_cpu_map)
for monitoring. The L3 cache information of a SNC NUMA node determines
which domains are summed for the "top level" L3-scoped events.

rdt_mon_domain::ci is initialized using the first online CPU of a NUMA
node. When this CPU goes offline, its shared_cpu_map is cleared to contain
only the offline CPU itself. Subsequently, attempting to read counters
via smp_call_on_cpu(offline_cpu) fails (and error ignored), returning
zero values for "top-level events" without any error indication.

Replace the cacheinfo references in struct rdt_mon_domain and struct
rmid_read with the cacheinfo ID (a unique identifier for the L3 cache).

rdt_domain_hdr::cpu_mask contains the online CPUs associated with that
domain. When reading "top-level events", select a CPU from
rdt_domain_hdr::cpu_mask and utilize its L3 shared_cpu_map to determine
valid CPUs for reading RMID counter via the MSR interface.

Considering all CPUs associated with the L3 cache improves the chances
of picking a housekeeping CPU on which the counter reading work can be
queued, avoiding an unnecessary IPI.

Fixes: 328ea68874 ("x86/resctrl: Prepare for new Sub-NUMA Cluster (SNC) monitor files")
Signed-off-by: Qinyun Tan <qinyuntan@linux.alibaba.com>
Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de>
Reviewed-by: Reinette Chatre <reinette.chatre@intel.com>
Tested-by: Tony Luck <tony.luck@intel.com>
Link: https://lore.kernel.org/20250530182053.37502-2-qinyuntan@linux.alibaba.com
2025-06-16 21:06:12 +02:00
..
2025-04-03 21:35:32 +02:00
2025-05-11 17:54:10 -07:00
2024-10-11 14:34:11 -04:00
2024-10-13 17:16:57 +02:00
2024-10-14 23:27:57 +05:30
2025-02-21 17:31:45 -06:00
2025-02-21 09:54:01 +01:00
2024-11-11 10:45:03 +01:00
2025-04-21 10:27:59 +02:00
2025-04-29 15:58:38 -04:00
2025-04-29 15:58:38 -04:00
2025-04-29 15:58:38 -04:00
2025-05-19 08:17:08 -07:00
2024-10-14 18:33:04 -07:00
2025-04-17 10:50:55 -07:00
2025-03-08 14:37:39 +01:00
2025-02-26 12:10:48 +01:00
2025-05-21 13:41:03 +02:00
2025-05-21 13:39:45 +02:00
2025-02-06 11:27:16 -07:00
2025-03-17 22:06:41 -07:00
2025-04-11 18:58:10 -07:00
2025-05-20 05:34:27 +02:00
2024-11-05 13:32:21 +01:00
2025-04-17 10:56:11 +02:00
2025-02-24 12:08:51 +02:00
2025-04-10 10:39:14 +01:00
2025-05-15 20:24:40 +02:00
2024-11-28 14:49:28 +01:00
2025-05-22 11:07:05 +02:00
2025-01-07 18:06:51 -08:00
2024-11-24 17:05:27 -08:00
2025-03-10 13:13:04 -07:00
2024-10-16 21:56:59 +02:00
2025-06-11 11:57:14 -07:00
2025-01-14 19:45:35 +01:00
2024-12-13 08:49:31 -07:00
2025-03-08 12:13:25 +01:00
2024-12-09 13:48:23 -08:00
2024-10-14 16:33:24 -05:00
2025-05-11 17:48:29 -07:00
2025-02-20 15:24:13 +01:00
2025-02-07 23:15:01 +05:30
2025-03-17 13:54:50 +00:00
2025-06-04 09:51:10 +02:00
2025-02-18 11:51:22 -05:00
2024-11-05 16:56:26 -08:00
2024-11-16 10:09:30 -06:00
2024-10-02 16:23:10 -05:00
2025-05-21 16:46:37 +02:00
2025-04-26 08:28:03 +02:00
2025-03-10 08:53:40 +01:00
2025-05-02 11:03:18 +05:30
2025-03-12 20:41:14 +01:00
2025-01-10 11:59:00 +01:00
2025-01-07 15:16:48 +01:00
2025-03-16 17:40:22 -07:00
2025-01-02 10:37:14 -06:00
2025-05-03 12:02:04 +02:00
2024-12-09 14:44:59 -08:00
2025-05-11 17:54:09 -07:00
2025-05-06 11:11:45 -06:00
2025-03-17 11:52:25 +01:00
2025-04-25 15:53:59 +02:00
2025-04-07 09:36:49 +02:00
2025-01-29 13:32:23 -08:00
2025-04-10 18:34:05 -07:00
2025-02-28 11:51:26 -08:00
2024-10-02 16:53:38 +02:00
2025-05-15 04:49:15 +03:00
2025-03-20 08:00:50 -07:00
2025-02-28 11:51:26 -08:00
2025-02-12 12:12:27 +01:00
2025-04-18 10:05:49 -04:00
2024-12-09 14:44:59 -08:00
2024-11-06 12:59:44 -05:00
2025-03-13 13:25:58 -07:00
2025-03-13 13:25:58 -07:00
2025-03-13 13:25:58 -07:00