From nobody Mon Feb 9 15:10:20 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.129.124 as permitted sender) client-ip=170.10.129.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.129.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=1637253284; cv=none; d=zohomail.com; s=zohoarc; b=G/TfS6n6pR872Fpx9d4Aqg/8tNa+W20RDckfIi9GFDm+5U6dT/zNK8iO60/bFdwUMjdCUCujcMe/SQ+5OGLQLQniflWt4xWerTdEybslEQic9z6dPojFMM/aMOZBacSDxKChYLd3r/VsMVru2o+DfsNF+VwcueLE5uCTxcPmaeY= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1637253284; 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=3e0MIZ8yYFiWP+5w/p5EpScpUukCEhlQvHLwCocknzk=; b=VpC58GjI7B7aecXhcafc+IyQocJEOTCxkw6NOThXZD02aVRTz982CDB8RXMmoTld+PZiuuLcxDCSUHkNHxBJtmyvI8yG6BQWaeER4eAc5Ca8hfTfgSMW/wiwymWpa3F3QRg9mcn11NbRIcX98liFHxPVVgm40Q7EeZAmx5A9bJs= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.129.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.129.124]) by mx.zohomail.com with SMTPS id 1637253284576638.2028317412158; Thu, 18 Nov 2021 08:34:44 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-401-49t4vnWMPbGoL3Cwoz5cyA-1; Thu, 18 Nov 2021 11:34:39 -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 9364310151E1; Thu, 18 Nov 2021 16:34:34 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 71E4C694B4; Thu, 18 Nov 2021 16:34:34 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 3D20D1832DFD; Thu, 18 Nov 2021 16:34:34 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 1AIGXsNB028083 for ; Thu, 18 Nov 2021 11:33:54 -0500 Received: by smtp.corp.redhat.com (Postfix) id A7B11608BA; Thu, 18 Nov 2021 16:33:54 +0000 (UTC) Received: from speedmetal.lan (unknown [10.40.208.20]) by smtp.corp.redhat.com (Postfix) with ESMTP id E81BF1B5C0 for ; Thu, 18 Nov 2021 16:33:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1637253283; 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=3e0MIZ8yYFiWP+5w/p5EpScpUukCEhlQvHLwCocknzk=; b=QiA4j8aXZt6+56LWre+4e8Mll5rXJc4U8NzLGzkUvpbIQK0ObBx+3xzIRtDIWS4ApV/+Rp kW47dFz+VG4aMC9w/IA/PEClTaztqqv4vAbeE4Hdgb4dYMKR5yklBFFAi8Nk4FkmROV1P3 eKsV5mAfQ/BAafxAZuT8+JgVKS8tcu0= X-MC-Unique: 49t4vnWMPbGoL3Cwoz5cyA-1 From: Peter Krempa To: libvir-list@redhat.com Subject: [PATCH 07/16] qemu: command: Rename qemuBuildHostNetStr -> qemuBuildHostNetProps Date: Thu, 18 Nov 2021 17:33:32 +0100 Message-Id: <284c0f3de511f5ff707f617db4633b1af750e686.1637253107.git.pkrempa@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-loop: libvir-list@redhat.com X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com 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: 1637253285920100001 Content-Type: text/plain; charset="utf-8" The function is already returning JSON properties, rename it accordingly. Signed-off-by: Peter Krempa --- src/qemu/qemu_command.c | 22 +++++++++++----------- src/qemu/qemu_command.h | 15 ++++++++------- src/qemu/qemu_hotplug.c | 8 ++++---- 3 files changed, 23 insertions(+), 22 deletions(-) diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index 24dd00af9b..9293a413e6 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@ -3936,13 +3936,13 @@ qemuBuildNicDevProps(virDomainDef *def, virJSONValue * -qemuBuildHostNetStr(virDomainNetDef *net, - char **tapfd, - size_t tapfdSize, - char **vhostfd, - size_t vhostfdSize, - const char *slirpfd, - const char *vdpadev) +qemuBuildHostNetProps(virDomainNetDef *net, + char **tapfd, + size_t tapfdSize, + char **vhostfd, + size_t vhostfdSize, + const char *slirpfd, + const char *vdpadev) { bool is_tap =3D false; virDomainNetType netType =3D virDomainNetGetActualType(net); @@ -8975,10 +8975,10 @@ qemuBuildInterfaceCommandLine(virQEMUDriver *driver, if (chardev) virCommandAddArgList(cmd, "-chardev", chardev, NULL); - if (!(hostnetprops =3D qemuBuildHostNetStr(net, - tapfdName, tapfdSize, - vhostfdName, vhostfdSize, - slirpfdName, vdpafdName))) + if (!(hostnetprops =3D qemuBuildHostNetProps(net, + tapfdName, tapfdSize, + vhostfdName, vhostfdSize, + slirpfdName, vdpafdName))) goto cleanup; if (qemuBuildNetdevCommandlineFromJSON(cmd, hostnetprops, qemuCaps) < = 0) diff --git a/src/qemu/qemu_command.h b/src/qemu/qemu_command.h index 81fd24406d..c544c9ec67 100644 --- a/src/qemu/qemu_command.h +++ b/src/qemu/qemu_command.h @@ -87,13 +87,14 @@ qemuBuildChrDeviceProps(const virDomainDef *vmdef, virJSONValue * qemuBuildChannelGuestfwdNetdevProps(virDomainChrDef *chr); -virJSONValue *qemuBuildHostNetStr(virDomainNetDef *net, - char **tapfd, - size_t tapfdSize, - char **vhostfd, - size_t vhostfdSize, - const char *slirpfd, - const char *vdpadev); +virJSONValue * +qemuBuildHostNetProps(virDomainNetDef *net, + char **tapfd, + size_t tapfdSize, + char **vhostfd, + size_t vhostfdSize, + const char *slirpfd, + const char *vdpadev); /* Current, best practice */ virJSONValue * diff --git a/src/qemu/qemu_hotplug.c b/src/qemu/qemu_hotplug.c index 6f667dfb76..3df0a1f17a 100644 --- a/src/qemu/qemu_hotplug.c +++ b/src/qemu/qemu_hotplug.c @@ -1459,10 +1459,10 @@ qemuDomainAttachNetDevice(virQEMUDriver *driver, vdpafdName =3D g_strdup_printf("/dev/fdset/%d", fdinfo.fdset); } - if (!(netprops =3D qemuBuildHostNetStr(net, - tapfdName, tapfdSize, - vhostfdName, vhostfdSize, - slirpfdName, vdpafdName))) { + if (!(netprops =3D qemuBuildHostNetProps(net, + tapfdName, tapfdSize, + vhostfdName, vhostfdSize, + slirpfdName, vdpafdName))) { ignore_value(qemuDomainObjExitMonitor(driver, vm)); goto cleanup; } --=20 2.31.1