]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commit
KVM: VMX: Pass "launched" directly to the vCPU-run asm blob
authorSean Christopherson <sean.j.christopherson@intel.com>
Fri, 25 Jan 2019 15:41:05 +0000 (07:41 -0800)
committerPaolo Bonzini <pbonzini@redhat.com>
Tue, 12 Feb 2019 12:12:24 +0000 (13:12 +0100)
commitc9afc58cc368623aaa34a62e321eea2a59240f6f
tree8c707879bf3e3f280c47340da80bcb8cb0488135
parentc09b03eb7f964370149577fdba425623b7f5b0b5
KVM: VMX: Pass "launched" directly to the vCPU-run asm blob

...and remove struct vcpu_vmx's temporary __launched variable.

Eliminating __launched is a bonus, the real motivation is to get to the
point where the only reference to struct vcpu_vmx in the asm code is
to vcpu.arch.regs, which will simplify moving the blob to a proper asm
file.  Note that also means this approach is deliberately different than
what is used in nested_vmx_check_vmentry_hw().

Use BL as it is a callee-save register in both 32-bit and 64-bit ABIs,
i.e. it can't be modified by vmx_update_host_rsp(), to avoid having to
temporarily save/restore the launched flag.

Signed-off-by: Sean Christopherson <sean.j.christopherson@intel.com>
Reviewed-by: Jim Mattson <jmattson@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/vmx/vmx.c
arch/x86/kvm/vmx/vmx.h