]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
KVM: nVMX: no need to set vcpu->cpu when switching vmcs
authorDavid Hildenbrand <david@redhat.com>
Thu, 24 Aug 2017 18:51:32 +0000 (20:51 +0200)
committerPaolo Bonzini <pbonzini@redhat.com>
Thu, 12 Oct 2017 12:01:52 +0000 (14:01 +0200)
vcpu->cpu is not cleared when doing a vmx_vcpu_put/load, so this can be
dropped.

Reviewed-by: Radim Krčmář <rkrcmar@redhat.com>
Signed-off-by: David Hildenbrand <david@redhat.com>
Signed-off-by: Radim Krčmář <rkrcmar@redhat.com>
arch/x86/kvm/vmx.c

index 40a54649d0d263af0bcec6f267308720e6759a82..8cf506de30c03145b39ca719f056fb2607d25f50 100644 (file)
@@ -9478,7 +9478,6 @@ static void vmx_switch_vmcs(struct kvm_vcpu *vcpu, struct loaded_vmcs *vmcs)
        vmx->loaded_vmcs = vmcs;
        vmx_vcpu_put(vcpu);
        vmx_vcpu_load(vcpu, cpu);
-       vcpu->cpu = cpu;
        put_cpu();
 }