From: James Hilliard <james.hilliard1@gmail.com>
To: Andrew Lunn <andrew@lunn.ch>,
Heiner Kallweit <hkallweit1@gmail.com>,
Russell King <linux@armlinux.org.uk>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@kernel.org>,
Jakub Kicinski <kuba@kernel.org>,
Paolo Abeni <pabeni@redhat.com>, Simon Horman <horms@kernel.org>,
Jonathan Corbet <corbet@lwn.net>,
Shuah Khan <skhan@linuxfoundation.org>,
Randy Dunlap <rdunlap@infradead.org>
Cc: Oleksij Rempel <o.rempel@pengutronix.de>,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-doc@vger.kernel.org,
James Hilliard <james.hilliard1@gmail.com>
Subject: [PATCH net-next v6 2/3] ethtool: include errored frames in PHY receive byte counts
Date: Mon, 16 Nov 2026 01:59:58 -0700 [thread overview]
Message-ID: <20261116-submit-acx00-phy-stats-v1-v6-2-8feef8e76cd5@gmail.com> (raw)
In-Reply-To: <20261116-submit-acx00-phy-stats-v1-v6-0-8feef8e76cd5@gmail.com>
Some PHYs count bytes in all received frames, including frames with
errors. A successful-byte count cannot be derived by subtracting a frame
error count because the lengths of damaged frames are not available
separately.
No in-tree PHY driver currently reports rx_bytes. Define this existing
counter to include bytes in frames with errors so drivers can report
their hardware byte count through it. The counter describes reception at
the PHY, independently of MAC or host filtering.
Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
---
include/linux/ethtool.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/linux/ethtool.h b/include/linux/ethtool.h
index c3a41fbd5426..9c3f079d9573 100644
--- a/include/linux/ethtool.h
+++ b/include/linux/ethtool.h
@@ -481,7 +481,7 @@ struct ethtool_eth_phy_stats {
/**
* struct ethtool_phy_stats - PHY-level statistics counters
* @rx_packets: Total successfully received frames
- * @rx_bytes: Total successfully received bytes
+ * @rx_bytes: Total received bytes
* @rx_errors: Total received frames with errors (e.g., CRC errors)
* @tx_packets: Total successfully transmitted frames
* @tx_bytes: Total successfully transmitted bytes
--
2.53.0
next prev parent reply other threads:[~2026-11-16 9:00 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-16 8:59 [PATCH net-next v6 0/3] net: phy: report ACx00 receive statistics James Hilliard
2026-11-16 8:59 ` [PATCH net-next v6 1/3] docs: networking: correct the PHY statistics group name James Hilliard
2026-11-16 8:59 ` James Hilliard [this message]
2026-11-16 8:59 ` [PATCH net-next v6 3/3] net: phy: acx00: report receive statistics James Hilliard
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=20261116-submit-acx00-phy-stats-v1-v6-2-8feef8e76cd5@gmail.com \
--to=james.hilliard1@gmail.com \
--cc=andrew@lunn.ch \
--cc=corbet@lwn.net \
--cc=davem@davemloft.net \
--cc=edumazet@kernel.org \
--cc=hkallweit1@gmail.com \
--cc=horms@kernel.org \
--cc=kuba@kernel.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=netdev@vger.kernel.org \
--cc=o.rempel@pengutronix.de \
--cc=pabeni@redhat.com \
--cc=rdunlap@infradead.org \
--cc=skhan@linuxfoundation.org \
/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
all inboxes | Powered by JetHome®