Izik Eidus wrote:
Marcelo Tosatti wrote:


/* Free page dirty bitmap if unneeded */
-    if (!(new.flags & KVM_MEM_LOG_DIRTY_PAGES))
+    if (!(new.flags & KVM_MEM_LOG_DIRTY_PAGES)) {
         new.dirty_bitmap = NULL;
+        if (old.flags & KVM_MEM_LOG_DIRTY_PAGES)
+            kvm_arch_flush_shadow(kvm);
+    }

Whats this for?

We have added all this SPTE_DONT_DIRTY..., when we stop dirty bit tracking, we want to continue setting the dirty bit for the spte inside set_spte(), so writing to the page would be faster....

Another way would be doing something like kvm_arch_clean_dont_dirty(), might be better than flushing the whole shadow page tables.

--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to