lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <zsoujuddzajo3qbrvde6rnzeq6ic5x7jofz3voab7dmtzh3zpw@h3bxd54btzic>
Date: Wed, 29 Oct 2025 17:26:46 +0100
From: Michal Kubecek <mkubecek@...e.cz>
To: Vadim Fedorenko <vadim.fedorenko@...ux.dev>
Cc: Jakub Kicinski <kuba@...nel.org>, netdev@...r.kernel.org, 
	Kory Maincent <kory.maincent@...tlin.com>
Subject: Re: [PATCH ethtool-next] netlink: tsconfig: add HW time stamping
 configuration

On Tue, Oct 28, 2025 at 09:48:00PM GMT, Vadim Fedorenko wrote:
> On 26/10/2025 16:57, Michal Kubecek wrote:
> > On Sat, Oct 04, 2025 at 08:27:15PM GMT, Vadim Fedorenko wrote:
> > > The kernel supports configuring HW time stamping modes via netlink
> > > messages, but previous implementation added support for HW time stamping
> > > source configuration. Add support to configure TX/RX time stamping.
> > > 
> > > Signed-off-by: Vadim Fedorenko <vadim.fedorenko@...ux.dev>
> > 
> > As far as I can see, you only allow one bit to be set in each of
> > ETHTOOL_A_TSCONFIG_TX_TYPES and ETHTOOL_A_TSCONFIG_RX_FILTERS. If only
> > one bit is supposed to be set, why are they passed as bitmaps?
> > (The netlink interface only mirrors what (read-only) ioctl interface
> > did.)
> 
> Well, yes, it's only 1 bit is supposed to be set. Unfortunately, netlink
> interface was added this way almost a year ago, we cannot change it
> anymore without breaking user-space API.

The netlink interface only mirrors what we already had in struct
ethtool_ts_info (i.e. the ioctl interface). Therefore my question was
not really about this part of kernel API (which is fixed already) but
rather about the ethtool command line syntax.

In other words, what I really want to ask is: Can we be absolutely sure
that it can never possibly happen in the future that we might need to
set more than one bit in a set message?

If the answer is positive, I'm OK with the patch but perhaps we should
document it explicitly in the TSCONFIG_SET description in kernel file
Documentation/networking/ethtool-netlink.rst

Michal

Download attachment "signature.asc" of type "application/pgp-signature" (485 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ