aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/netdev-times.py
diff options
context:
space:
mode:
authorArnd Bergmann <[email protected]>2017-11-27 12:44:53 +0100
committerJason Gunthorpe <[email protected]>2017-12-13 11:00:13 -0700
commitf8109d9e7de550a28d620144b0fe31e661e02bcb (patch)
treec8b414fd3b14457dad2a96178460ecd3f5920d10 /tools/perf/scripts/python/netdev-times.py
parent302d6424e4a293a5761997e6c9fc3dfb1e4c355f (diff)
infiniband: cxgb4: use ktime_get for timestamps
The debugfs file prints the difference between host timestamps as a seconds/nanoseconds tuple, along with a 64-bit nanoseconds hardware timestamp. The host time is read using getnstimeofday() which is deprecated because of the y2038 overflow, and it suffers from time jumps during settimeofday() and leap seconds. Converting to ktime_get_ts64() would solve those two, but I'm going a little further here by changing to ktime_get() and printing 64-bit nanoseconds on both host and hw timestamps. This simplifies the code further and makes the output easier to understand. The format of the debugfs file obviously changes here, but this should only be read by humans and not scripts, so I assume it's fine. Signed-off-by: Arnd Bergmann <[email protected]> Acked-by: Steve Wise <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/netdev-times.py')
0 files changed, 0 insertions, 0 deletions