From nobody Mon Feb 9 20:10:20 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1606337851; cv=none; d=zohomail.com; s=zohoarc; b=Ry3GD+jsDFxDFBHmcOA0MXI/qb8LGKdnSDBxZ78b00jF2lsSxz9FvBAlYkojcBgGcFqHwT0kkkF+2v6qkLcXKm9Nx2POumWfcGMY3MKQSFkICEx9502Qh3zis8zr0dZYkyCDOpq+t2Cv+RCWQKIesEjt8xgnZvFW+Yyq9d7Qbhw= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1606337851; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=kcyTO1EndQuMSTqqIVsGvEARRbZE17kEQ/mI/5TZMqc=; b=I6Q55MgfGOI0kHxhWZVlj5C9dLoV/+L4FP7s4lj4iMpe6txsdsmjc4EXGRlhQHzwWAfGyRs+w7sHKKGRIkjD19lenLMIrYN3q3rg9QGhMmG3Bc/QVWnV+/0CRZW/aFrYf2Tq5y9s/keAwpMFarxtsEarENPZcjXIszDuEmqOXTU= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1606337851448358.18714777609625; Wed, 25 Nov 2020 12:57:31 -0800 (PST) Received: from list by lists.xenproject.org with outflank-mailman.38065.70684 (Exim 4.92) (envelope-from ) id 1ki1qb-0008Tx-KU; Wed, 25 Nov 2020 20:57:05 +0000 Received: by outflank-mailman (output) from mailman id 38065.70684; Wed, 25 Nov 2020 20:57:05 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1ki1qb-0008Tq-HQ; Wed, 25 Nov 2020 20:57:05 +0000 Received: by outflank-mailman (input) for mailman id 38065; Wed, 25 Nov 2020 20:57:04 +0000 Received: from all-amaz-eas1.inumbo.com ([34.197.232.57] helo=us1-amaz-eas2.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1ki1qa-0008Tl-9o for xen-devel@lists.xenproject.org; Wed, 25 Nov 2020 20:57:04 +0000 Received: from us-smtp-delivery-124.mimecast.com (unknown [216.205.24.124]) by us1-amaz-eas2.inumbo.com (Halon) with ESMTP id 38c23258-97bd-4ad7-908c-1465e61840fc; Wed, 25 Nov 2020 20:57:03 +0000 (UTC) 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-361-AaIHiFkGOLqrKW3-qBNNqg-1; Wed, 25 Nov 2020 15:56:58 -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 938AF1005D62; Wed, 25 Nov 2020 20:56:56 +0000 (UTC) Received: from localhost (unknown [10.10.67.22]) by smtp.corp.redhat.com (Postfix) with ESMTP id 4230F60854; Wed, 25 Nov 2020 20:56:56 +0000 (UTC) Received: from all-amaz-eas1.inumbo.com ([34.197.232.57] helo=us1-amaz-eas2.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1ki1qa-0008Tl-9o for xen-devel@lists.xenproject.org; Wed, 25 Nov 2020 20:57:04 +0000 Received: from us-smtp-delivery-124.mimecast.com (unknown [216.205.24.124]) by us1-amaz-eas2.inumbo.com (Halon) with ESMTP id 38c23258-97bd-4ad7-908c-1465e61840fc; Wed, 25 Nov 2020 20:57:03 +0000 (UTC) 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-361-AaIHiFkGOLqrKW3-qBNNqg-1; Wed, 25 Nov 2020 15:56:58 -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 938AF1005D62; Wed, 25 Nov 2020 20:56:56 +0000 (UTC) Received: from localhost (unknown [10.10.67.22]) by smtp.corp.redhat.com (Postfix) with ESMTP id 4230F60854; Wed, 25 Nov 2020 20:56:56 +0000 (UTC) X-Outflank-Mailman: Message body and most headers restored to incoming version X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 38c23258-97bd-4ad7-908c-1465e61840fc DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1606337822; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=kcyTO1EndQuMSTqqIVsGvEARRbZE17kEQ/mI/5TZMqc=; b=dIPPZrOk2/l4Uh/CP/fTOkVRa7VJIIQixF7ocsHcarqTk2TvDYFtVPe6Nfcc9juwSxi3Ne ONjAL3u+NctLrS9I7e86U493VeV2XXQgchRbWlXwwACnn8TM+7YfSue5IXgQYUFS1X+yQr ACRNQ+kJZmqAkmpUWZAOrId/F07ftPw= X-MC-Unique: AaIHiFkGOLqrKW3-qBNNqg-1 From: Eduardo Habkost To: qemu-devel@nongnu.org Cc: Gerd Hoffmann , Thomas Huth , Paolo Bonzini , Stefano Stabellini , Anthony Perard , Paul Durrant , xen-devel@lists.xenproject.org, Richard Henderson , Claudio Fontana , Roman Bolshakov Subject: [PATCH v2 4/6] xen: Delete xen_available() function Date: Wed, 25 Nov 2020 15:56:34 -0500 Message-Id: <20201125205636.3305257-5-ehabkost@redhat.com> In-Reply-To: <20201125205636.3305257-1-ehabkost@redhat.com> References: <20201125205636.3305257-1-ehabkost@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=ehabkost@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" The function can be replaced with accel_available("xen"). Signed-off-by: Eduardo Habkost Acked-by: Anthony PERARD Reviewed-by: Cornelia Huck --- Cc: Paolo Bonzini Cc: qemu-devel@nongnu.org Cc: Stefano Stabellini Cc: Anthony Perard Cc: Paul Durrant Cc: xen-devel@lists.xenproject.org Cc: Richard Henderson Cc: Claudio Fontana Cc: Roman Bolshakov --- include/sysemu/arch_init.h | 2 -- softmmu/arch_init.c | 9 --------- softmmu/vl.c | 6 +++--- 3 files changed, 3 insertions(+), 14 deletions(-) diff --git a/include/sysemu/arch_init.h b/include/sysemu/arch_init.h index b32ce1afa9..40ac8052b7 100644 --- a/include/sysemu/arch_init.h +++ b/include/sysemu/arch_init.h @@ -32,6 +32,4 @@ enum { =20 extern const uint32_t arch_type; =20 -int xen_available(void); - #endif diff --git a/softmmu/arch_init.c b/softmmu/arch_init.c index 79383c8db8..f4770931f5 100644 --- a/softmmu/arch_init.c +++ b/softmmu/arch_init.c @@ -49,12 +49,3 @@ int graphic_depth =3D 32; =20 =20 const uint32_t arch_type =3D QEMU_ARCH; - -int xen_available(void) -{ -#ifdef CONFIG_XEN - return 1; -#else - return 0; -#endif -} diff --git a/softmmu/vl.c b/softmmu/vl.c index e6e0ad5a92..74b6ebf1e4 100644 --- a/softmmu/vl.c +++ b/softmmu/vl.c @@ -3667,21 +3667,21 @@ void qemu_init(int argc, char **argv, char **envp) has_defaults =3D 0; break; case QEMU_OPTION_xen_domid: - if (!(xen_available())) { + if (!(accel_available("xen"))) { error_report("Option not supported for this target"); exit(1); } xen_domid =3D atoi(optarg); break; case QEMU_OPTION_xen_attach: - if (!(xen_available())) { + if (!(accel_available("xen"))) { error_report("Option not supported for this target"); exit(1); } xen_mode =3D XEN_ATTACH; break; case QEMU_OPTION_xen_domid_restrict: - if (!(xen_available())) { + if (!(accel_available("xen"))) { error_report("Option not supported for this target"); exit(1); } --=20 2.28.0