From nobody Tue Sep 9 03:13:51 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.libvirt.org designates 8.43.85.245 as permitted sender) client-ip=8.43.85.245; envelope-from=devel-bounces@lists.libvirt.org; helo=lists.libvirt.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of lists.libvirt.org designates 8.43.85.245 as permitted sender) smtp.mailfrom=devel-bounces@lists.libvirt.org; dmarc=pass(p=reject dis=none) header.from=lists.libvirt.org ARC-Seal: i=1; a=rsa-sha256; t=1749126041; cv=none; d=zohomail.com; s=zohoarc; b=ApAmLjS+Bd+qaTBJmRoWm4oYdu+RKakFWPNJW0rna/3O20YdDAW2+vV07BhYfxVd2leIIxYdH7P+DaP596ARjfl4lEmrr8CuD4CvMVaoCLrAu+IumnxhzLzspEDTo5ALkS3infRiESIbPYdWFMSL+acFUQNd7jquz4DEDxSbMN0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1749126041; h=Content-Type:Content-Transfer-Encoding:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:Reply-To:References:Subject:Subject:To:To:Message-Id:Cc; bh=VMxzhJ1I//a5pYHO3c90m739zZqVevAQ3OfVeHY5teU=; b=d8UxKgLbeZdlYdnF+EeYg3GKlNxca1/8rQYVJD0b8PvKzzquQBM4ROSPViA4sqg3Ash3WWT7dvzhxIMWx1ZEBvvwiI8U3Z4m5F9KDN4q/PMtPF29caN1J5NWYIX8ABqKZ9isr4XlJFFIpIxasULhiuokzgVnWNEea1iVv5bl1WQ= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of lists.libvirt.org designates 8.43.85.245 as permitted sender) smtp.mailfrom=devel-bounces@lists.libvirt.org; dmarc=pass header.from= (p=reject dis=none) Return-Path: Received: from lists.libvirt.org (lists.libvirt.org [8.43.85.245]) by mx.zohomail.com with SMTPS id 1749126041602373.68204105564485; Thu, 5 Jun 2025 05:20:41 -0700 (PDT) Received: by lists.libvirt.org (Postfix, from userid 996) id 9D3DE10F3; Thu, 5 Jun 2025 08:20:40 -0400 (EDT) Received: from lists.libvirt.org (localhost [IPv6:::1]) by lists.libvirt.org (Postfix) with ESMTP id 4078C1500; Thu, 5 Jun 2025 08:16:43 -0400 (EDT) Received: by lists.libvirt.org (Postfix, from userid 996) id D952213EA; Thu, 5 Jun 2025 08:16:38 -0400 (EDT) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by lists.libvirt.org (Postfix) with ESMTPS id C23D7128A for ; Thu, 5 Jun 2025 08:16:23 -0400 (EDT) Received: from mx-prod-mc-06.mail-002.prod.us-west-2.aws.redhat.com (ec2-35-165-154-97.us-west-2.compute.amazonaws.com [35.165.154.97]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-689-VFvY67IjOhCcUgtCkpIiJA-1; Thu, 05 Jun 2025 08:16:21 -0400 Received: from mx-prod-int-02.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-02.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.15]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-06.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id C5D3F18004A3 for ; Thu, 5 Jun 2025 12:16:20 +0000 (UTC) Received: from moe.brq.redhat.com (unknown [10.43.3.236]) by mx-prod-int-02.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTP id 1C1831956087 for ; Thu, 5 Jun 2025 12:16:19 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on lists.libvirt.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_INVALID,DKIM_SIGNED, MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H5, RCVD_IN_MSPIKE_WL,RCVD_IN_VALIDITY_RPBL_BLOCKED, RCVD_IN_VALIDITY_SAFE_BLOCKED,SPF_HELO_NONE autolearn=unavailable autolearn_force=no version=3.4.4 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1749125783; h=from:from: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; bh=feB+emOZX7F8ED2NhscuWgnhQuoWM+2kY56NqWN6gzM=; b=VjrlMRWqgR+kVqf6duUmkOfRCYQXRvLBCvYt8cF6gLT2Any3CDtfhNfeLyaj7FqAf2KzSr 3s7NBLBSpx92RwYgKaszUtTL/8DQJaXSWuHHFYDz1AAGPzsiF2GjZUiVfHHGBHOwx3gEav 2O8gJ5egp1jHxKQ/BVakuz9hibtfIFs= X-MC-Unique: VFvY67IjOhCcUgtCkpIiJA-1 X-Mimecast-MFC-AGG-ID: VFvY67IjOhCcUgtCkpIiJA_1749125780 To: devel@lists.libvirt.org Subject: [PATCH 08/10] src: Unify argument name of virDomainMigratePerform3() Date: Thu, 5 Jun 2025 14:16:05 +0200 Message-ID: <05be667afe05abd5402735f5ce2548e972ce3fb0.1749125656.git.mprivozn@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.0 on 10.30.177.15 X-Mimecast-Spam-Score: 0 X-Mimecast-MFC-PROC-ID: C7FkpZMSx66v0SAmRhoygxdSkjsb33L1OT9etbbgfnk_1749125780 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable Message-ID-Hash: ITQ2HQOE5BDBCRNPDLQ7TZT5JTOHTPPH X-Message-ID-Hash: ITQ2HQOE5BDBCRNPDLQ7TZT5JTOHTPPH X-MailFrom: mprivozn@redhat.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-config-1; header-match-config-2; header-match-config-3; header-match-devel.lists.libvirt.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; suspicious-header X-Mailman-Version: 3.2.2 Precedence: list List-Id: Development discussions about the libvirt library & tools Archived-At: List-Archive: List-Help: List-Post: List-Subscribe: List-Unsubscribe: From: Michal Privoznik via Devel Reply-To: Michal Privoznik X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZM-MESSAGEID: 1749126042451116600 Content-Type: text/plain; charset="utf-8"; x-default="true" From: Michal Privoznik The virDomainMigratePerform3() API declares its last argument as 'bandwidth', though throughout various typedefs, RPC and callback implementations the name is changed to 'resource'. This creates a confusing. Unify the name. Signed-off-by: Michal Privoznik --- src/driver-hypervisor.h | 2 +- src/libvirt_internal.h | 2 +- src/qemu/qemu_driver.c | 4 ++-- src/remote/remote_daemon_dispatch.c | 2 +- src/remote/remote_driver.c | 4 ++-- src/remote/remote_protocol.x | 2 +- src/remote_protocol-structs | 2 +- src/rpc/gendispatch.pl | 2 +- 8 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/driver-hypervisor.h b/src/driver-hypervisor.h index 3f367806ee..6a43688b0c 100644 --- a/src/driver-hypervisor.h +++ b/src/driver-hypervisor.h @@ -1020,7 +1020,7 @@ typedef int const char *uri, unsigned long flags, const char *dname, - unsigned long resource); + unsigned long bandwidth); =20 typedef virDomainPtr (*virDrvDomainMigrateFinish3)(virConnectPtr dconn, diff --git a/src/libvirt_internal.h b/src/libvirt_internal.h index df99fe260c..b3376e4a24 100644 --- a/src/libvirt_internal.h +++ b/src/libvirt_internal.h @@ -226,7 +226,7 @@ int virDomainMigratePerform3(virDomainPtr dom, const char *uri, /* VM Migration URI */ unsigned long flags, const char *dname, - unsigned long resource); + unsigned long bandwidth); =20 virDomainPtr virDomainMigrateFinish3(virConnectPtr dconn, const char *dname, diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c index a89b78d5d8..99db92008f 100644 --- a/src/qemu/qemu_driver.c +++ b/src/qemu/qemu_driver.c @@ -11284,7 +11284,7 @@ qemuDomainMigratePerform3(virDomainPtr dom, const char *uri, unsigned long flags, const char *dname, - unsigned long resource) + unsigned long bandwidth) { virQEMUDriver *driver =3D dom->conn->privateData; virDomainObj *vm =3D NULL; @@ -11308,7 +11308,7 @@ qemuDomainMigratePerform3(virDomainPtr dom, NULL, migParams, cookiein, cookieinlen, cookieout, cookieoutlen, - flags, dname, resource, true); + flags, dname, bandwidth, true); =20 cleanup: virDomainObjEndAPI(&vm); diff --git a/src/remote/remote_daemon_dispatch.c b/src/remote/remote_daemon= _dispatch.c index 2abfe7bf3b..7e74ff063f 100644 --- a/src/remote/remote_daemon_dispatch.c +++ b/src/remote/remote_daemon_dispatch.c @@ -4910,7 +4910,7 @@ remoteDispatchDomainMigratePerform3(virNetServer *ser= ver G_GNUC_UNUSED, args->cookie_in.cookie_in_len, &cookieout, &cookieoutlen, dconnuri, uri, - args->flags, dname, args->resource) < 0) + args->flags, dname, args->bandwidth) < 0) goto cleanup; =20 /* remoteDispatchClientRequest will free cookie diff --git a/src/remote/remote_driver.c b/src/remote/remote_driver.c index 8fd387fc1c..ec71eaed87 100644 --- a/src/remote/remote_driver.c +++ b/src/remote/remote_driver.c @@ -5806,7 +5806,7 @@ remoteDomainMigratePerform3(virDomainPtr dom, const char *uri, unsigned long flags, const char *dname, - unsigned long resource) + unsigned long bandwidth) { remote_domain_migrate_perform3_args args =3D {0}; g_auto(remote_domain_migrate_perform3_ret) ret =3D {0}; @@ -5822,7 +5822,7 @@ remoteDomainMigratePerform3(virDomainPtr dom, args.dname =3D dname =3D=3D NULL ? NULL : (char **) &dname; args.uri =3D uri =3D=3D NULL ? NULL : (char **) &uri; args.dconnuri =3D dconnuri =3D=3D NULL ? NULL : (char **) &dconnuri; - args.resource =3D resource; + args.bandwidth =3D bandwidth; =20 if (call(dom->conn, priv, 0, REMOTE_PROC_DOMAIN_MIGRATE_PERFORM3, (xdrproc_t) xdr_remote_domain_migrate_perform3_args, (char *)= &args, diff --git a/src/remote/remote_protocol.x b/src/remote/remote_protocol.x index 21aaf615ba..3c93203210 100644 --- a/src/remote/remote_protocol.x +++ b/src/remote/remote_protocol.x @@ -2989,7 +2989,7 @@ struct remote_domain_migrate_perform3_args { remote_string uri; unsigned hyper flags; remote_string dname; - unsigned hyper resource; + unsigned hyper bandwidth; }; =20 struct remote_domain_migrate_perform3_ret { diff --git a/src/remote_protocol-structs b/src/remote_protocol-structs index 63a51e3362..0f87d13a5a 100644 --- a/src/remote_protocol-structs +++ b/src/remote_protocol-structs @@ -2316,7 +2316,7 @@ struct remote_domain_migrate_perform3_args { remote_string uri; uint64_t flags; remote_string dname; - uint64_t resource; + uint64_t bandwidth; }; struct remote_domain_migrate_perform3_ret { struct { diff --git a/src/rpc/gendispatch.pl b/src/rpc/gendispatch.pl index 1a7d09056e..dd3362c831 100755 --- a/src/rpc/gendispatch.pl +++ b/src/rpc/gendispatch.pl @@ -404,7 +404,7 @@ my $long_legacy =3D { DomainMigrateFinish3 =3D> { arg =3D> { flags =3D> 1 } }, DomainMigratePeer2Peer =3D> { arg =3D> { flags =3D> 1, resource = =3D> 1 } }, DomainMigratePerform =3D> { arg =3D> { flags =3D> 1, bandwidth = =3D> 1 } }, - DomainMigratePerform3 =3D> { arg =3D> { flags =3D> 1, resource = =3D> 1 } }, + DomainMigratePerform3 =3D> { arg =3D> { flags =3D> 1, bandwidth = =3D> 1 } }, DomainMigratePrepare =3D> { arg =3D> { flags =3D> 1, bandwidth = =3D> 1 } }, DomainMigratePrepare2 =3D> { arg =3D> { flags =3D> 1, bandwidth = =3D> 1 } }, DomainMigratePrepare3 =3D> { arg =3D> { flags =3D> 1, bandwidth = =3D> 1 } }, --=20 2.49.0