Skip to content

Commit 51cc5fa

Browse files
ouptonjannau
authored andcommitted
arm64: Enable IMP DEF PMUv3 traps on Apple M1
Apple M1 CPUs support IMPDEF traps of the PMUv3 sysregs, allowing a hypervisor to virtualize an architectural PMU for a VM. Flip the appropriate bit in HACR_EL2 on supporting hardware. Signed-off-by: Oliver Upton <oliver.upton@linux.dev> Signed-off-by: Janne Grunau <j@jannau.net>
1 parent 5bcc4de commit 51cc5fa

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

arch/arm64/kernel/cpu_errata.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,12 @@ has_neoverse_n1_erratum_1542419(const struct arm64_cpu_capabilities *entry,
195195
}
196196

197197
static const struct midr_range impdef_pmuv3_cpus[] = {
198+
MIDR_ALL_VERSIONS(MIDR_APPLE_M1_ICESTORM),
199+
MIDR_ALL_VERSIONS(MIDR_APPLE_M1_FIRESTORM),
200+
MIDR_ALL_VERSIONS(MIDR_APPLE_M1_ICESTORM_PRO),
201+
MIDR_ALL_VERSIONS(MIDR_APPLE_M1_FIRESTORM_PRO),
202+
MIDR_ALL_VERSIONS(MIDR_APPLE_M1_ICESTORM_MAX),
203+
MIDR_ALL_VERSIONS(MIDR_APPLE_M1_FIRESTORM_MAX),
198204
MIDR_ALL_VERSIONS(MIDR_APPLE_M2_BLIZZARD),
199205
MIDR_ALL_VERSIONS(MIDR_APPLE_M2_AVALANCHE),
200206
MIDR_ALL_VERSIONS(MIDR_APPLE_M2_BLIZZARD_PRO),

0 commit comments

Comments
 (0)