]> git.ipfire.org Git - thirdparty/linux.git/commit
perf/x86/intel/uncore: Add per-scheduler IMC CAS count events
authorZide Chen <zide.chen@intel.com>
Tue, 10 Feb 2026 00:52:25 +0000 (16:52 -0800)
committerPeter Zijlstra <peterz@infradead.org>
Mon, 23 Feb 2026 10:19:25 +0000 (11:19 +0100)
commit6a8a48644c4b804123e59dbfc5d6cd29a0194046
treed8d55cb51e0d730477fd9e1a4fa66b67976e91bd
parent486ff5ad49bc50315bcaf6d45f04a33ef0a45ced
perf/x86/intel/uncore: Add per-scheduler IMC CAS count events

IMC on SPR and EMR does not support sub-channels.  In contrast, CPUs
that use gnr_uncores[] (e.g. Granite Rapids and Sierra Forest)
implement two command schedulers (SCH0/SCH1) per memory channel,
providing logically independent command and data paths.

Do not reuse the spr_uncore_imc[] configuration for these CPUs.
Instead, introduce a dedicated gnr_uncore_imc[] with per-scheduler
events, so userspace can monitor SCH0 and SCH1 independently.

On these CPUs, replace cas_count_{read,write} with
cas_count_{read,write}_sch{0,1}.  This may break existing userspace
that relies on cas_count_{read,write}, prompting it to switch to the
per-scheduler events, as the legacy event reports only partial
traffic (SCH0).

Fixes: 632c4bf6d007 ("perf/x86/intel/uncore: Support Granite Rapids")
Fixes: cb4a6ccf3583 ("perf/x86/intel/uncore: Support Sierra Forest and Grand Ridge")
Reported-by: Reinette Chatre <reinette.chatre@intel.com>
Signed-off-by: Zide Chen <zide.chen@intel.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Reviewed-by: Dapeng Mi <dapeng1.mi@linux.intel.com>
Cc: stable@vger.kernel.org
Link: https://patch.msgid.link/20260210005225.20311-1-zide.chen@intel.com
arch/x86/events/intel/uncore_snbep.c