From: Avi Kivity Subject: [PATCH] Don't launch guest if -no-kvm when tcg is not configured in Date: Sun, 12 Sep 2010 09:51:35 +0200 Message-ID: <1284277895-18850-1-git-send-email-avi@redhat.com> To: kvm@vger.kernel.org Return-path: Received: from mx1.redhat.com ([209.132.183.28]:37956 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751577Ab0ILHvh (ORCPT ); Sun, 12 Sep 2010 03:51:37 -0400 Received: from int-mx08.intmail.prod.int.phx2.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o8C7pbRR015087 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Sun, 12 Sep 2010 03:51:37 -0400 Received: from cleopatra.tlv.redhat.com (cleopatra.tlv.redhat.com [10.35.255.11]) by int-mx08.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o8C7pato011027 for ; Sun, 12 Sep 2010 03:51:37 -0400 Sender: kvm-owner@vger.kernel.org List-ID: Signed-off-by: Avi Kivity --- vl.c | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-) diff --git a/vl.c b/vl.c index 2a32cc5..22a3616 100644 --- a/vl.c +++ b/vl.c @@ -2473,6 +2473,10 @@ int main(int argc, char **argv, char **envp) break; case QEMU_OPTION_no_kvm: kvm_allowed = 0; +#ifdef CONFIG_NO_CPU_EMULATION + fprintf(stderr, "cpu emulation not configured\n"); + exit(1); +#endif break; #ifdef CONFIG_KVM case QEMU_OPTION_no_kvm_irqchip: { -- 1.7.1