linux-doc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Oleksij Rempel <o.rempel@pengutronix.de>
To: Kory Maincent <kory.maincent@bootlin.com>
Cc: Andrew Lunn <andrew@lunn.ch>, Jakub Kicinski <kuba@kernel.org>,
	"David S. Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@google.com>,
	Paolo Abeni <pabeni@redhat.com>, Simon Horman <horms@kernel.org>,
	Donald Hunter <donald.hunter@gmail.com>,
	Jonathan Corbet <corbet@lwn.net>,
	Heiner Kallweit <hkallweit1@gmail.com>,
	Russell King <linux@armlinux.org.uk>,
	Maxime Chevallier <maxime.chevallier@bootlin.com>,
	Nishanth Menon <nm@ti.com>,
	kernel@pengutronix.de, linux-kernel@vger.kernel.org,
	netdev@vger.kernel.org, UNGLinuxDriver@microchip.com,
	linux-doc@vger.kernel.org, Michal Kubecek <mkubecek@suse.cz>,
	Roan van Dijk <roan@protonic.nl>
Subject: Re: [PATCH net-next v4 2/5] ethtool: netlink: add ETHTOOL_MSG_MSE_GET and wire up PHY MSE access
Date: Thu, 21 Aug 2025 12:15:48 +0200	[thread overview]
Message-ID: <aKbx1EoO0iWe2bMU@pengutronix.de> (raw)
In-Reply-To: <20250821115830.3a231885@kmaincent-XPS-13-7390>

Hello Kory,

On Thu, Aug 21, 2025 at 11:59:14AM +0200, Kory Maincent wrote:
> Hello Oleksij,
> 
> Le Thu, 21 Aug 2025 11:10:58 +0200,
> Oleksij Rempel <o.rempel@pengutronix.de> a écrit :
> 
> > Introduce the userspace entry point for PHY MSE diagnostics via
> > ethtool netlink. This exposes the core API added previously and
> > returns both configuration and one or more snapshots.
> > 
> > Userspace sends ETHTOOL_MSG_MSE_GET with an optional channel
> > selector. The reply carries:
> >   - ETHTOOL_A_MSE_CONFIG: scale limits, timing, and supported
> >     capability bitmask
> >   - ETHTOOL_A_MSE_SNAPSHOT+: one or more snapshots, each tagged
> >     with the selected channel
> > 
> > If no channel is requested, the kernel returns snapshots for all
> > supported selectors (per‑channel if available, otherwise WORST,
> > otherwise LINK). Requests for unsupported selectors fail with
> > -EOPNOTSUPP; link down returns -ENOLINK.
> > 
> > Changes:
> >   - YAML: add attribute sets (mse, mse-config, mse-snapshot) and
> >     the mse-get operation
> >   - UAPI (generated): add ETHTOOL_A_MSE_* enums and message IDs,
> >     ETHTOOL_MSG_MSE_GET/REPLY
> >   - ethtool core: add net/ethtool/mse.c implementing the request,
> >     register genl op, and hook into ethnl dispatch
> >   - docs: document MSE_GET in ethtool-netlink.rst
> > 
> > The include/uapi/linux/ethtool_netlink_generated.h is generated
> > from Documentation/netlink/specs/ethtool.yaml.
> > 
> > Signed-off-by: Oleksij Rempel <o.rempel@pengutronix.de>
> 
> ...
> 
> > +MSE Configuration
> > +-----------------
> > +
> > +This nested attribute contains the full configuration properties for the MSE
> > +measurements
> > +
> > +  ===============================================  ======
> > ====================
> > +  ETHTOOL_A_MSE_CONFIG_MAX_AVERAGE_MSE             u32     max avg_mse scale
> > +  ETHTOOL_A_MSE_CONFIG_MAX_PEAK_MSE                u32     max peak_mse scale
> > +  ETHTOOL_A_MSE_CONFIG_REFRESH_RATE_PS             u64     sample rate (ps)
> > +  ETHTOOL_A_MSE_CONFIG_NUM_SYMBOLS                 u64     symbols per sample
> > +  ETHTOOL_A_MSE_CONFIG_SUPPORTED_CAPS              bitset  capability bitmask
> > +  ===============================================  ======
> > ==================== +
> 
> Why did you remove the kernel doc identifiers to phy_mse_config?
> It was useful for the documentation.
> 
> > +MSE Snapshot
> > +------------
> > +
> > +This nested attribute contains an atomic snapshot of MSE values for a
> > specific +channel or for the link as a whole.
> > +
> > +  ===============================================  ======
> > ======================
> > +  ETHTOOL_A_MSE_SNAPSHOT_CHANNEL                   u32     channel enum value
> > +  ETHTOOL_A_MSE_SNAPSHOT_AVERAGE_MSE               u32     average MSE value
> > +  ETHTOOL_A_MSE_SNAPSHOT_PEAK_MSE                  u32     current peak MSE
> > +  ETHTOOL_A_MSE_SNAPSHOT_WORST_PEAK_MSE            u32     worst-case peak
> > MSE
> > +  ===============================================  ======
> 
> Same question here for phy_mse_snapshot.

I had following warnings:
Documentation/networking/ethtool-netlink:2499: ./include/linux/phy.h:3: WARNING: Duplicate C declaration, also defined at kapi:892. 
Declaration is '.. c:struct:: phy_mse_config'. 
Documentation/networking/ethtool-netlink:2515: ./include/linux/phy.h:3: WARNING: Duplicate C declaration, also defined at kapi:915.
Declaration is '.. c:struct:: phy_mse_snapshot'

I didn't found proper was to solve it, so I removed them.

-- 
Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | http://www.pengutronix.de/  |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

  reply	other threads:[~2025-08-21 10:16 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-08-21  9:10 [PATCH net-next v4 0/5] ethtool: introduce PHY MSE diagnostics UAPI and drivers Oleksij Rempel
2025-08-21  9:10 ` [PATCH net-next v4 1/5] ethtool: introduce core UAPI and driver API for PHY MSE diagnostics Oleksij Rempel
2025-08-21  9:10 ` [PATCH net-next v4 2/5] ethtool: netlink: add ETHTOOL_MSG_MSE_GET and wire up PHY MSE access Oleksij Rempel
2025-08-21  9:59   ` Kory Maincent
2025-08-21 10:15     ` Oleksij Rempel [this message]
2025-08-21 12:47       ` Kory Maincent
2025-08-21  9:10 ` [PATCH net-next v4 3/5] ethtool: netlink: add lightweight MSE reporting to LINKSTATE_GET Oleksij Rempel
2025-08-21  9:11 ` [PATCH net-next v4 4/5] net: phy: micrel: add MSE interface support for KSZ9477 family Oleksij Rempel
2025-08-21  9:11 ` [PATCH net-next v4 5/5] net: phy: dp83td510: add MSE interface support for 10BASE-T1L Oleksij Rempel

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=aKbx1EoO0iWe2bMU@pengutronix.de \
    --to=o.rempel@pengutronix.de \
    --cc=UNGLinuxDriver@microchip.com \
    --cc=andrew@lunn.ch \
    --cc=corbet@lwn.net \
    --cc=davem@davemloft.net \
    --cc=donald.hunter@gmail.com \
    --cc=edumazet@google.com \
    --cc=hkallweit1@gmail.com \
    --cc=horms@kernel.org \
    --cc=kernel@pengutronix.de \
    --cc=kory.maincent@bootlin.com \
    --cc=kuba@kernel.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=maxime.chevallier@bootlin.com \
    --cc=mkubecek@suse.cz \
    --cc=netdev@vger.kernel.org \
    --cc=nm@ti.com \
    --cc=pabeni@redhat.com \
    --cc=roan@protonic.nl \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).