[RFC PATCH v7 09/28] HACK! KVM: arm64: Enable SPE virtualization only in VHE mode
Alexandru Elisei
alexandru.elisei at arm.com
Thu Sep 3 09:06:04 PDT 2026
For RFC only.
Signed-off-by: Alexandru Elisei <alexandru.elisei at arm.com>
---
arch/arm64/kvm/spe.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/arm64/kvm/spe.c b/arch/arm64/kvm/spe.c
index 97160d1fae81..00908aa2576b 100644
--- a/arch/arm64/kvm/spe.c
+++ b/arch/arm64/kvm/spe.c
@@ -22,8 +22,8 @@ void kvm_spe_add_instance(struct arm_spe_pmu *spe_pmu)
{
struct spe_pmu_entry *entry;
- /* TODO: pKVM support */
- if (is_protected_kvm_enabled())
+ /* TODO: pKVM and nVHE support */
+ if (is_protected_kvm_enabled() || !has_vhe())
return;
guard(mutex)(&spe_pmus_lock);
--
2.43.0
More information about the linux-arm-kernel
mailing list