Re: [PATCH RFC] KVM MMU: fix hashing for TDP and non-paging modes

2010-04-27 Thread Marcelo Tosatti
On Mon, Apr 26, 2010 at 05:00:05PM -0700, Eric Northup wrote: On Mon, Apr 26, 2010 at 2:46 PM, Marcelo Tosatti mtosa...@redhat.com wrote: Doh, and your patch does not. But it does not apply to kvm.git -next branch, can you regenerate please? -- For TDP mode, avoid creating multiple page

Re: [PATCH RFC] KVM MMU: fix hashing for TDP and non-paging modes

2010-04-26 Thread Avi Kivity
On 04/23/2010 02:11 PM, Avi Kivity wrote: All feedback would be welcome, since I'm new to this system! A strawman patch follows. Patch is correct, but I have already fixed this in a more extensive patch set (that also folds the 32-bit and 64-bit cases together, etc.) and I'm too lazy to

Re: [PATCH RFC] KVM MMU: fix hashing for TDP and non-paging modes

2010-04-26 Thread Marcelo Tosatti
On Thu, Apr 22, 2010 at 02:15:14PM -0700, Eric Northup wrote: I've been reading the x86's mmu.c recently and had been wondering about something. Avi's recent mmu documentation (thanks!) seems to have confirmed my understanding of how the shadow paging is supposed to be working. In TDP mode,

Re: [PATCH RFC] KVM MMU: fix hashing for TDP and non-paging modes

2010-04-26 Thread Marcelo Tosatti
On Mon, Apr 26, 2010 at 06:30:00PM -0300, Marcelo Tosatti wrote: @@ -2089,6 +2089,10 @@ static int mmu_alloc_roots(struct kvm_vcpu *vcpu) root_gfn = 0; if (mmu_check_root(vcpu, root_gfn)) return 1; + if

Re: [PATCH RFC] KVM MMU: fix hashing for TDP and non-paging modes

2010-04-26 Thread Eric Northup
On Mon, Apr 26, 2010 at 2:46 PM, Marcelo Tosatti mtosa...@redhat.com wrote: Doh, and your patch does not. But it does not apply to kvm.git -next branch, can you regenerate please? -- For TDP mode, avoid creating multiple page table roots for the single guest-to-host physical address map by

Re: [PATCH RFC] KVM MMU: fix hashing for TDP and non-paging modes

2010-04-23 Thread Avi Kivity
On 04/23/2010 12:15 AM, Eric Northup wrote: I've been reading the x86's mmu.c recently and had been wondering about something. Avi's recent mmu documentation (thanks!) seems to have confirmed my understanding of how the shadow paging is supposed to be working. Wasn't it a lot more fun to

[PATCH RFC] KVM MMU: fix hashing for TDP and non-paging modes

2010-04-22 Thread Eric Northup
I've been reading the x86's mmu.c recently and had been wondering about something. Avi's recent mmu documentation (thanks!) seems to have confirmed my understanding of how the shadow paging is supposed to be working. In TDP mode, when mmu_alloc_roots() calls kvm_mmu_get_page(), why does it pass