Netdev List
 help / color / mirror / Atom feed
From: Jakub Kicinski <kuba@kernel.org>
To: davem@davemloft.net
Cc: netdev@vger.kernel.org, edumazet@google.com, pabeni@redhat.com,
	andrew+netdev@lunn.ch, horms@kernel.org,
	Jakub Kicinski <kuba@kernel.org>,
	brett.creeley@amd.com, eric.joyner@amd.com, leitao@debian.org
Subject: [PATCH net-next] eth: ionic: delete the incorrect link_down_count reporting
Date: Mon, 15 Jun 2026 10:01:53 -0700	[thread overview]
Message-ID: <20260615170153.592171-1-kuba@kernel.org> (raw)

The definition of the statistic is quite clear,
struct ethtool_link_ext_stats says:

   This statistic counts when PHY _actually_ went down, or lost link.

Reportedly this is not how the device-counted stat on ionic behaves.
The goal is to detect flapping links, due to bad cabling.
ionic reportedly uses this for some firmware stat of how many times
the traffic was stopped. This is _not_ what should be reported here.

Link: https://lore.kernel.org/20260610061830.51037-1-eric.joyner@amd.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
---
CC: brett.creeley@amd.com
CC: eric.joyner@amd.com
CC: leitao@debian.org
---
 drivers/net/ethernet/pensando/ionic/ionic_ethtool.c | 10 ----------
 1 file changed, 10 deletions(-)

diff --git a/drivers/net/ethernet/pensando/ionic/ionic_ethtool.c b/drivers/net/ethernet/pensando/ionic/ionic_ethtool.c
index 78a802eb159f..f7dcfe3d032d 100644
--- a/drivers/net/ethernet/pensando/ionic/ionic_ethtool.c
+++ b/drivers/net/ethernet/pensando/ionic/ionic_ethtool.c
@@ -111,15 +111,6 @@ static void ionic_get_regs(struct net_device *netdev, struct ethtool_regs *regs,
 	memcpy_fromio(p + offset, idev->dev_cmd_regs->words, size);
 }
 
-static void ionic_get_link_ext_stats(struct net_device *netdev,
-				     struct ethtool_link_ext_stats *stats)
-{
-	struct ionic_lif *lif = netdev_priv(netdev);
-
-	if (lif->ionic->pdev->is_physfn)
-		stats->link_down_events = lif->link_down_count;
-}
-
 static int ionic_get_link_ksettings(struct net_device *netdev,
 				    struct ethtool_link_ksettings *ks)
 {
@@ -1132,7 +1123,6 @@ static const struct ethtool_ops ionic_ethtool_ops = {
 	.get_regs_len		= ionic_get_regs_len,
 	.get_regs		= ionic_get_regs,
 	.get_link		= ethtool_op_get_link,
-	.get_link_ext_stats	= ionic_get_link_ext_stats,
 	.get_link_ksettings	= ionic_get_link_ksettings,
 	.set_link_ksettings	= ionic_set_link_ksettings,
 	.get_coalesce		= ionic_get_coalesce,
-- 
2.54.0


             reply	other threads:[~2026-06-15 17:01 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-15 17:01 Jakub Kicinski [this message]
2026-06-15 17:14 ` [PATCH net-next] eth: ionic: delete the incorrect link_down_count reporting Breno Leitao
2026-06-15 17:29   ` Creeley, Brett

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=20260615170153.592171-1-kuba@kernel.org \
    --to=kuba@kernel.org \
    --cc=andrew+netdev@lunn.ch \
    --cc=brett.creeley@amd.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=eric.joyner@amd.com \
    --cc=horms@kernel.org \
    --cc=leitao@debian.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