From mboxrd@z Thu Jan 1 00:00:00 1970 From: Xavier Gnata Subject: Re: with kerenl 2.6.27, CONFIG_KVM_GUEST does not work Date: Tue, 14 Oct 2008 08:49:00 +0200 Message-ID: <48F440DC.9080608@gmail.com> References: <519a8b110810100911j2e8229a2mf86f770b724a1bc3@mail.gmail.com> <20081011180436.GA13387@dmt.cnet> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: QUOTED-PRINTABLE Cc: kvm@vger.kernel.org To: Held Bernhard Return-path: Received: from ik-out-1112.google.com ([66.249.90.181]:37607 "EHLO ik-out-1112.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751535AbYJNGtF (ORCPT ); Tue, 14 Oct 2008 02:49:05 -0400 Received: by ik-out-1112.google.com with SMTP id c30so1475360ika.5 for ; Mon, 13 Oct 2008 23:49:03 -0700 (PDT) In-Reply-To: Sender: kvm-owner@vger.kernel.org List-ID: Held Bernhard wrote: >> Does the attached work for you? >> >> Avi, do you have thoughts on how to proceed with pvmmu? Using hyperc= alls >> instead of faults can still be beneficial (for the first write befor= e >> 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 *v= cpu, >> 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; >> } >> =20 > 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 o= f > segfaults in the guest (2.6.26.5 or 2.6.27, x86_64 on host and guest)= =2E > > Thanks for the patch! > > HTH, > Bernhard > =20 Hi, Using this patch on a vanilla 2.6.27 kernel, I get this when I try to=20 compile it: arch/x86/kvm/mmu.c: In function =91kvm_pv_mmu_flush_tlb=92: arch/x86/kvm/mmu.c:2241: error: =91KVM_REQ_MMU_SYNC=92 undeclared (firs= t use=20 in this function) arch/x86/kvm/mmu.c:2241: error: (Each undeclared identifier is reported= =20 only once arch/x86/kvm/mmu.c:2241: error: for each function it appears in.) make[2]: *** [arch/x86/kvm/mmu.o] Error 1 It was fine with kvm-75 but I still not able to start my ubuntu 2.6.27=20 guest with kvm 75 qnd kvm 76. host : vanilla 2.6.27 x86_64 guest : ubuntu 8.10 (2.6.27) I must be missing a patch somewhere... Xavier