]> www.infradead.org Git - users/jedix/linux-maple.git/commit
KVM: arm64: Drop kvm_arm_pmu_available static key
authorOliver Upton <oliver.upton@linux.dev>
Wed, 5 Mar 2025 20:26:33 +0000 (12:26 -0800)
committerOliver Upton <oliver.upton@linux.dev>
Tue, 11 Mar 2025 19:54:29 +0000 (12:54 -0700)
commita38b67d1518331a4147c52c4fa563846ea0969f9
tree61e203bb4f9c30b457b7a55faf289de4bb4aeefe
parent6f34024d185e2fa6636c660431c4595a6529328d
KVM: arm64: Drop kvm_arm_pmu_available static key

With the PMUv3 cpucap, kvm_arm_pmu_available is no longer used in the
hot path of guest entry/exit. On top of that, guest support for PMUv3
may not correlate with host support for the feature, e.g. on IMPDEF
hardware.

Throw out the static key and just inspect the list of PMUs to determine
if PMUv3 is supported for KVM guests.

Tested-by: Janne Grunau <j@jannau.net>
Reviewed-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20250305202641.428114-7-oliver.upton@linux.dev
Signed-off-by: Oliver Upton <oliver.upton@linux.dev>
arch/arm64/kernel/image-vars.h
arch/arm64/kvm/arm.c
arch/arm64/kvm/pmu-emul.c
include/kvm/arm_pmu.h