From 65ccd1af452a2794eb28dd03376310d042c46a06 Mon Sep 17 00:00:00 2001 From: Vincent Donnefort Date: Thu, 6 Apr 2023 10:48:57 +0100 Subject: [PATCH] ANDROID: KVM: arm64: Fix pKVM module loading close The HVC number limit must be the id inside the enum, not the fully encoded version. Without this fix, all HVC would be rejected after closing the pKVM modules door. Bug: 254835242 Change-Id: Ia338859e07412ea1c2377b90ddee2c29c6fb0755 Signed-off-by: Vincent Donnefort --- arch/arm64/kvm/hyp/nvhe/hyp-main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm64/kvm/hyp/nvhe/hyp-main.c b/arch/arm64/kvm/hyp/nvhe/hyp-main.c index 224ba5d00303..c854d1f674e5 100644 --- a/arch/arm64/kvm/hyp/nvhe/hyp-main.c +++ b/arch/arm64/kvm/hyp/nvhe/hyp-main.c @@ -1327,7 +1327,7 @@ int reset_pkvm_priv_hcall_limit(void) return -EACCES; addr = hyp_fixmap_map(__hyp_pa(&pkvm_priv_hcall_limit)); - *addr = KVM_HOST_SMCCC_FUNC(__pkvm_prot_finalize); + *addr = __KVM_HOST_SMCCC_FUNC___pkvm_prot_finalize; hyp_fixmap_unmap(); return 0;