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=w9y0m+po; dkim-atps=neutral Received: from mail.ozlabs.org (mail.ozlabs.org [IPv6:2404:9400:2221:ea00::3]) by passt.top (Postfix) with ESMTPS id 408045A0283 for ; Wed, 13 Aug 2025 05:27:13 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gibson.dropbear.id.au; s=202508; t=1755055626; bh=st8uR2Mjc+ZA+QfL87ElL+oTuiivFCF86OdQ0g1nVy4=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=w9y0m+po0I1YUyHIzdt1CXORA/xsBTIdNLeFL3AQqbvNynxOSU1RpcSRaxyUEn64C HkS9JwvAkbwDWP1wmoNR/R3aTWf/w2jWCeB30iVB1lpFN0sBr5l+3kBBXRoIJHVpBU gQp6cTib7JCQlItIJPAo9TR+OLMA2wKHOO0Ml2hLT/SOfXhq+HfzLqx+hYvCqLqZs/ UWOwQc6d0G4LgvjGAPyFsFeRpG/K77siy7SjdMxhCcHOpVkZPvc+1xatBD8EXNwVT5 PnEuo8dXiJu4YV6bGH9sBXoQwo5ToOt0IUMYdywmTy7L2HQSnFE6S393wG4gdXxE8Z 53YNDT4m0FKwQ== Received: by gandalf.ozlabs.org (Postfix, from userid 1007) id 4c1v1k5bM8z4xcZ; Wed, 13 Aug 2025 13:27:06 +1000 (AEST) Date: Wed, 13 Aug 2025 13:24:03 +1000 From: David Gibson To: Laurent Vivier Subject: Re: [PATCH v9 28/30] packet: remove unused parameter from PACKET_POOL_DECL() Message-ID: References: <20250808140142.3404325-1-lvivier@redhat.com> <20250808140142.3404325-29-lvivier@redhat.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="MEBjCPH2pULUJ0CW" Content-Disposition: inline In-Reply-To: <20250808140142.3404325-29-lvivier@redhat.com> Message-ID-Hash: 6NTBLYYHUPGIFMJVHH3GKWCU4Z6FVAXH X-Message-ID-Hash: 6NTBLYYHUPGIFMJVHH3GKWCU4Z6FVAXH 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: --MEBjCPH2pULUJ0CW Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Aug 08, 2025 at 04:01:40PM +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 d327ec0c3d54..bbc786468455 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 --MEBjCPH2pULUJ0CW Content-Type: application/pgp-signature; name=signature.asc -----BEGIN PGP SIGNATURE----- iQIzBAEBCgAdFiEEO+dNsU4E3yXUXRK2zQJF27ox2GcFAmicBVIACgkQzQJF27ox 2GdEWBAAnq+AKnusp5R2SONu5rg9TpPucKCcNYsR1lFXGabs8porTL/DyM0J0jKJ zATu3fA4aOUzRg5WVOafETkdKVDLoG3gn2ks66/yj6/Uoi4cPqoBgL6m+G2KHtdg ZBnUKMO0mHB7wc/GG3thXfOtVrekdNW1YuU36RHExMjffbu21c1r2cXpDfvOUvrn iNfSINW2J2kbONLEuTDYaWtfoNkV/9d/NdmmOnzYUQCZyJi3Ta7RqIJIuIdtWBls u1zUtMpwny+toQOppumtQRyQESfCLjdkzy3ZznXY6kKQAxvzq1wjSe549m2ZyqKd vRCH2Z9SZXJSbUgVsTEMcZDO3BSOZP/V0zTypp6p+JSywGuXLpCSuy3lFUC3jX6V s14209uxv9Gmnl2asKGFL/hDFQXmzWPHY/dB4XrNrWYv8CMc7dSWbpztWl4A7Ylu dbnknSPiNCQ2LrUP3D5A8I0C+SujBGuQixouqAM5xstF2Vs/JpQWgf9CNufGvc3k eFL9AO/B3SinBb4Y/e3piZMv/raAQUdwix3zzQr4A4pevi+0VkFobYoc7mqNT693 es8tuWOWyzmgjjeB1CGeqYLtQPydqkXzcVcb6slqoysUXt7lUhBffFd1F0GGuMjF OAls9unFqcv1/EFq/Z77cA2da1bz6tW5n4/Uqv6KnB52b33DoMY= =8Faw -----END PGP SIGNATURE----- --MEBjCPH2pULUJ0CW--