浏览代码

KVM: MMU: Flush tlbs after clearing write permission when accessing dirty log

Otherwise, the cpu may allow writes to the tracked pages, and we lose
some display bits or fail to migrate correctly.

Signed-off-by: Avi Kivity <avi@qumranet.com>
Avi Kivity 17 年之前
父节点
当前提交
171d595d3b
共有 1 个文件被更改,包括 1 次插入0 次删除
  1. 1 0
      arch/x86/kvm/mmu.c

+ 1 - 0
arch/x86/kvm/mmu.c

@@ -2111,6 +2111,7 @@ void kvm_mmu_slot_remove_write_access(struct kvm *kvm, int slot)
 			if (pt[i] & PT_WRITABLE_MASK)
 				pt[i] &= ~PT_WRITABLE_MASK;
 	}
+	kvm_flush_remote_tlbs(kvm);
 	spin_unlock(&kvm->mmu_lock);
 }