[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20251023181012.6bf107a6@kernel.org>
Date: Thu, 23 Oct 2025 18:10:12 -0700
From: Jakub Kicinski <kuba@...nel.org>
To: Oleksij Rempel <o.rempel@...gutronix.de>
Cc: Andrew Lunn <andrew@...n.ch>, "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>,
Jonathan Corbet <corbet@....net>, Heiner Kallweit <hkallweit1@...il.com>,
Russell King <linux@...linux.org.uk>, Kory Maincent
<kory.maincent@...tlin.com>, Maxime Chevallier
<maxime.chevallier@...tlin.com>, Nishanth Menon <nm@...com>,
kernel@...gutronix.de, linux-kernel@...r.kernel.org,
netdev@...r.kernel.org, UNGLinuxDriver@...rochip.com,
linux-doc@...r.kernel.org, Michal Kubecek <mkubecek@...e.cz>, Roan van Dijk
<roan@...tonic.nl>
Subject: Re: [PATCH net-next v7 3/5] ethtool: netlink: add lightweight MSE
reporting to LINKSTATE_GET
On Mon, 20 Oct 2025 12:31:45 +0200 Oleksij Rempel wrote:
> Extend ETHTOOL_MSG_LINKSTATE_GET to optionally return a simplified
> Mean Square Error (MSE) reading alongside existing link status fields.
>
> The new attributes are:
> - ETHTOOL_A_LINKSTATE_MSE_VALUE: current average MSE value
> - ETHTOOL_A_LINKSTATE_MSE_MAX: scale limit for the reported value
> - ETHTOOL_A_LINKSTATE_MSE_CHANNEL: source channel selector
>
> This path reuses the PHY MSE core API (struct phy_mse_capability and
> struct phy_mse_snapshot), but only retrieves a single value intended for
> quick link-health checks:
> * If the PHY supports a WORST channel selector, report its current
> average MSE.
> * Otherwise, if LINK-wide measurements are supported, report those.
> * If neither is available, omit the attributes.
>
> Unlike the full MSE_GET interface, LINKSTATE_GET does not expose
> per-channel or peak/worst-peak values and incurs minimal overhead.
> Drivers that implement get_mse_capability() / get_mse_snapshot() will
> automatically populate this data.
>
> The intent is to provide tooling with a "fast path" health indicator
> without issuing a separate MSE_GET request, though the long-term overlap
> with the full interface may need reevaluation.
I don't think this justification is sufficient, we don't normally
duplicate information in uAPI to make user space have to issue
fewer calls. ethtool $link already issues a number of calls to
the kernel.
Powered by blists - more mailing lists