freebsd-dev/sys/dev/mlx5
Konstantin Belousov ef23f141bc Implement hardware mlx5(4) rx timestamps.
Driver support is only provided for ConnectX4/5.

System-time timestamp is calculated based on the free-running counter
timestamp provided by hardware.  Driver periodically samples the
counter to calibrate it against the system clock and uses linear
interpolation to convert.  Stability of the crystal which drives the
clock is +-50 ppm at the operational temperature, which makes the
algorithm good enough.

The calculation is somewhat delicate because all values are 64bit and
overflow the naive formula for linear interpolation.  The calculation
drops the least significant bits in advance, see the PREC shift in
mlx5_mbuf_tstmp().

Hardware stamps can be turned off by 'ifconfig mceN -hwrxtsmp'.  Buggy
firmware might result in small but visible errors in the reported
timestamps, detectable e.g. by nonsensical (negative) RTT values for
LAN pings.

Reviewed by:	gallatin, hselasky
Sponsored by:	Mellanox Technologies
Differential revision:	https://reviews.freebsd.org/D12638
2017-11-29 10:04:11 +00:00
..
mlx5_core Remove duplicate static function prototype to fix compilation of 2017-11-18 20:32:09 +00:00
mlx5_en Implement hardware mlx5(4) rx timestamps. 2017-11-29 10:04:11 +00:00
mlx5_ib Compile fixes for 32-bit architectures. 2017-11-24 12:08:50 +00:00
cq.h Add runtime support for modifying the SQ and RQ completion event 2017-01-20 11:11:49 +00:00
device.h Implement hardware mlx5(4) rx timestamps. 2017-11-29 10:04:11 +00:00
diagnostics.h Make "desc" pointer non-constant inside the mlx5_core_diagnostics_entry 2017-01-30 08:35:15 +00:00
doorbell.h
driver.h Add more and update existing mlx5 core firmware structure definitions and bits. 2017-11-10 14:39:03 +00:00
fs.h Refactor the flowsteering APIs used by mlx5en(4). This change is needed by 2017-11-10 09:49:08 +00:00
mlx5_ifc.h Add more and update existing mlx5 core firmware structure definitions and bits. 2017-11-10 14:39:03 +00:00
mlx5_rdma_if.h
qp.h The new mlx5ib(4) module requires some existing values to be redefined. 2017-11-10 15:28:17 +00:00
srq.h
vport.h Add API function to query port performance counters for infiniband and RoCE 2017-11-10 13:58:49 +00:00