From: Rob Herring <robh@kernel.org>
To: Alexander Shishkin <alexander.shishkin@linux.intel.com>,
Ingo Molnar <mingo@redhat.com>,
Catalin Marinas <catalin.marinas@arm.com>,
Peter Zijlstra <peterz@infradead.org>,
Mark Rutland <mark.rutland@arm.com>,
Will Deacon <will@kernel.org>, Jiri Olsa <jolsa@kernel.org>,
Namhyung Kim <namhyung@kernel.org>,
Arnaldo Carvalho de Melo <acme@kernel.org>
Cc: linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
linux-perf-users@vger.kernel.org
Subject: [PATCH RFC v1 1/3] perf: arm_spe: Support new SPEv1.2/v8.7 'not taken' event
Date: Thu, 25 Aug 2022 13:08:00 -0500 [thread overview]
Message-ID: <20220825-arm-spe-v8-7-v1-1-c75b8d92e692@kernel.org> (raw)
In-Reply-To: <20220825-arm-spe-v8-7-v1-0-c75b8d92e692@kernel.org>
Arm SPEv1.2 (Armv8.7/v9.2) adds a new event, 'not taken', in bit 6 of
the PMSEVFR_EL1 register. Update arm_spe_pmsevfr_res0() to support the
additional event.
Signed-off-by: Rob Herring <robh@kernel.org>
diff --git a/arch/arm64/include/asm/sysreg.h b/arch/arm64/include/asm/sysreg.h
index 7c71358d44c4..57904c11aece 100644
--- a/arch/arm64/include/asm/sysreg.h
+++ b/arch/arm64/include/asm/sysreg.h
@@ -312,6 +312,8 @@
BIT_ULL(6) | BIT_ULL(4) | BIT_ULL(2) | BIT_ULL(0))
#define SYS_PMSEVFR_EL1_RES0_8_3 \
(SYS_PMSEVFR_EL1_RES0_8_2 & ~(BIT_ULL(18) | BIT_ULL(17) | BIT_ULL(11)))
+#define SYS_PMSEVFR_EL1_RES0_8_7 \
+ (SYS_PMSEVFR_EL1_RES0_8_3 & ~BIT_ULL(6))
#define SYS_PMSLATFR_EL1 sys_reg(3, 0, 9, 9, 6)
#define SYS_PMSLATFR_EL1_MINLAT_SHIFT 0
@@ -847,6 +849,7 @@
#define ID_AA64DFR0_PMSVER_8_2 0x1
#define ID_AA64DFR0_PMSVER_8_3 0x2
+#define ID_AA64DFR0_PMSVER_8_7 0x3
#define ID_DFR0_PERFMON_SHIFT 24
diff --git a/drivers/perf/arm_spe_pmu.c b/drivers/perf/arm_spe_pmu.c
index b65a7d9640e1..a75b03b5c8f9 100644
--- a/drivers/perf/arm_spe_pmu.c
+++ b/drivers/perf/arm_spe_pmu.c
@@ -677,9 +677,11 @@ static u64 arm_spe_pmsevfr_res0(u16 pmsver)
case ID_AA64DFR0_PMSVER_8_2:
return SYS_PMSEVFR_EL1_RES0_8_2;
case ID_AA64DFR0_PMSVER_8_3:
+ return SYS_PMSEVFR_EL1_RES0_8_3;
+ case ID_AA64DFR0_PMSVER_8_7:
/* Return the highest version we support in default */
default:
- return SYS_PMSEVFR_EL1_RES0_8_3;
+ return SYS_PMSEVFR_EL1_RES0_8_7;
}
}
--
b4 0.10.0-dev
next prev parent reply other threads:[~2022-08-25 18:08 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-08-25 18:07 [PATCH RFC v1 0/3] perf: Arm SPEv1.2 support Rob Herring
2022-08-25 18:08 ` Rob Herring [this message]
2022-08-25 18:08 ` [PATCH RFC v1 2/3] perf: Add perf_event_attr::config3 Rob Herring
2022-08-25 19:31 ` Arnaldo Carvalho de Melo
2022-08-25 19:43 ` Rob Herring
2022-08-25 19:53 ` Arnaldo Carvalho de Melo
2022-08-31 19:06 ` Rob Herring
2022-08-31 20:07 ` Arnaldo Carvalho de Melo
2022-08-25 18:08 ` [PATCH RFC v1 3/3] perf: arm_spe: Add support for SPEv1.2 inverted event filtering Rob Herring
2022-09-05 14:55 ` James Clark
2022-09-06 13:48 ` Rob Herring
2022-09-12 8:53 ` Leo Yan
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=20220825-arm-spe-v8-7-v1-1-c75b8d92e692@kernel.org \
--to=robh@kernel.org \
--cc=acme@kernel.org \
--cc=alexander.shishkin@linux.intel.com \
--cc=catalin.marinas@arm.com \
--cc=jolsa@kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-perf-users@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=mingo@redhat.com \
--cc=namhyung@kernel.org \
--cc=peterz@infradead.org \
--cc=will@kernel.org \
/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;
as well as URLs for NNTP newsgroup(s).