From mboxrd@z Thu Jan 1 00:00:00 1970 From: Anthony Liguori Subject: Re: [PATCH 5 of 5] [kvm powerpc] Report bad GFNs Date: Wed, 21 May 2008 21:47:40 -0500 Message-ID: <4834DECC.8000301@codemonkey.ws> References: <43830c96d3d0b1e6411d.1211412175@localhost.localdomain> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: avi@qumranet.com, kvm@vger.kernel.org, kvm-ppc@vger.kernel.org To: Hollis Blanchard Return-path: Received: from py-out-1112.google.com ([64.233.166.182]:54347 "EHLO py-out-1112.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755243AbYEVCru (ORCPT ); Wed, 21 May 2008 22:47:50 -0400 Received: by py-out-1112.google.com with SMTP id p76so471298pyb.10 for ; Wed, 21 May 2008 19:47:49 -0700 (PDT) In-Reply-To: <43830c96d3d0b1e6411d.1211412175@localhost.localdomain> Sender: kvm-owner@vger.kernel.org List-ID: Hollis Blanchard wrote: > This code shouldn't be hit anyways, but when it is, it's useful to have a > little more information about the failure. > > Signed-off-by: Hollis Blanchard > > diff --git a/arch/powerpc/kvm/44x_tlb.c b/arch/powerpc/kvm/44x_tlb.c > --- a/arch/powerpc/kvm/44x_tlb.c > +++ b/arch/powerpc/kvm/44x_tlb.c > @@ -145,7 +145,7 @@ void kvmppc_mmu_map(struct kvm_vcpu *vcp > down_read(¤t->mm->mmap_sem); > new_page = gfn_to_page(vcpu->kvm, gfn); > if (is_error_page(new_page)) { > - printk(KERN_ERR "Couldn't get guest page!\n"); > + printk(KERN_ERR "Couldn't get guest page for gfn %lx!\n", gfn); > kvm_release_page_clean(new_page); > up_read(¤t->mm->mmap_sem); > return; > FWIW, you should probably rate limit this sort of thing if this is what would get triggered if the guest tried to program the tlb with an invalid gfn. Regards, Anthony Liguori > -- > To unsubscribe from this list: send the line "unsubscribe kvm" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html >