]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
tools: ynl: ethtool.py: Output timestamping statistics from tsinfo-get operation
authorRahul Rameshbabu <rrameshbabu@nvidia.com>
Wed, 3 Apr 2024 21:28:45 +0000 (14:28 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 22 May 2025 12:12:15 +0000 (14:12 +0200)
commit95a9e08ea5bbd48b3bcf6fb64bc0aef07fd2aa40
tree0bb113b4bb2c2d0dc2a7d517d13caade349169a7
parenta7d6e0ac0a8861f6b1027488062251a8e28150fd
tools: ynl: ethtool.py: Output timestamping statistics from tsinfo-get operation

[ Upstream commit 2e0e148c727061009d3db5f436f51890bbb49a80 ]

Print the nested stats attribute containing timestamping statistics when
the --show-time-stamping flag is used.

  [root@binary-eater-vm-01 linux-ethtool-ts]# ./tools/net/ynl/ethtool.py --show-time-stamping mlx5_1
  Time stamping parameters for mlx5_1:
  Capabilities:
    hardware-transmit
    hardware-receive
    hardware-raw-clock
  PTP Hardware Clock: 0
  Hardware Transmit Timestamp Modes:
    off
    on
  Hardware Receive Filter Modes:
    none
    all
  Statistics:
    tx-pkts: 8
    tx-lost: 0
    tx-err: 0

Signed-off-by: Rahul Rameshbabu <rrameshbabu@nvidia.com>
Reviewed-by: Dragos Tatulea <dtatulea@nvidia.com>
Link: https://lore.kernel.org/r/20240403212931.128541-8-rrameshbabu@nvidia.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Stable-dep-of: 45375814eb3f ("tools/net/ynl: ethtool: fix crash when Hardware Clock info is missing")
Signed-off-by: Sasha Levin <sashal@kernel.org>
tools/net/ynl/ethtool.py