[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20090329125041.GI31080@8bytes.org>
Date: Sun, 29 Mar 2009 14:50:41 +0200
From: Joerg Roedel <joro@...tes.org>
To: Avi Kivity <avi@...hat.com>
Cc: Joerg Roedel <joerg.roedel@....com>,
Marcelo Tosatti <mtosatti@...hat.com>, kvm@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH] kvm mmu: add support for 1GB pages in shadow paging
code
On Sun, Mar 29, 2009 at 02:59:26PM +0300, Avi Kivity wrote:
> Joerg Roedel wrote:
>> return write_protected;
>> }
>> @@ -789,11 +797,14 @@ static int kvm_handle_hva(struct kvm *kvm,
>> unsigned long hva,
>> if (hva >= start && hva < end) {
>> gfn_t gfn_offset = (hva - start) >> PAGE_SHIFT;
>> unsigned long lidx = gfn_offset / KVM_PAGES_PER_2M_PAGE;
>> + unsigned long hidx = gfn_offset / KVM_PAGES_PER_1G_PAGE;
>> retval |= handler(kvm, &memslot->rmap[gfn_offset],
>> KVM_PAGE_SIZE_4k);
>> retval |= handler(kvm,
>> &memslot->lpage_info[lidx].rmap_pde,
>> KVM_PAGE_SIZE_2M);
>> + retval |= handler(kvm, &memslot->hpage_info[hidx].rmap_pde,
>> + KVM_PAGE_SIZE_1G);
>> }
>> }
>>
>
> Isn't this needed for tdp as well?
Hmm, yes. But it may be no problem not doing it because large pages are
never swapped out. Anyway, I will move this to the tdp patch
Joerg
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists