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=QooVZ7fN; dkim-atps=neutral Received: from mail.ozlabs.org (gandalf.ozlabs.org [150.107.74.76]) by passt.top (Postfix) with ESMTPS id B29145A0262 for ; Tue, 03 Mar 2026 23:53:23 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gibson.dropbear.id.au; s=202602; t=1772578400; bh=g9lpsUEQz+/2AzNPRFGyVaWbdlvZBv0hmvgJHiSjc54=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=QooVZ7fN8cXnwsfrAaujqR+rZeILt7tomTUE+G7N4GW+LXGX4Q2blBDCEnWo3yDpQ MY74czljUtRH+bX6vF7Fc4cXxdWWS/dyUCjePjveX8NSkgyDIJti2iNB0zvxOmpWIM NZ54wc9roROiU1JnAWLUxGRdooBbMEWNsAsWVZLhVxk5TYMMN34pklo1aIvlXd8Pcl J3lbSZiEOyNStXGjJTiLwzhvb3+SGT4xoyExYtMXvT3n+1khwQ34aqR2wGkfs0Qh3z ppksA5SOScRvVERF684VxTkGJop4UNBEIpkSdcwDhD3dzEePtWlLXzSTVpce4AseNB pwHzzUlGIPkkQ== Received: by gandalf.ozlabs.org (Postfix, from userid 1007) id 4fQWL829Qhz4wCk; Wed, 04 Mar 2026 09:53:20 +1100 (AEDT) Date: Wed, 4 Mar 2026 09:51:48 +1100 From: David Gibson To: Stefano Brivio Subject: Re: [PATCH trivial] checksum: fix clang-tidy error Message-ID: References: <20260226162451.1717333-1-lvivier@redhat.com> <20260303201131.2cf8b06c@elisabeth> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="6ZrueNna0zxMfgrw" Content-Disposition: inline In-Reply-To: <20260303201131.2cf8b06c@elisabeth> Message-ID-Hash: MTMIW7YIZZD2MO6MFQBEMPBE7SAGFGSW X-Message-ID-Hash: MTMIW7YIZZD2MO6MFQBEMPBE7SAGFGSW 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, jfiusdq@proton.me 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: --6ZrueNna0zxMfgrw Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Mar 03, 2026 at 08:11:32PM +0100, Stefano Brivio wrote: > On Thu, 26 Feb 2026 17:24:51 +0100 > Laurent Vivier wrote: >=20 > > Fix the following error reported by clang-tidy > >=20 > > $ make clang-tidy > > ... > > checksum.c:284:2: error: preprocessor condition can be written more con= cisely using '#ifdef' [readability-use-concise-preprocessor-directives,-war= nings-as-errors] > > 284 | #if defined(__AVX2__) > > | ^~ ~~~~~~~~~~~~~~~~~ > > | ifdef __AVX2__ > >=20 > > Fixes: 036fb8770cc2 ("checksum: add VSX fast path for POWER8/POWER9") > > Cc: jfiusdq@proton.me > > Signed-off-by: Laurent Vivier > > --- > > checksum.c | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > >=20 > > diff --git a/checksum.c b/checksum.c > > index 828f9ecc9c02..bfba6f78b293 100644 > > --- a/checksum.c > > +++ b/checksum.c > > @@ -281,7 +281,7 @@ void csum_icmp6(struct icmp6hdr *icmp6hr, > > icmp6hr->icmp6_cksum =3D csum(payload, dlen, psum); > > } > > =20 > > -#if defined(__AVX2__) > > +#ifdef __AVX2__ > > #include > > =20 > > /** >=20 > This (conceptually) conflicts with a newer patch: >=20 > [PATCH 3/3] clang-tidy: Don't insist on #ifdef over #if defined() > https://archives.passt.top/passt-dev/20260302043135.800803-4-david@gibs= on.dropbear.id.au/ >=20 > which, Laurent mentioned offline, is preferable to this in his view. >=20 > So I'm going to drop this (while carrying the Fixes: tag and adding a > Reported-by:) in favour of that one. Somehow I entirely missed Laurent's mail. Thanks for fixing this up. --=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 --6ZrueNna0zxMfgrw Content-Type: application/pgp-signature; name=signature.asc -----BEGIN PGP SIGNATURE----- iQIzBAEBCgAdFiEEO+dNsU4E3yXUXRK2zQJF27ox2GcFAmmnZfoACgkQzQJF27ox 2GddBA/6As1e/R+jmlQ2jVs1xTdBJoM6tsWjuWhpND/Qx3KSuvAHYlFAsKOGmRTf S/9lmx4F1R66pYu/ep5Swkf4IyGbrnaV/+M4UBC6Q8bofj7a6nHIFMNArIl4JmP1 KMIpDjivrQjeuX+kgQFRZbfFudeBkqC4IVT0Dej9YtWroMa1enOqrSmZpVrMPFTD qkLAOmjIEerS9AK5RH1RBuCBS99lmW5PzSNbzdD8o33ryAeTaTvlk9MCwXskTQKx 3Kp4tRvrOtfv62Vi8Ndz7yuqFf+OUQWM5jvi+fbQOrKtvBEiG3gK7D6qeqE7sn+i WlgafpkeWEFg9VfuFsHlLC9AL23jTayJWg4hRYGYxCBrphNFcvVqdDr8J9jMzFd7 3THIQQUq5iXm6injpsqxbzPfCwXUlcQ9W40PoNOQnc6bFzOzN1oW0Dhf1GBxzLjm 1xgmUi+u/0+Xwi3AAcmKXTO9tEttBY10keAm0rNXHsnySmuI2H2pPSoRZ63kBMld prd8L/ea9yjqLxqwbegkyy9UCo4Fl4eQxSYjWBnsEzXhjbwRwbj/4y1efoJ2Kq7F DfqZLlu7gzlt7vMhCVhTz6mDNyZbKfm4WqzVdwZvs6sw6HnGhO7WHIJBfDXJ2t9y 9GnOg4kyeWVzc50t/9D6dkVXJckjflUUV5WCq8Qe0OLMw2dOPdA= =dKtG -----END PGP SIGNATURE----- --6ZrueNna0zxMfgrw--