summaryrefslogtreecommitdiffstats
path: root/arch/x86/kvm/mmu.c
diff options
context:
space:
mode:
authorSheng Yang <sheng@linux.intel.com>2009-07-09 17:00:42 +0800
committerAvi Kivity <avi@redhat.com>2009-09-10 08:33:14 +0300
commit3662cb1cd6ed26873ca808f3e16cc54246ad40ca (patch)
treeecc11fa956e94cd3599f1bf5998ab54528f3fba1 /arch/x86/kvm/mmu.c
parent4088bb3caee82086fd85a844604274f6237f66a7 (diff)
downloadop-kernel-dev-3662cb1cd6ed26873ca808f3e16cc54246ad40ca.zip
op-kernel-dev-3662cb1cd6ed26873ca808f3e16cc54246ad40ca.tar.gz
KVM: Discard unnecessary kvm_mmu_flush_tlb() in kvm_mmu_load()
set_cr3() should already cover the TLB flushing. Signed-off-by: Sheng Yang <sheng@linux.intel.com> Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
Diffstat (limited to 'arch/x86/kvm/mmu.c')
-rw-r--r--arch/x86/kvm/mmu.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c
index f1f0815..87c67f4 100644
--- a/arch/x86/kvm/mmu.c
+++ b/arch/x86/kvm/mmu.c
@@ -2373,8 +2373,8 @@ int kvm_mmu_load(struct kvm_vcpu *vcpu)
spin_unlock(&vcpu->kvm->mmu_lock);
if (r)
goto out;
+ /* set_cr3() should ensure TLB has been flushed */
kvm_x86_ops->set_cr3(vcpu, vcpu->arch.mmu.root_hpa);
- kvm_mmu_flush_tlb(vcpu);
out:
return r;
}
OpenPOWER on IntegriCloud