From 42a42417a6dbce1a566c2f96e840ca7397cc2a3a Mon Sep 17 00:00:00 2001 From: Mostafa Saleh Date: Mon, 10 Apr 2023 21:49:24 +0000 Subject: [PATCH] ANDROID: KVM: arm64: Add getters for SMCCC args 4-6 SMCCCv1.1 can have up to 6 args, but there were no getters for args 4-6. This patch adds the missing getters. Bug: 357781595 Bug: 348382247 Bug: 236685427 Change-Id: I99d06bd7a91da102f62355e373475a906384c87b Signed-off-by: Mostafa Saleh --- include/kvm/arm_hypercalls.h | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/include/kvm/arm_hypercalls.h b/include/kvm/arm_hypercalls.h index 2df152207ccd..a5fcbca03c1a 100644 --- a/include/kvm/arm_hypercalls.h +++ b/include/kvm/arm_hypercalls.h @@ -28,6 +28,21 @@ static inline unsigned long smccc_get_arg3(struct kvm_vcpu *vcpu) return vcpu_get_reg(vcpu, 3); } +static inline unsigned long smccc_get_arg4(struct kvm_vcpu *vcpu) +{ + return vcpu_get_reg(vcpu, 4); +} + +static inline unsigned long smccc_get_arg5(struct kvm_vcpu *vcpu) +{ + return vcpu_get_reg(vcpu, 5); +} + +static inline unsigned long smccc_get_arg6(struct kvm_vcpu *vcpu) +{ + return vcpu_get_reg(vcpu, 6); +} + static inline void smccc_set_retval(struct kvm_vcpu *vcpu, unsigned long a0, unsigned long a1,