Re: [PATCH 2/2] kvm: change the dirty page tracking to work with dirty bity

2009-06-11 Thread Ulrich Drepper
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Izik Eidus wrote: + if (!kvm_x86_ops-dirty_bit_support()) { + spin_lock(kvm-mmu_lock); + /* remove_write_access() flush the tlb */ + kvm_mmu_slot_remove_write_access(kvm,

Re: [PATCH 2/2] kvm: change the dirty page tracking to work with dirty bity

2009-06-11 Thread Izik Eidus
Avi Kivity wrote: Izik Eidus wrote: change the dirty page tracking to work with dirty bity instead of page fault. right now the dirty page tracking work with the help of page faults, when we want to track a page for being dirty, we write protect it and we mark it dirty when we have write page

Re: [PATCH 2/2] kvm: change the dirty page tracking to work with dirty bity

2009-06-11 Thread Avi Kivity
Izik Eidus wrote: Avi Kivity wrote: Izik Eidus wrote: change the dirty page tracking to work with dirty bity instead of page fault. right now the dirty page tracking work with the help of page faults, when we want to track a page for being dirty, we write protect it and we mark it dirty when

Re: [PATCH 2/2] kvm: change the dirty page tracking to work with dirty bity

2009-06-11 Thread Marcelo Tosatti
On Thu, Jun 11, 2009 at 02:27:46PM +0300, Izik Eidus wrote: Marcelo Tosatti wrote: What i'm saying is with shadow and NPT (i believe) you can mark a spte writable but not dirty, which gives you the ability to know whether certain pages have been dirtied. Isnt this what this patch is

Re: [PATCH 2/2] kvm: change the dirty page tracking to work with dirty bity

2009-06-10 Thread Izik Eidus
Izik Eidus wrote: +static int vmx_dirty_bit_support(void) +{ + return false; +} + Again, idiotic bug: this should be: return tdp_enable == false; ... -- To unsubscribe from this list: send the line unsubscribe kvm in the body of a message to majord...@vger.kernel.org More

Re: [PATCH 2/2] kvm: change the dirty page tracking to work with dirty bity

2009-06-10 Thread Marcelo Tosatti
On Wed, Jun 10, 2009 at 07:23:25PM +0300, Izik Eidus wrote: change the dirty page tracking to work with dirty bity instead of page fault. right now the dirty page tracking work with the help of page faults, when we want to track a page for being dirty, we write protect it and we mark it dirty

Re: [PATCH 2/2] kvm: change the dirty page tracking to work with dirty bity

2009-06-10 Thread Izik Eidus
Marcelo Tosatti wrote: On Wed, Jun 10, 2009 at 07:23:25PM +0300, Izik Eidus wrote: change the dirty page tracking to work with dirty bity instead of page fault. right now the dirty page tracking work with the help of page faults, when we want to track a page for being dirty, we write protect

Re: [PATCH 2/2] kvm: change the dirty page tracking to work with dirty bity

2009-06-10 Thread Izik Eidus
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) +