|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [xen master] x86/vmx: Correct the declaration of vmx_asm_vmexit_handler()
commit 43e1387130dfbf201c3bf50c8967ad117a994754
Author: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
AuthorDate: Thu Feb 23 11:57:48 2023 +0000
Commit: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
CommitDate: Fri Feb 24 17:44:29 2023 +0000
x86/vmx: Correct the declaration of vmx_asm_vmexit_handler()
Taking struct cpu_user_regs as a full object is bogus, and while what was
probably meant was to take a struct cpu_user_regs pointer, that's still
wrong.
This isn't a function; its an address stored in the VMCS that the CPU
resumes
from on VMExit, meaning that it doesn't conform to a normal C API/ABI.
Annotate it with `nocall`, and move the declaration into vmcs.c next to its
sole user.
Fixes: 9c3118a82523 ("bitkeeper revision 1.1159.1.483
(41c0c417XYObowWqbfqU0cdLx30C9w)")
`-> "Initial Intel VMX support"
Reported-by: Jan Beulich <JBeulich@xxxxxxxx>
Signed-off-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
Reviewed-by: Jan Beulich <jbeulich@xxxxxxxx>
---
xen/arch/x86/hvm/vmx/vmcs.c | 2 ++
xen/arch/x86/include/asm/hvm/vmx/vmx.h | 1 -
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/xen/arch/x86/hvm/vmx/vmcs.c b/xen/arch/x86/hvm/vmx/vmcs.c
index e1c268789e..ed71ecfb62 100644
--- a/xen/arch/x86/hvm/vmx/vmcs.c
+++ b/xen/arch/x86/hvm/vmx/vmcs.c
@@ -1074,6 +1074,8 @@ static void pi_desc_init(struct vcpu *v)
v->arch.hvm.vmx.pi_desc.ndst = APIC_INVALID_DEST;
}
+void nocall vmx_asm_vmexit_handler(void);
+
static int construct_vmcs(struct vcpu *v)
{
struct domain *d = v->domain;
diff --git a/xen/arch/x86/include/asm/hvm/vmx/vmx.h
b/xen/arch/x86/include/asm/hvm/vmx/vmx.h
index 97d6b810ec..f6308ed656 100644
--- a/xen/arch/x86/include/asm/hvm/vmx/vmx.h
+++ b/xen/arch/x86/include/asm/hvm/vmx/vmx.h
@@ -82,7 +82,6 @@ typedef enum {
#define PI_xAPIC_NDST_MASK 0xFF00
-void vmx_asm_vmexit_handler(struct cpu_user_regs);
void vmx_intr_assist(void);
void noreturn cf_check vmx_do_resume(void);
void cf_check vmx_vlapic_msr_changed(struct vcpu *v);
--
generated by git-patchbot for /home/xen/git/xen.git#master
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |