From: Simon Horman <horms@kernel.org>
To: Jakub Kicinski <kuba@kernel.org>
Cc: Peter Seiderer <ps.report@gmx.net>,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-kselftest@vger.kernel.org,
"David S . Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Paolo Abeni <pabeni@redhat.com>, Shuah Khan <shuah@kernel.org>,
Artem Chernyshev <artem.chernyshev@red-soft.ru>,
Nam Cao <namcao@linutronix.de>,
Frederic Weisbecker <frederic@kernel.org>
Subject: Re: [PATCH net-next v5 8/8] net: pktgen: use defines for the various dec/hex number parsing digits lengths
Date: Tue, 18 Feb 2025 13:29:05 +0000 [thread overview]
Message-ID: <20250218132905.GV1615191@kernel.org> (raw)
In-Reply-To: <20250217094740.76a25671@kernel.org>
On Mon, Feb 17, 2025 at 09:47:40AM -0800, Jakub Kicinski wrote:
> On Sun, 16 Feb 2025 09:17:39 +0000 Simon Horman wrote:
> > On Fri, Feb 14, 2025 at 08:11:45PM -0800, Jakub Kicinski wrote:
> > > On Thu, 13 Feb 2025 12:00:25 +0100 Peter Seiderer wrote:
> > > > Use defines for the various dec/hex number parsing digits lengths
> > > > (hex32_arg/num_arg calls).
> > >
> > > I don't understand the value of this patch, TBH.
> > >
> > > Example:
> > >
> > > +#define HEX_2_DIGITS 2
> > >
> > > - len = hex32_arg(&user_buffer[i], 2, &tmp_value);
> > > + len = hex32_arg(&user_buffer[i], HEX_2_DIGITS, &tmp_value);
> > >
> > > The word hex is already there.
> > > There is still a two.
> > > I don't think the new define has any explanatory power?
> > >
> > > Previous 7 patches look ready indeed.
> >
> > This one is on me. I felt the magic number 2 and so on
> > was unclear. But if you prefer the code as-is that is fine by me too.
>
> I agree that it's a bit hard to guess what the call does and what
> the arguments are. To me at least, the constants as named don't help.
> We can get a third opinion, or if none is provided skip the patch for
> now?
Yes, I see your point.
No objections from me to skipping this patch.
next prev parent reply other threads:[~2025-02-18 13:29 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-02-13 11:00 [PATCH net-next v5 0/8] Some pktgen fixes/improvments (part I) Peter Seiderer
2025-02-13 11:00 ` [PATCH net-next v5 1/8] net: pktgen: replace ENOTSUPP with EOPNOTSUPP Peter Seiderer
2025-02-13 11:00 ` [PATCH net-next v5 2/8] net: pktgen: enable 'param=value' parsing Peter Seiderer
2025-02-16 9:21 ` Simon Horman
2025-02-13 11:00 ` [PATCH net-next v5 3/8] net: pktgen: fix hex32_arg parsing for short reads Peter Seiderer
2025-02-13 11:00 ` [PATCH net-next v5 4/8] net: pktgen: fix 'rate 0' error handling (return -EINVAL) Peter Seiderer
2025-02-13 11:00 ` [PATCH net-next v5 5/8] net: pktgen: fix 'ratep " Peter Seiderer
2025-02-13 11:00 ` [PATCH net-next v5 6/8] net: pktgen: fix ctrl interface command parsing Peter Seiderer
2025-02-13 11:00 ` [PATCH net-next v5 7/8] net: pktgen: fix access outside of user given buffer in pktgen_thread_write() Peter Seiderer
2025-02-13 11:00 ` [PATCH net-next v5 8/8] net: pktgen: use defines for the various dec/hex number parsing digits lengths Peter Seiderer
2025-02-15 4:11 ` Jakub Kicinski
2025-02-16 9:17 ` Simon Horman
2025-02-17 17:47 ` Jakub Kicinski
2025-02-18 13:29 ` Simon Horman [this message]
2025-02-19 8:30 ` Peter Seiderer
2025-02-18 12:32 ` Edward Cree
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250218132905.GV1615191@kernel.org \
--to=horms@kernel.org \
--cc=artem.chernyshev@red-soft.ru \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=frederic@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=namcao@linutronix.de \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=ps.report@gmx.net \
--cc=shuah@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.