KVM: nVMX: no need to set vcpu->cpu when switching vmcs
authorDavid Hildenbrand <[email protected]>
Thu, 24 Aug 2017 18:51:32 +0000 (20:51 +0200)
committerPaolo Bonzini <[email protected]>
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ář <[email protected]>
Signed-off-by: David Hildenbrand <[email protected]>
Signed-off-by: Radim Krčmář <[email protected]>
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();
 }