From patchwork Wed Sep 2 21:59:04 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jean-Christophe Dubois X-Patchwork-Id: 32852 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by bilbo.ozlabs.org (Postfix) with ESMTPS id 5D4E1B7093 for ; Thu, 3 Sep 2009 07:59:47 +1000 (EST) Received: from localhost ([127.0.0.1]:53905 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Mixrj-0001yM-Qi for incoming@patchwork.ozlabs.org; Wed, 02 Sep 2009 17:59:43 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MixrJ-0001y5-7b for qemu-devel@nongnu.org; Wed, 02 Sep 2009 17:59:17 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MixrE-0001w9-LT for qemu-devel@nongnu.org; Wed, 02 Sep 2009 17:59:17 -0400 Received: from [199.232.76.173] (port=60908 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MixrE-0001w6-Fq for qemu-devel@nongnu.org; Wed, 02 Sep 2009 17:59:12 -0400 Received: from smtp6-g21.free.fr ([212.27.42.6]:35176) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MixrD-0007Sx-RU for qemu-devel@nongnu.org; Wed, 02 Sep 2009 17:59:12 -0400 Received: from smtp6-g21.free.fr (localhost [127.0.0.1]) by smtp6-g21.free.fr (Postfix) with ESMTP id 2896BE080B9; Wed, 2 Sep 2009 23:59:07 +0200 (CEST) Received: from localhost.localdomain (unknown [78.235.240.156]) by smtp6-g21.free.fr (Postfix) with ESMTP id 2A8E2E0809D; Wed, 2 Sep 2009 23:59:05 +0200 (CEST) From: Jean-Christophe DUBOIS To: qemu-devel@nongnu.org Date: Wed, 2 Sep 2009 23:59:04 +0200 Message-Id: <1251928744-404-1-git-send-email-jcd@tribudubois.net> X-Mailer: git-send-email 1.6.0.4 X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) Cc: Jean-Christophe DUBOIS Subject: [Qemu-devel] [PATCH] fix vl.c compilation if CONFIG_KVM is not defined X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org vl.c will not link if CONFIG_KVM is not defined. This patch fixes the problem. Signed-off-by: Jean-Christophe Dubois --- vl.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/vl.c b/vl.c index 1bdc586..4188178 100644 --- a/vl.c +++ b/vl.c @@ -3944,7 +3944,8 @@ static void tcg_init_vcpu(void *_env) static void kvm_start_vcpu(CPUState *env) { - kvm_init_vcpu(env); + if (kvm_enabled()) + kvm_init_vcpu(env); env->thread = qemu_mallocz(sizeof(QemuThread)); env->halt_cond = qemu_mallocz(sizeof(QemuCond)); qemu_cond_init(env->halt_cond);