summaryrefslogtreecommitdiff
path: root/scripts/basic/split-include.c
diff options
context:
space:
mode:
authorCarolina Jubran <cjubran@nvidia.com>2026-09-02 22:37:31 +0300
committerJakub Kicinski <kuba@kernel.org>2026-09-05 13:23:37 -0700
commitdf99553f840e4c529c1ba4c29bd39396466ca11a (patch)
treeecb6041345128d74a0f500d1d0fbfdefd287021b /scripts/basic/split-include.c
parentc0c6f4ba8a37688f7b4d4044898d88f0450d44c2 (diff)
downloadlinux-df99553f840e4c529c1ba4c29bd39396466ca11a.tar.gz
linux-df99553f840e4c529c1ba4c29bd39396466ca11a.zip
net/mlx5e: Keep HW timestamp stats monotonic across reconfiguration
`mlx5e_stats_ts_get()` currently selects either DMA or port timestamp counters based on `tx_ptp_opened`. This flag is intentionally kept set once the PTP TX queues have been opened so their statistics remain available after queue teardown. As a result, DMA timestamps are no longer reported after switching from port timestamping back to DMA timestamping. The function also reads statistics only from the currently active channels and TCs. Reducing the number of channels or TCs can therefore drop previously accumulated timestamp counters from the reported value. Read the persistent channel statistics instead and always include DMA timestamp counters. Once the PTP TX queues have been opened, also include the port timestamp counters. This also drops state_lock. It previously protected live channel/PTP pointers, the new code only reads persistent channel_stats and ptp_stats via mlx5e_stats_nch_read(), which is already safe for lockless stats access. Fixes: 3579032c08c1 ("net/mlx5e: Implement ethtool hardware timestamping statistics") Signed-off-by: Carolina Jubran <cjubran@nvidia.com> Reviewed-by: Shahar Shitrit <shshitrit@nvidia.com> Signed-off-by: Tariq Toukan <tariqt@nvidia.com> Link: https://patch.msgid.link/20260902193731.3668958-1-tariqt@nvidia.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'scripts/basic/split-include.c')
0 files changed, 0 insertions, 0 deletions