All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH net-next] bnxt: add more ethtool standard stats
@ 2021-04-19 20:02 Jakub Kicinski
  2021-04-19 23:30 ` patchwork-bot+netdevbpf
  0 siblings, 1 reply; 2+ messages in thread
From: Jakub Kicinski @ 2021-04-19 20:02 UTC (permalink / raw)
  To: davem; +Cc: netdev, michael.chan, Jakub Kicinski

Michael suggest a few more stats we can expose.

$ ethtool -S eth0 --groups eth-mac
Standard stats for eth0:
eth-mac-FramesTransmittedOK: 902623288966
eth-mac-FramesReceivedOK: 28727667047
eth-mac-FrameCheckSequenceErrors: 1
eth-mac-AlignmentErrors: 0
eth-mac-OutOfRangeLengthField: 0
$ ethtool -S eth0 | grep '\(fcs\|align\|oor\)'
     rx_fcs_err_frames: 1
     rx_align_err_frames: 0
     tx_fcs_err_frames: 0

Suggested-by: Michael Chan <michael.chan@broadcom.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
---
 drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c b/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c
index 832252313b18..3b66e300c962 100644
--- a/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c
+++ b/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c
@@ -4020,6 +4020,12 @@ static void bnxt_get_eth_mac_stats(struct net_device *dev,
 		BNXT_GET_RX_PORT_STATS64(rx, rx_good_frames);
 	mac_stats->FramesTransmittedOK =
 		BNXT_GET_TX_PORT_STATS64(tx, tx_good_frames);
+	mac_stats->FrameCheckSequenceErrors =
+		BNXT_GET_RX_PORT_STATS64(rx, rx_fcs_err_frames);
+	mac_stats->AlignmentErrors =
+		BNXT_GET_RX_PORT_STATS64(rx, rx_align_err_frames);
+	mac_stats->OutOfRangeLengthField =
+		BNXT_GET_RX_PORT_STATS64(rx, rx_oor_len_frames);
 }
 
 static void bnxt_get_eth_ctrl_stats(struct net_device *dev,
-- 
2.30.2


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH net-next] bnxt: add more ethtool standard stats
  2021-04-19 20:02 [PATCH net-next] bnxt: add more ethtool standard stats Jakub Kicinski
@ 2021-04-19 23:30 ` patchwork-bot+netdevbpf
  0 siblings, 0 replies; 2+ messages in thread
From: patchwork-bot+netdevbpf @ 2021-04-19 23:30 UTC (permalink / raw)
  To: Jakub Kicinski; +Cc: davem, netdev, michael.chan

Hello:

This patch was applied to netdev/net-next.git (refs/heads/master):

On Mon, 19 Apr 2021 13:02:42 -0700 you wrote:
> Michael suggest a few more stats we can expose.
> 
> $ ethtool -S eth0 --groups eth-mac
> Standard stats for eth0:
> eth-mac-FramesTransmittedOK: 902623288966
> eth-mac-FramesReceivedOK: 28727667047
> eth-mac-FrameCheckSequenceErrors: 1
> eth-mac-AlignmentErrors: 0
> eth-mac-OutOfRangeLengthField: 0
> $ ethtool -S eth0 | grep '\(fcs\|align\|oor\)'
>      rx_fcs_err_frames: 1
>      rx_align_err_frames: 0
>      tx_fcs_err_frames: 0
> 
> [...]

Here is the summary with links:
  - [net-next] bnxt: add more ethtool standard stats
    https://git.kernel.org/netdev/net-next/c/37434782d63f

You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-04-19 23:30 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-19 20:02 [PATCH net-next] bnxt: add more ethtool standard stats Jakub Kicinski
2021-04-19 23:30 ` patchwork-bot+netdevbpf

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.