From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [patch 2/5] KVM: MMU: make for_each_shadow_entry aware of largepages Date: Wed, 10 Jun 2009 12:15:02 +0300 Message-ID: <4A2F7996.8020805@redhat.com> References: <20090609213009.436123773@amt.cnet> <20090609213312.750051328@amt.cnet> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: kvm@vger.kernel.org, sheng.yang@intel.com To: Marcelo Tosatti Return-path: Received: from mx2.redhat.com ([66.187.237.31]:60571 "EHLO mx2.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757464AbZFJJPD (ORCPT ); Wed, 10 Jun 2009 05:15:03 -0400 In-Reply-To: <20090609213312.750051328@amt.cnet> Sender: kvm-owner@vger.kernel.org List-ID: Marcelo Tosatti wrote: > This way there is no need to add explicit checks in every > for_each_shadow_entry user. > > Signed-off-by: Marcelo Tosatti > > Index: kvm/arch/x86/kvm/mmu.c > =================================================================== > --- kvm.orig/arch/x86/kvm/mmu.c > +++ kvm/arch/x86/kvm/mmu.c > @@ -1273,6 +1273,11 @@ static bool shadow_walk_okay(struct kvm_ > { > if (iterator->level < PT_PAGE_TABLE_LEVEL) > return false; > + > + if (iterator->level == PT_PAGE_TABLE_LEVEL) > + if (is_large_pte(*iterator->sptep)) > + return false; > > s/==/>/? -- error compiling committee.c: too many arguments to function