From nobody Mon Feb 9 05:19:22 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) client-ip=170.10.133.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1675259400; cv=none; d=zohomail.com; s=zohoarc; b=k96ZHV1kPhpDddP4wkdWRqn3tb9LbpbsK0zyKmnw1/tuGxD6jU5w4NNKi85TdZ+nvZTohs0xJGiWNStuWaOdrfPAEEUpIvCYjeo0i1Gyuw+a9FsnshfNh8okPkfaret86jFbirvLPahR3bO9Od9RnaHEatcCAt2jQYTYrimzfEg= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1675259400; h=Content-Type:Content-Transfer-Encoding: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=oewH/eaAyyFr62TWvTKcEwHaneb58lwfADysooVTO4A=; b=U6vFflQ4mSn+Lf9Gt6KupCFxDXeUuLELqD2BZoWr869vd0KARCBi4KVN+Cz5Ye0ATYZCwVXLHO5w72m/icC6CjgI+rjTDoEw2Onx+GdVXATStZtl1XZ3HRQsEznfLjV84GTghmAKSrLZWLn8AazVpHhfsSOyq8mBhuzR1G27iAs= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mx.zohomail.com with SMTPS id 1675259400446247.79639146249053; Wed, 1 Feb 2023 05:50:00 -0800 (PST) Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-150-DwT2yLTvNOeQWpsfXFatcw-1; Wed, 01 Feb 2023 08:49:53 -0500 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id DA1DC88B7CE; Wed, 1 Feb 2023 13:49:48 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (unknown [10.30.29.100]) by smtp.corp.redhat.com (Postfix) with ESMTP id C281F2166B39; Wed, 1 Feb 2023 13:49:48 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (localhost [IPv6:::1]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id 1DB8619465B2; Wed, 1 Feb 2023 13:49:47 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.rdu2.redhat.com [10.11.54.5]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id 6E60019465A2 for ; Wed, 1 Feb 2023 13:49:36 +0000 (UTC) Received: by smtp.corp.redhat.com (Postfix) id 3AD05422F2; Wed, 1 Feb 2023 13:49:36 +0000 (UTC) Received: from maggie.redhat.com (unknown [10.43.2.39]) by smtp.corp.redhat.com (Postfix) with ESMTP id D58A253A0 for ; Wed, 1 Feb 2023 13:49:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1675259399; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=oewH/eaAyyFr62TWvTKcEwHaneb58lwfADysooVTO4A=; b=cK/NDLlRbd9bGraGjMnOw5ixUb8LiOpMub7Ee+Ln/uW+OwSN29ms+29Dsl935hX64DvTzy sRHcp6P6B2W//L2phFkhBr9aHSs1xF5xXGquuiTajiZC4/3CGTpzqnKNWOLfpcOd25XNvC bQx3T3+BgjHBozP1SVSIEvCRZrVK6nA= X-MC-Unique: DwT2yLTvNOeQWpsfXFatcw-1 X-Original-To: libvir-list@listman.corp.redhat.com From: Michal Privoznik To: libvir-list@redhat.com Subject: [PATCH 1/5] domain_conf: Move virDomainNetVhostuserMode enum declaration Date: Wed, 1 Feb 2023 14:49:30 +0100 Message-Id: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.5 X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libvir-list-bounces@redhat.com Sender: "libvir-list" X-Scanned-By: MIMEDefang 3.1 on 10.11.54.6 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) X-ZM-MESSAGEID: 1675259402440100001 Content-Type: text/plain; charset="utf-8"; x-default="true" While it's true that the virDomainNetVhostuserMode enum is used solely in virDomainNetDefParseXML(), its placement just above the function is rather unfortunate. Let's put it at the beginning of the file with the rest of the enum declarations/implementations. Signed-off-by: Michal Privoznik --- src/conf/domain_conf.c | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c index 1cf2bf84bc..dc5c0b0ba5 100644 --- a/src/conf/domain_conf.c +++ b/src/conf/domain_conf.c @@ -1500,6 +1500,23 @@ VIR_ENUM_IMPL(virDomainLaunchSecurity, "s390-pv", ); =20 +typedef enum { + VIR_DOMAIN_NET_VHOSTUSER_MODE_NONE, + VIR_DOMAIN_NET_VHOSTUSER_MODE_CLIENT, + VIR_DOMAIN_NET_VHOSTUSER_MODE_SERVER, + + VIR_DOMAIN_NET_VHOSTUSER_MODE_LAST +} virDomainNetVhostuserMode; + +VIR_ENUM_DECL(virDomainNetVhostuserMode); +VIR_ENUM_IMPL(virDomainNetVhostuserMode, + VIR_DOMAIN_NET_VHOSTUSER_MODE_LAST, + "", + "client", + "server", +); + + static virClass *virDomainObjClass; static virClass *virDomainXMLOptionClass; static void virDomainObjDispose(void *obj); @@ -9222,23 +9239,6 @@ virDomainNetDefParseXMLRequireSource(virDomainNetDef= *def, } =20 =20 -typedef enum { - VIR_DOMAIN_NET_VHOSTUSER_MODE_NONE, - VIR_DOMAIN_NET_VHOSTUSER_MODE_CLIENT, - VIR_DOMAIN_NET_VHOSTUSER_MODE_SERVER, - - VIR_DOMAIN_NET_VHOSTUSER_MODE_LAST -} virDomainNetVhostuserMode; - -VIR_ENUM_DECL(virDomainNetVhostuserMode); -VIR_ENUM_IMPL(virDomainNetVhostuserMode, - VIR_DOMAIN_NET_VHOSTUSER_MODE_LAST, - "", - "client", - "server", -); - - static virDomainNetDef * virDomainNetDefParseXML(virDomainXMLOption *xmlopt, xmlNodePtr node, --=20 2.39.1