From mboxrd@z Thu Jan 1 00:00:00 1970 From: Christian Ehrhardt Subject: Re: [PATCH] [PATCH] qemu: report issues causing the kvm probe to fail Date: Mon, 15 Dec 2008 14:26:52 +0100 Message-ID: <49465B1C.8010900@linux.vnet.ibm.com> References: <494631D6.3080807@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: QUOTED-PRINTABLE Cc: hollisb@us.ibm.com, kvm@vger.kernel.org To: Avi Kivity Return-path: Received: from mtagate5.de.ibm.com ([195.212.29.154]:62288 "EHLO mtagate5.de.ibm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751279AbYLON1E (ORCPT ); Mon, 15 Dec 2008 08:27:04 -0500 Received: from d12nrmr1607.megacenter.de.ibm.com (d12nrmr1607.megacenter.de.ibm.com [9.149.167.49]) by mtagate5.de.ibm.com (8.13.8/8.13.8) with ESMTP id mBFDR1WL436070 for ; Mon, 15 Dec 2008 13:27:01 GMT Received: from d12av02.megacenter.de.ibm.com (d12av02.megacenter.de.ibm.com [9.149.165.228]) by d12nrmr1607.megacenter.de.ibm.com (8.13.8/8.13.8/NCO v9.1) with ESMTP id mBFDR1571044566 for ; Mon, 15 Dec 2008 14:27:01 +0100 Received: from d12av02.megacenter.de.ibm.com (loopback [127.0.0.1]) by d12av02.megacenter.de.ibm.com (8.12.11.20060308/8.13.3) with ESMTP id mBFDR1nP005795 for ; Mon, 15 Dec 2008 14:27:01 +0100 In-Reply-To: <494631D6.3080807@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: Avi Kivity wrote: > Christian Ehrhardt wrote: >> I ran into the issue of a failign KVM Probe of the qemu configure=20 >> script three >> times this week always needing "set -x", inserting an exit, masking=20 >> the cleanup >> trap and compiling the c file by hand until I knew what the reason=20 >> is. I think >> we could make easier for developers and end users. >> Therefore this patch keeps the qemu style configure output which is = a=20 >> list of >> "$Feature $Status", but extend the "no" result like "KVM Support no"= =20 >> with some >> more information. >> >> There might be a lot of things going wrong with that probe and I=20 >> don't want >> to handle all of them, but if it is one of the known checks e.g. for >> KVM_API_VERSION then we could grep/awk that out and report it. The p= atch >> reports in case of a known case in the style >> "KVM support no - (Missing KVM capability=20 >> KVM_CAP_DESTROY_MEMORY_REGION_WORKS)" >> >> In case more than one #error is triggered it creates a comma=20 >> separated list in >> those brackets and in case it is something else than an #error it=20 >> just reports >> plain old "no". >> >> diff --git a/qemu/configure b/qemu/configure >> --- a/qemu/configure >> +++ b/qemu/configure >> @@ -1037,12 +1037,14 @@ if test "$kvm" =3D "yes" ; then >> if test "$kvm" =3D "yes" ; then >> cat > $TMPC <> #include >> -#if !defined(KVM_API_VERSION) || \ >> - KVM_API_VERSION < 12 || \ >> - KVM_API_VERSION > 12 || \ >> - !defined(KVM_CAP_USER_MEMORY) || \ >> - !defined(KVM_CAP_SET_TSS_ADDR) >> +#if !defined(KVM_API_VERSION) || KVM_API_VERSION < 12 ||=20 >> KVM_API_VERSION > 12 >> #error Invalid KVM version >> =20 > > You might refine this a bit: if KVM_API_VERSION is not defined, most= =20 > likely linux/kvm.h could not be found, so you might as well report th= at. > >> +#endif >> =20 > > Updated v2 should appear on the list soon reporting all gcc "error:"=20 messages. --=20 Gr=FCsse / regards,=20 Christian Ehrhardt IBM Linux Technology Center, Open Virtualization