From: Oleksij Rempel <o.rempel@pengutronix.de>
To: James Hilliard <james.hilliard1@gmail.com>
Cc: 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>,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-doc@vger.kernel.org, stable+noautosel@kernel.org
Subject: Re: [PATCH net-next v4 3/3] net: phy: dp83tg720: report inclusive RX packet totals
Date: Fri, 13 Nov 2026 22:39:24 +0100 [thread overview]
Message-ID: <aveDjK-2qZL-4Sm2@pengutronix.de> (raw)
In-Reply-To: <20261113-submit-acx00-phy-stats-v1-v4-3-986b8a4a1871@gmail.com>
On Fri, Nov 13, 2026 at 10:12:07AM -0700, James Hilliard wrote:
> The DP83TG720S-Q1 datasheet describes PKT_STAT_4 and PKT_STAT_5
> (0x063c and 0x063d) as the total received packet count, including packets
> with errors. The driver currently reports this count through rx_packets,
> which is defined as successfully received packets.
>
> Report the accumulated count through rx_packets_total instead. This
> exposes it as RxFramesTotal rather than RxFrames in the ethtool phydev
> statistics group, matching the hardware counter's semantics.
>
> Fixes: 677d895af1cc ("net: phy: dp83tg720: add statistics support")
> Link: https://www.ti.com/lit/ds/symlink/dp83tg720s-q1.pdf
> Cc: <stable+noautosel@kernel.org> # Requires the new PHY receive-total statistics API
> Cc: Oleksij Rempel <o.rempel@pengutronix.de>
> Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
I do not think this patch should go in. Please drop it from the series.
Patches 1 and 2 do not depend on it; dp83tg720 can keep reporting
rx_packets as it does today.
The datasheet (SNLS604G) does not say that this count includes frames
with errors. Tables 7-80 and 7-81 describe the fields only as the lower
and upper 16 bits of the Rx packet counter. Section 6.3.1.3 and Table 6-2
list a total packet count and a count of packets with errors. They do
not say whether the total includes those packets. The word "total" alone
does not settle it.
Before the reported value changes, I need either a test or other TI
documentation that shows whether the counter includes frames with
CRC errors.
Even if it turns out that the counter includes frames with CRC errors, I
would rather subtract the CRC error count (RxErrors) in the driver and
keep rx_packets with its documented meaning than change the interface
for existing users.
Oleksij
prev parent reply other threads:[~2026-11-13 21:39 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-13 17:12 [PATCH net-next v4 0/3] ethtool: expose PHY receive totals James Hilliard
2026-11-13 17:12 ` [PATCH net-next v4 1/3] ethtool: add PHY receive frame and byte totals James Hilliard
2026-11-13 20:55 ` Andrew Lunn
2026-11-13 17:12 ` [PATCH net-next v4 2/3] net: phy: acx00: report receive statistics James Hilliard
2026-11-13 17:12 ` [PATCH net-next v4 3/3] net: phy: dp83tg720: report inclusive RX packet totals James Hilliard
2026-11-13 21:39 ` Oleksij Rempel [this message]
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=aveDjK-2qZL-4Sm2@pengutronix.de \
--to=o.rempel@pengutronix.de \
--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=james.hilliard1@gmail.com \
--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=pabeni@redhat.com \
--cc=rdunlap@infradead.org \
--cc=skhan@linuxfoundation.org \
--cc=stable+noautosel@kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.