Re: [PATCH net-next 5/7] bng_en: add initial support for ethtool stats display
From: Bhargava Chenna Marreddy
Date: Tue Feb 24 2026 - 14:51:16 EST
On Tue, Feb 24, 2026 at 1:22 AM Andrew Lunn <andrew@xxxxxxx> wrote:
>
> > + BNGE_RX_STATS_ENTRY(rx_64b_frames),
> > + BNGE_RX_STATS_ENTRY(rx_65b_127b_frames),
> > + BNGE_RX_STATS_ENTRY(rx_128b_255b_frames),
> > + BNGE_RX_STATS_ENTRY(rx_256b_511b_frames),
> > + BNGE_RX_STATS_ENTRY(rx_512b_1023b_frames),
> > + BNGE_RX_STATS_ENTRY(rx_1024b_1518b_frames),
> > + BNGE_RX_STATS_ENTRY(rx_good_vlan_frames),
> > + BNGE_RX_STATS_ENTRY(rx_1519b_2047b_frames),
> > + BNGE_RX_STATS_ENTRY(rx_2048b_4095b_frames),
> > + BNGE_RX_STATS_ENTRY(rx_4096b_9216b_frames),
> > + BNGE_RX_STATS_ENTRY(rx_9217b_16383b_frames),
>
> > + BNGE_TX_STATS_ENTRY(tx_64b_frames),
> > + BNGE_TX_STATS_ENTRY(tx_65b_127b_frames),
> > + BNGE_TX_STATS_ENTRY(tx_128b_255b_frames),
> > + BNGE_TX_STATS_ENTRY(tx_256b_511b_frames),
> > + BNGE_TX_STATS_ENTRY(tx_512b_1023b_frames),
> > + BNGE_TX_STATS_ENTRY(tx_1024b_1518b_frames),
> > + BNGE_TX_STATS_ENTRY(tx_good_vlan_frames),
> > + BNGE_TX_STATS_ENTRY(tx_1519b_2047b_frames),
> > + BNGE_TX_STATS_ENTRY(tx_2048b_4095b_frames),
> > + BNGE_TX_STATS_ENTRY(tx_4096b_9216b_frames),
> > + BNGE_TX_STATS_ENTRY(tx_9217b_16383b_frames),
>
> These look like rmon stats, which should be returned by the ethtool
> .get_rmon_stats call. Please take a look at the documentation of
>
> * @get_eth_phy_stats: Query some of the IEEE 802.3 PHY statistics.
> * @get_eth_mac_stats: Query some of the IEEE 802.3 MAC statistics.
> * @get_eth_ctrl_stats: Query some of the IEEE 802.3 MAC Ctrl statistics.
>
> and see if you should be using these as well.
Hi Andrew,
Thanks for pointing this out. We'll review the stats and map them to
the appropriate structured callbacks (.get_rmon_stats, .get_eth_phy_stats,
.get_eth_mac_stats & .get_eth_ctrl_stats).
To make sure we get v2 right -- should these stats be moved entirely to
the structured callbacks, or should they remain in .get_ethtool_stats as well?
Thanks,
Bhargava Marreddy
>
> Andrew
Attachment:
smime.p7s
Description: S/MIME Cryptographic Signature