From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: passt.top; dmarc=none (p=none dis=none) header.from=gibson.dropbear.id.au Authentication-Results: passt.top; dkim=pass (2048-bit key; secure) header.d=gibson.dropbear.id.au header.i=@gibson.dropbear.id.au header.a=rsa-sha256 header.s=202602 header.b=grt+4Ujk; dkim-atps=neutral Received: from mail.ozlabs.org (gandalf.ozlabs.org [150.107.74.76]) by passt.top (Postfix) with ESMTPS id CA6315A0269 for ; Sat, 21 Mar 2026 08:40:28 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gibson.dropbear.id.au; s=202602; t=1774078825; bh=uH3hmh0Gs4EBB4ujsoBT7hKX3aA/Thxmihaa/Ke7QUg=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=grt+4Ujk2jvkiVkaGma0b5U0Gv8IkSHtzS8Z8u/worCUWzKcqQmgtZTWxa/rRDYQK vF/hKwNDg9LDLrmpUAB+3tytUIfo+7s9m5+KyusVmLbcqEJPIJrEA8l6EI2fSaOiez +eVM2ZwZOVpulD8WA2PcFURUfl6qUQrrDID1vAFs39cz/cYlfqbr2DJN8fujrvzPRW l6RDWZAKh3XnMghy1IxfQw6sOx/uZhhehoWPInbSuWz28D+I6l9abNF1EJ7eCZfsno iGVkLKelC9C1wQ3k+QFU4BOV1BLpy2qjSG7mVWdGGwnrkH37fCT0Q4oRjIfkCzHnBA fQmVMp3RLI5ug== Received: by gandalf.ozlabs.org (Postfix, from userid 1007) id 4fdBDT10Rhz4wSj; Sat, 21 Mar 2026 18:40:25 +1100 (AEDT) Date: Sat, 21 Mar 2026 18:40:14 +1100 From: David Gibson To: Stefano Brivio Subject: Re: [PATCH v3 0/3] Decouple iovec management from virtqueue elements Message-ID: References: <20260318091941.2652278-1-lvivier@redhat.com> <20260320215816.052d2be8@elisabeth> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="ADZ4RhhQTNr9KuAK" Content-Disposition: inline In-Reply-To: <20260320215816.052d2be8@elisabeth> Message-ID-Hash: ZSBUXOGI3SBJ4PGPCPWTQWEXEXLGISDM X-Message-ID-Hash: ZSBUXOGI3SBJ4PGPCPWTQWEXEXLGISDM X-MailFrom: dgibson@gandalf.ozlabs.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: Laurent Vivier , passt-dev@passt.top X-Mailman-Version: 3.3.8 Precedence: list List-Id: Development discussion and patches for passt Archived-At: Archived-At: List-Archive: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: --ADZ4RhhQTNr9KuAK Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Mar 20, 2026 at 09:58:17PM +0100, Stefano Brivio wrote: > On Wed, 18 Mar 2026 10:19:38 +0100 > Laurent Vivier wrote: >=20 > > This series prepares the vhost-user path for multi-buffer support, > > where a single virtqueue element can use more than one iovec entry. > >=20 > > Currently, iovec arrays are tightly coupled to virtqueue elements: > > callers must pre-initialize each element's in_sg/out_sg pointers > > before calling vu_queue_pop(), and each element is assumed to own > > exactly one iovec slot. This makes it impossible for a single element > > to span multiple iovec entries, which is needed for UDP multi-buffer > > reception. > >=20 > > The series decouples iovec storage from elements in three patches: > >=20 > > - Patch 1 passes iovec arrays as separate parameters to vu_queue_pop() > > and vu_queue_map_desc(), so the caller controls where descriptors > > are mapped rather than reading them from pre-initialized element > > fields. > >=20 > > - Patch 2 passes the actual remaining out_sg capacity to > > vu_queue_pop() in vu_handle_tx() instead of a fixed per-element > > constant, enabling dynamic iovec allocation. > >=20 > > - Patch 3 moves iovec pool management into vu_collect(), which now > > accepts the iovec array and tracks consumed entries across elements > > with a running counter. This removes vu_set_element() and > > vu_init_elem() entirely. Callers that still assume one iovec per > > element assert this invariant explicitly until they are updated for > > multi-buffer. > >=20 > > The follow-up udp-iov_vu series builds on this to implement actual > > multi-buffer support in the UDP vhost-user path. > >=20 > > v3: > > - rebase and add David's R-b > > - fix coding style (if) > > - rename in_num to in_total >=20 > Applied. I took the liberty to add David's Reviewed-by: back on 3/3 as > the only change in 3/3 v3 compared to v2 was actually something he > suggested. Oh, sorry, I thought I'd already R-b'ed all of v3. --=20 David Gibson (he or they) | I'll have my music baroque, and my code david AT gibson.dropbear.id.au | minimalist, thank you, not the other way | around. http://www.ozlabs.org/~dgibson --ADZ4RhhQTNr9KuAK Content-Type: application/pgp-signature; name=signature.asc -----BEGIN PGP SIGNATURE----- iQIzBAEBCgAdFiEEO+dNsU4E3yXUXRK2zQJF27ox2GcFAmm+S0kACgkQzQJF27ox 2Gea0hAAjrGAXODULAjGSh959EcYxfqutSJN+lDUXEK8YeCbEsgSPpqXUQpl6WH3 H0saUxXLLeWu+t9vsJi2oMX5V2HwiITGBtLwvKSmgP9J8QOu78EJ4jeshfsQq0jj tEUZ58KYaYoNbv3kToLA3JMs5G/Jat8Xv8OAX9NcAbCZvDL+0iLVh4JDXZLKEADc kkFs6JQIhPpfbttXZ44j3QtnjDL+CU9rJXKx1WzJ2nH3+Z+9KYn+wBSk83lA3lqz jOQSQP5Srzk5CYZtq69NC2ryFz6WFG00Ty8je9aG1KN4l4KbLbLsp9y+wG+Plohr zc15cpUoJ/oRVg4+/wm3Bwe7vuiehRuvjlurAr3mngC4+RVLM4XATs9BbCyFRd6m hWsPgRppbY7uzXDBTO4ZP9Afb2TyozJl9i2dQGGvYB9cyh2l/MWLGeyMlr9hrS9c fFnSKjSPLCshkfny7jSBLuSO61nzoiIEVUaBeQR/u+5CHXtDQMg7xQPDf0Norpat 0RlN54bqIiyAGSIuPrf02LM9XOJPSghbQH9IUVQgWKlBhftux2bCjEySf1QBFwEn csuCo80637hYEv6XZt6Fhy7UbKGPQ+v1Jgs1gAJO1C8Lk5O8oPE/gWYYhpL0V8i0 4+JR2jZjW/XSg+BxaMBQiMCXfBaHhZv6UxBd5MXwK8r7eL7o0RQ= =Zo8z -----END PGP SIGNATURE----- --ADZ4RhhQTNr9KuAK--