]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/blobdiff - arch/x86/kvm/vmx/vmenter.S
KVM: VMX: Pass @launched to the vCPU-run asm via standard ABI regs
[mirror_ubuntu-jammy-kernel.git] / arch / x86 / kvm / vmx / vmenter.S
index 7d8b09abcdecd87895be7be07053735c39064f88..a3d9a8e062f960376cd5f84b84a121905d2eaa4f 100644 (file)
@@ -84,7 +84,7 @@ ENDPROC(vmx_vmexit)
  * __vmx_vcpu_run - Run a vCPU via a transition to VMX guest mode
  * @vmx:       struct vcpu_vmx *
  * @regs:      unsigned long * (to guest registers)
- * %RBX:       VMCS launched status (non-zero indicates already launched)
+ * @launched:  %true if the VMCS has been launched
  *
  * Returns:
  *     %RBX is 0 on VM-Exit, 1 on VM-Fail
@@ -99,6 +99,9 @@ ENTRY(__vmx_vcpu_run)
         */
        push %_ASM_ARG2
 
+       /* Copy @launched to BL, _ASM_ARG3 is volatile. */
+       mov %_ASM_ARG3B, %bl
+
        /* Adjust RSP to account for the CALL to vmx_vmenter(). */
        lea -WORD_SIZE(%_ASM_SP), %_ASM_ARG2
        call vmx_update_host_rsp