diff options
author | Breno Leitao <leitao@debian.org> | 2025-06-18 01:32:42 -0700 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2025-06-19 16:15:34 -0700 |
commit | f9e2511d80c2eaeb940c5f8280d7eea9d7946ece (patch) | |
tree | 8133946fcdd2f534a9b27a75c3a6258d4bedc43e /net/unix/af_unix.c | |
parent | c3ee72ded0d2fc6433a009291d7825b28426e4c0 (diff) |
netdevsim: migrate to dstats stats collection
Replace custom statistics tracking with the kernel's dstats infrastructure
to simplify code and improve consistency with other network drivers.
This change:
- Sets dev->pcpu_stat_type = NETDEV_PCPU_STAT_DSTATS for automatic
automatic allocation and deallocation.
- Removes manual stats fields and their update
- Replaces custom nsim_get_stats64() with dev_get_stats()
- Uses dev_dstats_tx_add() and dev_dstats_tx_dropped() helpers
- Eliminates the need for manual synchronization primitives
The dstats framework provides the same functionality with less code.
Suggested-by: Jakub Kicinski <kuba@kernel.org>
Reviewed-by: Joe Damato <joe@dama.to>
Signed-off-by: Breno Leitao <leitao@debian.org>
Link: https://patch.msgid.link/20250618-netdevsim_stat-v4-1-19fe0d35e28e@debian.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'net/unix/af_unix.c')
0 files changed, 0 insertions, 0 deletions