From: Eric Joyner <eric.joyner@amd.com>
To: <netdev@vger.kernel.org>
Cc: Brett Creeley <brett.creeley@amd.com>,
Andrew Lunn <andrew+netdev@lunn.ch>,
"David S. Miller" <davem@davemloft.net>,
"Eric Dumazet" <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
Jacob Keller <jacob.e.keller@intel.com>,
Eric Joyner <eric.joyner@amd.com>
Subject: [PATCH net-next v4 0/5] ionic: Expose more port stats to ethtool
Date: Tue, 9 Jun 2026 23:18:25 -0700 [thread overview]
Message-ID: <20260610061830.51037-1-eric.joyner@amd.com> (raw)
The primary aim of this patchset is to support the reporting of new port
statistics (and one old one) that firmware sends to the driver; these
include general FEC codeword stats and the FEC histogram. A scheme for
these extra stats is introduced in order to prevent devices that don't
support these new statistics from unconditionally setting them or
reporting them in ethtool.
---
v4:
- A big addition is a new scheme where the driver will only report the
new statistics supported by firmware if the firmware sets the statistic
value to something that isn't invalid; more details in patch 3, and this
is used in patch 5 to prevent FEC stats from being unconditionally
reported on devices/firmware versions that don't support these stats.
- The link_down_count from firmware mentioned in v2 was moved back to an
entry in the general ethtool statistics; the existing driver-calculated
value for the ethtool ext link is more appropriate due to the firmware
value being a small size and not resetting between driver loads.
- Add netdev_err_once() call recommended by Sashiko for ethtool handler
- Drop devcmd retry logic patch from previous versions for now;
explicitly include Brett's patch from another patchset to fix the
ionic_get_link_ext_stats() PF/VF check
v3:
Address issues mostly found by Sashiko:
- Fix potential return of uninitialized variable in __ionic_dev_cmd_wait()
- Fix bounds of wait in __ionic_dev_cmd_wait() to prevent function from
giving up prematurely now that the wait period has changed
- Add NULL check to ionic_get_link_ext_stats(), following the example set by
ionic_get_link_ksettings()
- Add missing le16_to_cpu() when copying link_down_count from firmware
v2:
- Add missing cpu_to_le64() to FEC histogram stat assignment
- Remove unused pb_stats field that's replaced by the new FEC/extra stats
- Replace ethtool ext link stat with firmware stat instead of adding
the firmware stat to general ethtool statistics; remove old driver
calculated stat
- Add explanation for what EAGAIN return value could be used for in
commit message
Brett Creeley (1):
ionic: Fix check in ionic_get_link_ext_stats
Eric Joyner (4):
ionic: Update ionic_if.h with new extra port stats
ionic: Report "rx_bits_phy" stat to ethtool
ionic: Report "link_down_events_phy" in ethtool statistics
ionic: Add .get_fec_stats ethtool handler
.../net/ethernet/pensando/ionic/ionic_dev.h | 1 +
.../ethernet/pensando/ionic/ionic_ethtool.c | 83 ++++++++++++++++++-
.../net/ethernet/pensando/ionic/ionic_if.h | 39 +++------
.../net/ethernet/pensando/ionic/ionic_main.c | 6 ++
.../net/ethernet/pensando/ionic/ionic_stats.c | 64 +++++++++++++-
5 files changed, 164 insertions(+), 29 deletions(-)
base-commit: 93790c374b9d77f3db15786d7d432872d92751cf
--
2.17.1
next reply other threads:[~2026-06-10 6:18 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-10 6:18 Eric Joyner [this message]
2026-06-10 6:18 ` [PATCH net-next v4 1/5] ionic: Fix check in ionic_get_link_ext_stats Eric Joyner
2026-06-10 6:18 ` [PATCH net-next v4 2/5] ionic: Update ionic_if.h with new extra port stats Eric Joyner
2026-06-10 6:18 ` [PATCH net-next v4 3/5] ionic: Report "rx_bits_phy" stat to ethtool Eric Joyner
2026-06-10 6:18 ` [PATCH net-next v4 4/5] ionic: Report "link_down_events_phy" in ethtool statistics Eric Joyner
2026-06-10 6:18 ` [PATCH net-next v4 5/5] ionic: Add .get_fec_stats ethtool handler Eric Joyner
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=20260610061830.51037-1-eric.joyner@amd.com \
--to=eric.joyner@amd.com \
--cc=andrew+netdev@lunn.ch \
--cc=brett.creeley@amd.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=jacob.e.keller@intel.com \
--cc=kuba@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
/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