Subject: Re: [RFC net-next 1/2] net: ethtool: plumb PHY stats to PHY drivers

From: Jakub Kicinski <[email-masked]>
Date: Thu, 29 Aug 2024 12:13:01 -0700

On Thu, 29 Aug 2024 20:10:00 +0200 Oleksij Rempel wrote:
> On Thu, Aug 29, 2024 at 10:43:41AM -0700, Jakub Kicinski wrote:
> > Feed the existing IEEE PHY counter struct (which currently
> > only has one entry) and link stats into the PHY driver.
> > The MAC driver can override the value if it somehow has a better
> > idea of PHY stats. Since the stats are "undefined" at input
> > the drivers can't += the values, so we should be safe from
> > double-counting.
> > 
> > Vladimir, I don't understand MM but doesn't MM share the PHY?
> > Ocelot seems to aggregate which I did not expect.
> > 
> > Signed-off-by: Jakub Kicinski <[email-masked]>  
> 
> Huh.. it is completely different compared to what I was thinking.
> If I see it correctly, it will help to replace missing HW stats for some
> MACs like ASIX. But it will fail to help diagnose MAC-PHY connections
> issues like, wrong RGMII configurations or other kind of damages on the
> PCB. Right?

This is just a pre-req for the next patch, to let phy drivers report
the (very few) stats we have already defined for integrated NIC drivers.
What statistics we choose to add later is up to us, this is just
groundwork.

BTW the series is primarily to allow you to report the packet / error
and OA stats in a structured way, it's not related directly by the
discussion on T1L troubleshooting.