From nobody Mon Feb 9 20:10:34 2026 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1606338189; cv=none; d=zohomail.com; s=zohoarc; b=LEQaysEVv0PSwXw0UYP0M0hAQTDeeNr7jAAtNr58VLvCQ1x8enWs5pjI5xV2hjft6g6E70MPoWx5pkp0zvSYqdPtG4/Ltvq3imYwD2XDIqSyo001EgIWvgR8XXivars83RbDubfIQYeuz/rAPqOWcWnm2fWDHVoWV+v6quJmyME= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1606338189; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=UZZQRbSxpJbfML8IkKeWrdc8btDAgjJ9BXbeofnw+dE=; b=Lcm4H03n6aJ9RenQamF6mEGO0pkhSB7dr99a97Gv32aPjPYrHyYDSwP51ejP1WK4e6NFe1TM2HONsELXnxS0p8f61se6DnhHYiFuE1OlujiZi12oPmPHgSAUfoJLhRo91W/B8rAie1MDWrqw1zvdOu5T7udZzOLYGvoSQx2xMXo= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1606338189827404.06854373843476; Wed, 25 Nov 2020 13:03:09 -0800 (PST) Received: from localhost ([::1]:37736 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ki1wS-0004x9-AM for importer@patchew.org; Wed, 25 Nov 2020 16:03:08 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:51944) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ki1qW-0000M2-9B for qemu-devel@nongnu.org; Wed, 25 Nov 2020 15:57:00 -0500 Received: from us-smtp-delivery-124.mimecast.com ([216.205.24.124]:36960) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.90_1) (envelope-from ) id 1ki1qU-0003MM-JR for qemu-devel@nongnu.org; Wed, 25 Nov 2020 15:57:00 -0500 Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-159-uPzmHt8iMk6LKtSdDdHVQg-1; Wed, 25 Nov 2020 15:56:56 -0500 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id C3F1A180E49C; Wed, 25 Nov 2020 20:56:54 +0000 (UTC) Received: from localhost (unknown [10.10.67.22]) by smtp.corp.redhat.com (Postfix) with ESMTP id 85F3560854; Wed, 25 Nov 2020 20:56:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1606337818; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=UZZQRbSxpJbfML8IkKeWrdc8btDAgjJ9BXbeofnw+dE=; b=XYsMEKCKqmBBKkiniTq7vAgg6ay2whGDiF0bO5RUde04OQ0JgBOfeFsTRw/b2nMM6CCyu2 G6yDrxfqH4eantlQYX0JBvtDn43Q9P9YyxGaE23KFEihBVAR9Ej9V304kiNyhpBqAXPPiJ VOG2CbojhtD+IuFhXUdb2Ni20bO/Txg= X-MC-Unique: uPzmHt8iMk6LKtSdDdHVQg-1 From: Eduardo Habkost To: qemu-devel@nongnu.org Subject: [PATCH v2 3/6] kvm: Remove kvm_available() function Date: Wed, 25 Nov 2020 15:56:33 -0500 Message-Id: <20201125205636.3305257-4-ehabkost@redhat.com> In-Reply-To: <20201125205636.3305257-1-ehabkost@redhat.com> References: <20201125205636.3305257-1-ehabkost@redhat.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=216.205.24.124; envelope-from=ehabkost@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Thomas Huth , kvm@vger.kernel.org, Richard Henderson , Markus Armbruster , Roman Bolshakov , Gerd Hoffmann , Paolo Bonzini , Claudio Fontana Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) Content-Type: text/plain; charset="utf-8" The only caller can use accel_available("kvm") instead. Signed-off-by: Eduardo Habkost Reviewed-by: Cornelia Huck --- Cc: Markus Armbruster Cc: qemu-devel@nongnu.org Cc: Paolo Bonzini Cc: kvm@vger.kernel.org Cc: Richard Henderson Cc: Paolo Bonzini Cc: Claudio Fontana Cc: Roman Bolshakov --- include/sysemu/arch_init.h | 1 - monitor/qmp-cmds.c | 2 +- softmmu/arch_init.c | 9 --------- 3 files changed, 1 insertion(+), 11 deletions(-) diff --git a/include/sysemu/arch_init.h b/include/sysemu/arch_init.h index 54f069d491..b32ce1afa9 100644 --- a/include/sysemu/arch_init.h +++ b/include/sysemu/arch_init.h @@ -32,7 +32,6 @@ enum { =20 extern const uint32_t arch_type; =20 -int kvm_available(void); int xen_available(void); =20 #endif diff --git a/monitor/qmp-cmds.c b/monitor/qmp-cmds.c index a08143b323..ac5b8a97d7 100644 --- a/monitor/qmp-cmds.c +++ b/monitor/qmp-cmds.c @@ -57,7 +57,7 @@ KvmInfo *qmp_query_kvm(Error **errp) KvmInfo *info =3D g_malloc0(sizeof(*info)); =20 info->enabled =3D kvm_enabled(); - info->present =3D kvm_available(); + info->present =3D accel_available("kvm"); =20 return info; } diff --git a/softmmu/arch_init.c b/softmmu/arch_init.c index 7ef32a98b9..79383c8db8 100644 --- a/softmmu/arch_init.c +++ b/softmmu/arch_init.c @@ -50,15 +50,6 @@ int graphic_depth =3D 32; =20 const uint32_t arch_type =3D QEMU_ARCH; =20 -int kvm_available(void) -{ -#ifdef CONFIG_KVM - return 1; -#else - return 0; -#endif -} - int xen_available(void) { #ifdef CONFIG_XEN --=20 2.28.0