From: kan.liang@linux.intel.com
To: peterz@infradead.org, mingo@redhat.com, linux-kernel@vger.kernel.org
Cc: artem.bityutskiy@linux.intel.com, rui.zhang@intel.com,
Kan Liang <kan.liang@linux.intel.com>
Subject: [RESEND PATCH 4/4] perf/x86/intel/cstate: Add Grand Ridge support
Date: Thu, 16 Nov 2023 06:22:45 -0800 [thread overview]
Message-ID: <20231116142245.1233485-4-kan.liang@linux.intel.com> (raw)
In-Reply-To: <20231116142245.1233485-1-kan.liang@linux.intel.com>
From: Kan Liang <kan.liang@linux.intel.com>
The same as the Sierra Forest, the Grand Ridge supports core C1/C6 and
module C6. But it doesn't support pkg C6 residency counter.
Signed-off-by: Kan Liang <kan.liang@linux.intel.com>
---
arch/x86/events/intel/cstate.c | 15 ++++++++++++---
1 file changed, 12 insertions(+), 3 deletions(-)
diff --git a/arch/x86/events/intel/cstate.c b/arch/x86/events/intel/cstate.c
index 4a46ef315284..4b50a3a9818a 100644
--- a/arch/x86/events/intel/cstate.c
+++ b/arch/x86/events/intel/cstate.c
@@ -41,7 +41,7 @@
* MSR_CORE_C1_RES: CORE C1 Residency Counter
* perf code: 0x00
* Available model: SLM,AMT,GLM,CNL,ICX,TNT,ADL,RPL
- * MTL,SRF
+ * MTL,SRF,GRR
* Scope: Core (each processor core has a MSR)
* MSR_CORE_C3_RESIDENCY: CORE C3 Residency Counter
* perf code: 0x01
@@ -52,7 +52,8 @@
* perf code: 0x02
* Available model: SLM,AMT,NHM,WSM,SNB,IVB,HSW,BDW,
* SKL,KNL,GLM,CNL,KBL,CML,ICL,ICX,
- * TGL,TNT,RKL,ADL,RPL,SPR,MTL,SRF
+ * TGL,TNT,RKL,ADL,RPL,SPR,MTL,SRF,
+ * GRR
* Scope: Core
* MSR_CORE_C7_RESIDENCY: CORE C7 Residency Counter
* perf code: 0x03
@@ -99,7 +100,7 @@
* Scope: Package (physical package)
* MSR_MODULE_C6_RES_MS: Module C6 Residency Counter.
* perf code: 0x00
- * Available model: SRF
+ * Available model: SRF,GRR
* Scope: A cluster of cores shared L2 cache
*
*/
@@ -677,6 +678,13 @@ static const struct cstate_model glm_cstates __initconst = {
BIT(PERF_CSTATE_PKG_C10_RES),
};
+static const struct cstate_model grr_cstates __initconst = {
+ .core_events = BIT(PERF_CSTATE_CORE_C1_RES) |
+ BIT(PERF_CSTATE_CORE_C6_RES),
+
+ .module_events = BIT(PERF_CSTATE_MODULE_C6_RES),
+};
+
static const struct cstate_model srf_cstates __initconst = {
.core_events = BIT(PERF_CSTATE_CORE_C1_RES) |
BIT(PERF_CSTATE_CORE_C6_RES),
@@ -739,6 +747,7 @@ static const struct x86_cpu_id intel_cstates_match[] __initconst = {
X86_MATCH_INTEL_FAM6_MODEL(ATOM_TREMONT_L, &glm_cstates),
X86_MATCH_INTEL_FAM6_MODEL(ATOM_GRACEMONT, &adl_cstates),
X86_MATCH_INTEL_FAM6_MODEL(ATOM_CRESTMONT_X, &srf_cstates),
+ X86_MATCH_INTEL_FAM6_MODEL(ATOM_CRESTMONT, &grr_cstates),
X86_MATCH_INTEL_FAM6_MODEL(ICELAKE_L, &icl_cstates),
X86_MATCH_INTEL_FAM6_MODEL(ICELAKE, &icl_cstates),
--
2.35.1
next prev parent reply other threads:[~2023-11-16 14:23 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-11-16 14:22 [RESEND PATCH 1/4] perf/x86/intel/cstate: Cleanup duplicate attr_groups kan.liang
2023-11-16 14:22 ` [RESEND PATCH 2/4] x86/smp: Export symbol cpu_clustergroup_mask kan.liang
2023-11-16 14:40 ` Peter Zijlstra
2023-11-16 15:20 ` Liang, Kan
2023-11-20 14:35 ` [tip: perf/core] x86/smp: Export symbol cpu_clustergroup_mask() tip-bot2 for Kan Liang
2023-11-16 14:22 ` [RESEND PATCH 3/4] perf/x86/intel/cstate: Add Sierra Forest support kan.liang
2023-11-20 14:35 ` [tip: perf/core] " tip-bot2 for Kan Liang
2023-11-16 14:22 ` kan.liang [this message]
2023-11-20 14:35 ` [tip: perf/core] perf/x86/intel/cstate: Add Grand Ridge support tip-bot2 for Kan Liang
2023-11-20 14:35 ` [tip: perf/core] perf/x86/intel/cstate: Cleanup duplicate attr_groups tip-bot2 for Kan Liang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20231116142245.1233485-4-kan.liang@linux.intel.com \
--to=kan.liang@linux.intel.com \
--cc=artem.bityutskiy@linux.intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=peterz@infradead.org \
--cc=rui.zhang@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox