From mboxrd@z Thu Jan 1 00:00:00 1970 From: Held Bernhard Subject: Re: with kerenl 2.6.27, CONFIG_KVM_GUEST does not work Date: Sun, 12 Oct 2008 22:57:05 +0200 Message-ID: References: <519a8b110810100911j2e8229a2mf86f770b724a1bc3@mail.gmail.com> <20081011180436.GA13387@dmt.cnet> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit To: kvm@vger.kernel.org Return-path: Received: from main.gmane.org ([80.91.229.2]:46414 "EHLO ciao.gmane.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752030AbYJLVFE (ORCPT ); Sun, 12 Oct 2008 17:05:04 -0400 Received: from root by ciao.gmane.org with local (Exim 4.43) id 1Kp87b-0005Cj-4A for kvm@vger.kernel.org; Sun, 12 Oct 2008 21:05:03 +0000 Received: from p5b07f3d7.dip.t-dialin.net ([91.7.243.215]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 12 Oct 2008 21:05:03 +0000 Received: from berny156 by p5b07f3d7.dip.t-dialin.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 12 Oct 2008 21:05:03 +0000 In-Reply-To: <20081011180436.GA13387@dmt.cnet> Sender: kvm-owner@vger.kernel.org List-ID: > Does the attached work for you? > > Avi, do you have thoughts on how to proceed with pvmmu? Using hypercalls > instead of faults can still be beneficial (for the first write before > page goes out of sync, or for non-leaf tables which currently don't go > oos). But at the current state pvmmu should be slower in most loads. > Perhaps disable it? > > KVM: MMU: sync root on paravirt TLB flush > > The pvmmu TLB flush handler should request a root sync, similarly to > a native read-write CR3. > > Signed-off-by: Marcelo Tosatti > > diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c > index 79cb4a9..7e70e97 100644 > --- a/arch/x86/kvm/mmu.c > +++ b/arch/x86/kvm/mmu.c > @@ -2747,6 +2747,7 @@ static int kvm_pv_mmu_write(struct kvm_vcpu *vcpu, > static int kvm_pv_mmu_flush_tlb(struct kvm_vcpu *vcpu) > { > kvm_x86_ops->tlb_flush(vcpu); > + set_bit(KVM_REQ_MMU_SYNC, &vcpu->requests); > return 1; > } This patch works for me (kvm-77, 2.6.27 host and guest)! kvm-75 works fine, but kvm-76 and kvm-77 (all unpatched) show lot's of segfaults in the guest (2.6.26.5 or 2.6.27, x86_64 on host and guest). Thanks for the patch! HTH, Bernhard