mbox

[RFC,v1,0/3] pdump HW timestamps for mlx5

Message ID 20200609141713.11614-1-patrick.keroulas@radio-canada.ca (mailing list archive)
Headers

Message

Patrick Keroulas June 9, 2020, 2:17 p.m. UTC
  The intention is to produce a pcap with nanosecond precision when
timestamp offloading is activated on mlx5 NIC.

The packets forwarded by testpmd hold the raw counter but a pcap
requires a time unit. Assuming that the NIC clock is already synced
with external master clock, this patchset simply integrates the
nanosecond converter that is already implemented by ibverbs. The
conversion is performed is pdump rx callback.

Patrick Keroulas (3):
  net/mlx5: add timestamp-to-ns converter from libibverbs
  ethdev: add API to convert raw timestamps to nsec
  net/pcap: dump hardware timestamps

 drivers/common/mlx5/mlx5_glue.c          | 16 ++++++++++++
 drivers/common/mlx5/mlx5_glue.h          |  4 +++
 drivers/net/mlx5/mlx5.c                  |  1 +
 drivers/net/mlx5/mlx5.h                  |  1 +
 drivers/net/mlx5/mlx5_ethdev.c           | 30 ++++++++++++++++++++++
 drivers/net/pcap/rte_eth_pcap.c          | 32 ++++++++++++++++--------
 lib/librte_ethdev/rte_ethdev.c           | 12 +++++++++
 lib/librte_ethdev/rte_ethdev.h           | 17 +++++++++++++
 lib/librte_ethdev/rte_ethdev_core.h      |  5 ++++
 lib/librte_ethdev/rte_ethdev_version.map |  2 ++
 lib/librte_mbuf/rte_mbuf_core.h          |  3 ++-
 lib/librte_pdump/rte_pdump.c             | 15 ++++++++++-
 12 files changed, 126 insertions(+), 12 deletions(-)