From cbe59d40a2f3b64e0e91835dc8d2c4ee0896f458 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 4fce0949b0f4..4c5ff40ccdc9 100644 --- a/arch/arm64/kvm/hyp/nvhe/hyp-main.c +++ b/arch/arm64/kvm/hyp/nvhe/hyp-main.c @@ -1328,7 +1328,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;