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=202508 header.b=m8uS0vFl; dkim-atps=neutral Received: from mail.ozlabs.org (mail.ozlabs.org [IPv6:2404:9400:2221:ea00::3]) by passt.top (Postfix) with ESMTPS id 32FDE5A027B for ; Fri, 15 Aug 2025 03:11:44 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gibson.dropbear.id.au; s=202508; t=1755220300; bh=6g30SKIceYmksepVqUqMhelEznteaXYxaurE7cKHmHA=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=m8uS0vFlokggBGcEyOxvD0N8Fr8yd/2r68yBfvp7CeG9jE3Z7ECvy7GBu51UUx6nW hzSh9wz+Xv8SxWGeTTxm4m/49I8dVUvJ2UKmdcBV1a2RlhL3hpj/A3RquO1GhFRhSN GKLxLgmnQjFF2sRK2n7Cfmbu/JMny0maQP3P1WKneKiLIqMy0ob9YdEhT9my7pyEFs usLEKnnl8BW8oH/X86x0i3ALtAh4EevSONshN0Wq02yrigVkOQLQj7BtpR268q/Y3o lFbmg85XklI9xfnux1h6LtaCuhoEg2ojLiDKRgyrq4iG6lcrlBtzdJAS5Na4I5uxs+ gZEITBM6mre7g== Received: by gandalf.ozlabs.org (Postfix, from userid 1007) id 4c33wX528Yz4xdW; Fri, 15 Aug 2025 11:11:40 +1000 (AEST) Date: Fri, 15 Aug 2025 11:02:45 +1000 From: David Gibson To: Laurent Vivier Subject: Re: [PATCH v10 28/30] packet: remove unused parameter from PACKET_POOL_DECL() Message-ID: References: <20250814094849.919709-1-lvivier@redhat.com> <20250814094849.919709-29-lvivier@redhat.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="Gc5hNDwC/fFY2IzU" Content-Disposition: inline In-Reply-To: <20250814094849.919709-29-lvivier@redhat.com> Message-ID-Hash: OM6JAUCHFBDKJEFKI57JYRWTWZPWG7SY X-Message-ID-Hash: OM6JAUCHFBDKJEFKI57JYRWTWZPWG7SY 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: 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: --Gc5hNDwC/fFY2IzU Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Aug 14, 2025 at 11:48:47AM +0200, Laurent Vivier wrote: > _buf is not used in the macro. Remove it. > Remove it also from PACKET_POOL_NOINIT() as it was needed > for PACKET_POOL_DECL(). >=20 > Signed-off-by: Laurent Vivier Reviewed-by: David Gibson > --- > packet.h | 6 +++--- > tap.c | 6 +++--- > 2 files changed, 6 insertions(+), 6 deletions(-) >=20 > diff --git a/packet.h b/packet.h > index 286b6b9994db..43b9022075d1 100644 > --- a/packet.h > +++ b/packet.h > @@ -43,7 +43,7 @@ void pool_flush(struct pool *p); > #define packet_get(p, idx, data) \ > packet_get_do(p, idx, data, __func__, __LINE__) > =20 > -#define PACKET_POOL_DECL(_name, _size, _buf) \ > +#define PACKET_POOL_DECL(_name, _size) \ > struct _name ## _t { \ > char *buf; \ > size_t buf_size; \ > @@ -62,7 +62,7 @@ struct _name ## _t { \ > #define PACKET_INIT(name, size, buf, buf_size) \ > (struct name ## _t) PACKET_POOL_INIT_NOCAST(size, buf, buf_size) > =20 > -#define PACKET_POOL_NOINIT(name, size, buf) \ > - PACKET_POOL_DECL(name, size, buf) name ## _storage; \ > +#define PACKET_POOL_NOINIT(name, size) \ > + PACKET_POOL_DECL(name, size) name ## _storage; \ > static struct pool *name =3D (struct pool *)&name ## _storage > #endif /* PACKET_H */ > diff --git a/tap.c b/tap.c > index 99fe810980fd..4e09beac364b 100644 > --- a/tap.c > +++ b/tap.c > @@ -95,8 +95,8 @@ CHECK_FRAME_LEN(L2_MAX_LEN_VU); > ETH_HLEN + sizeof(struct ipv6hdr) + sizeof(struct udphdr)) > =20 > /* IPv4 (plus ARP) and IPv6 message batches from tap/guest to IP handler= s */ > -static PACKET_POOL_NOINIT(pool_tap4, TAP_MSGS_IP4, pkt_buf); > -static PACKET_POOL_NOINIT(pool_tap6, TAP_MSGS_IP6, pkt_buf); > +static PACKET_POOL_NOINIT(pool_tap4, TAP_MSGS_IP4); > +static PACKET_POOL_NOINIT(pool_tap6, TAP_MSGS_IP6); > =20 > #define TAP_SEQS 128 /* Different L4 tuples in one batch */ > #define FRAGMENT_MSG_RATE 10 /* # seconds between fragment warnings */ > @@ -555,7 +555,7 @@ void eth_update_mac(struct ethhdr *eh, > memcpy(eh->h_source, eth_s, sizeof(eh->h_source)); > } > =20 > -PACKET_POOL_DECL(pool_l4, UIO_MAXIOV, pkt_buf); > +PACKET_POOL_DECL(pool_l4, UIO_MAXIOV); > =20 > /** > * struct l4_seq4_t - Message sequence for one protocol handler call, IP= v4 --=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 --Gc5hNDwC/fFY2IzU Content-Type: application/pgp-signature; name=signature.asc -----BEGIN PGP SIGNATURE----- iQIzBAEBCgAdFiEEO+dNsU4E3yXUXRK2zQJF27ox2GcFAmiehzQACgkQzQJF27ox 2GeQDg/+I0EHnRR9zC9nIQ64o+lgvOJE6fC8QJrxXrMoR464Hbd8t3OQC8+74luR 6uI2vvn7FlNRgZfA49zuT2EwXiIcZfMTremxBFy0NDNG+CHcftUxtlf7TEpdAyt/ n9lpyQR3TQL8ews9iUKugx5LdyQJpBO1skUIflz4SOUbSzbEhy8QznNs0mFCijfS Za9oABbDYB5saqaCQrztRFA701tQ3FX/xn3o01pU8yxJjIA1DiuaBwpqvmvVXcgN dQDc2RJ3lTFfsqeXPMoiSUt81YlK1Xd/Ya+IzXj3HyaFUHI9tjcUANjKx7GKfv9R j9AHe0yq6hD8vnMDmwoodWu5lS5ZrSuqsaK7M2MqKq956Y4/yC/cMrfthyTfM7Ei ng8xzOzaKXvpApVh1mpOSNPAkSXNxPmYyuV9LoBTaQ6XrW4gH2vJAlAmo1cvUHk0 CYhBNWd+OQNwmuATuyX5CBLNavMPK1d8XuCKKuze174yrDIN2CjLE09gWu71a7Hr McbBDBYOnDbRyzJl5DxR+7sFgXhxrieN6bTL0gfpc8iMpJN06wxRT70WHJ/GmE0w maA1xHEJ6Q+EPERNV9WyN0JFd9u6ptDjIkeuKLJCZPzBgs9POCJYMN5mZdzD5plA o5VslwcTrdUgOG3cBBKhogKEZCq9ockFyJy8MtdQuKkR5aiP0y8= =87KZ -----END PGP SIGNATURE----- --Gc5hNDwC/fFY2IzU--