diff options
author | Sean Christopherson <sean.j.christopherson@intel.com> | 2019-01-25 18:41:20 +0300 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2019-02-21 00:48:18 +0300 |
commit | 4f44c4eec5b72020c6d99e9e4f3d0505874c98c9 (patch) | |
tree | 8e012666bf201b1e18a8055dd0f43b461fe67742 /arch/x86/kvm | |
parent | fc2ba5a27a1aaa16b664e64f85e0e1307d2bde3a (diff) | |
download | linux-4f44c4eec5b72020c6d99e9e4f3d0505874c98c9.tar.xz |
KVM: VMX: Reorder clearing of registers in the vCPU-run assembly flow
Move the clearing of the common registers (not 64-bit-only) to the start
of the flow that clears registers holding guest state. This is
purely a cosmetic change so that the label doesn't point at a blank line
and a #define.
No functional change intended.
Signed-off-by: Sean Christopherson <sean.j.christopherson@intel.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'arch/x86/kvm')
-rw-r--r-- | arch/x86/kvm/vmx/vmenter.S | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/arch/x86/kvm/vmx/vmenter.S b/arch/x86/kvm/vmx/vmenter.S index d325f1d6110b..7b272738c576 100644 --- a/arch/x86/kvm/vmx/vmenter.S +++ b/arch/x86/kvm/vmx/vmenter.S @@ -185,7 +185,12 @@ ENTRY(__vmx_vcpu_run) * free. RSP and RAX are exempt as RSP is restored by hardware during * VM-Exit and RAX is explicitly loaded with 0 or 1 to return VM-Fail. */ -1: +1: xor %ebx, %ebx + xor %ecx, %ecx + xor %edx, %edx + xor %esi, %esi + xor %edi, %edi + xor %ebp, %ebp #ifdef CONFIG_X86_64 xor %r8d, %r8d xor %r9d, %r9d @@ -196,12 +201,6 @@ ENTRY(__vmx_vcpu_run) xor %r14d, %r14d xor %r15d, %r15d #endif - xor %ebx, %ebx - xor %ecx, %ecx - xor %edx, %edx - xor %esi, %esi - xor %edi, %edi - xor %ebp, %ebp /* "POP" @regs. */ add $WORD_SIZE, %_ASM_SP |