[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250130102451.46a4b247@kmaincent-XPS-13-7390>
Date: Thu, 30 Jan 2025 10:24:51 +0100
From: Kory Maincent <kory.maincent@...tlin.com>
To: Jakub Kicinski <kuba@...nel.org>
Cc: Willem de Bruijn <willemdebruijn.kernel@...il.com>, "David S. Miller"
<davem@...emloft.net>, Eric Dumazet <edumazet@...gle.com>, Paolo Abeni
<pabeni@...hat.com>, Simon Horman <horms@...nel.org>, Donald Hunter
<donald.hunter@...il.com>, Thomas Petazzoni <thomas.petazzoni@...tlin.com>,
linux-kernel@...r.kernel.org, netdev@...r.kernel.org
Subject: Re: [PATCH net 2/3] net: ethtool: tsconfig: Fix ts filters and
types enums size check
On Wed, 29 Jan 2025 16:45:08 -0800
Jakub Kicinski <kuba@...nel.org> wrote:
> On Tue, 28 Jan 2025 16:35:47 +0100 Kory Maincent wrote:
> > Fix the size check for the hwtstamp_tx_types and hwtstamp_rx_filters
> > enumerations.
>
> This is just a code cleanup, the constants are way smaller than 32
> today. The assert being too restrictive makes no functional difference.
That's right, it was mainly for consistency with the other assert. And to avoid
possible future mistake but indeed reaching 32 bit is not expected soon. Should
I remove the patch as it is not a functional issue?
> > Align this check with the approach used in tsinfo for
> > consistency and correctness.
>
> First-principles based explanation of why 32 is the correct value would
> be much better than just alignment. Otherwise reviewer has to figure out
> whether we should be changing from >= to > or vice versa...
Ack, I will if I keep the patch.
Regards,
--
Köry Maincent, Bootlin
Embedded Linux and kernel engineering
https://bootlin.com
Powered by blists - more mailing lists