mbox series

[net-next,v4,0/2] net: xilinx: axienet: Add statistics support

Message ID 20240820175343.760389-1-sean.anderson@linux.dev (mailing list archive)
Headers show
Series net: xilinx: axienet: Add statistics support | expand

Message

Sean Anderson Aug. 20, 2024, 5:53 p.m. UTC
Add support for hardware statistics counters (if they are enabled) in
the AXI Ethernet driver. Unfortunately, the implementation is
complicated a bit since the hardware might only support 32-bit counters.

Changes in v4:
- Reduce hw_last_counter to u32 to ensure we use (wrapping) 32-bit
  arithmetic.
- Implement get_ethtool_stats for nonstandard statistics
- Rebase onto net-next/main

Changes in v3:
- Use explicit mutex_lock/unlock instead of guard() in
  __axienet_device_reset to make it clear that we need to hold
  lp->stats_lock for the whole function.

Changes in v2:
- Switch to a seqlock-based implementation to allow fresher updates
  (rather than always using stale counter values from the previous
  refresh).
- Take stats_lock unconditionally in __axienet_device_reset
- Fix documentation mismatch

Sean Anderson (2):
  net: xilinx: axienet: Report RxRject as rx_dropped
  net: xilinx: axienet: Add statistics support

 drivers/net/ethernet/xilinx/xilinx_axienet.h  |  85 +++++
 .../net/ethernet/xilinx/xilinx_axienet_main.c | 327 +++++++++++++++++-
 2 files changed, 408 insertions(+), 4 deletions(-)

Comments

patchwork-bot+netdevbpf@kernel.org Aug. 22, 2024, 1 a.m. UTC | #1
Hello:

This series was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@kernel.org>:

On Tue, 20 Aug 2024 13:53:40 -0400 you wrote:
> Add support for hardware statistics counters (if they are enabled) in
> the AXI Ethernet driver. Unfortunately, the implementation is
> complicated a bit since the hardware might only support 32-bit counters.
> 
> Changes in v4:
> - Reduce hw_last_counter to u32 to ensure we use (wrapping) 32-bit
>   arithmetic.
> - Implement get_ethtool_stats for nonstandard statistics
> - Rebase onto net-next/main
> 
> [...]

Here is the summary with links:
  - [net-next,v4,1/2] net: xilinx: axienet: Report RxRject as rx_dropped
    https://git.kernel.org/netdev/net-next/c/d70e3788da1d
  - [net-next,v4,2/2] net: xilinx: axienet: Add statistics support
    https://git.kernel.org/netdev/net-next/c/76abb5d675c4

You are awesome, thank you!