[net-next,v2,1/2] dsa: lan9303: Change stat name

Message ID 20221115165131.11467-1-jerry.ray@microchip.com
State New
Headers
Series [net-next,v2,1/2] dsa: lan9303: Change stat name |

Commit Message

Jerry Ray Nov. 15, 2022, 4:51 p.m. UTC
  This patch changes the reported ethtool statistics for the lan9303
family of parts covered by this driver.

The TxUnderRun statistic label is renamed to RxShort to accurately
reflect what stat the device is reporting.  I did not reorder the
statistics as that might cause problems with existing user code that
are expecting the stats at a certain offset.

Signed-off-by: Jerry Ray <jerry.ray@microchip.com>
---
v1->v2:
  Split patch into 2 pieces.
---
 drivers/net/dsa/lan9303-core.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
  

Comments

Andrew Lunn Nov. 15, 2022, 5:30 p.m. UTC | #1
On Tue, Nov 15, 2022 at 10:51:30AM -0600, Jerry Ray wrote:
> This patch changes the reported ethtool statistics for the lan9303
> family of parts covered by this driver.
> 
> The TxUnderRun statistic label is renamed to RxShort to accurately
> reflect what stat the device is reporting.  I did not reorder the
> statistics as that might cause problems with existing user code that
> are expecting the stats at a certain offset.
> 
> Signed-off-by: Jerry Ray <jerry.ray@microchip.com>

Reviewed-by: Andrew Lunn <andrew@lunn.ch>

    Andrew
  
Florian Fainelli Nov. 16, 2022, 5:08 p.m. UTC | #2
On 11/15/2022 8:51 AM, Jerry Ray wrote:
> This patch changes the reported ethtool statistics for the lan9303
> family of parts covered by this driver.
> 
> The TxUnderRun statistic label is renamed to RxShort to accurately
> reflect what stat the device is reporting.  I did not reorder the
> statistics as that might cause problems with existing user code that
> are expecting the stats at a certain offset.
> 
> Signed-off-by: Jerry Ray <jerry.ray@microchip.com>

This looks like a bugfix no? We should not we slap a:

Fixes: a1292595e006 ("net: dsa: add new DSA switch driver for the 
SMSC-LAN9303")

Reviewed-by: Florian Fainelli <f.faineli@gmail.com>
  
Jakub Kicinski Nov. 16, 2022, 5:31 p.m. UTC | #3
On Wed, 16 Nov 2022 09:08:58 -0800 Florian Fainelli wrote:
> This looks like a bugfix no? We should not we slap a:
> 
> Fixes: a1292595e006 ("net: dsa: add new DSA switch driver for the 
> SMSC-LAN9303")

With the entire Fixes tag as a single line ;) And that'll mean that
patches 1 and 2 need to be posted separately. First one to net and the
second one to net-next.
  

Patch

diff --git a/drivers/net/dsa/lan9303-core.c b/drivers/net/dsa/lan9303-core.c
index 438e46af03e9..80f07bd20593 100644
--- a/drivers/net/dsa/lan9303-core.c
+++ b/drivers/net/dsa/lan9303-core.c
@@ -961,7 +961,7 @@  static const struct lan9303_mib_desc lan9303_mib[] = {
 	{ .offset = LAN9303_MAC_TX_BRDCST_CNT_0, .name = "TxBroad", },
 	{ .offset = LAN9303_MAC_TX_PAUSE_CNT_0, .name = "TxPause", },
 	{ .offset = LAN9303_MAC_TX_MULCST_CNT_0, .name = "TxMulti", },
-	{ .offset = LAN9303_MAC_RX_UNDSZE_CNT_0, .name = "TxUnderRun", },
+	{ .offset = LAN9303_MAC_RX_UNDSZE_CNT_0, .name = "RxShort", },
 	{ .offset = LAN9303_MAC_TX_64_CNT_0, .name = "Tx64Byte", },
 	{ .offset = LAN9303_MAC_TX_127_CNT_0, .name = "Tx128Byte", },
 	{ .offset = LAN9303_MAC_TX_255_CNT_0, .name = "Tx256Byte", },