freebsd-dev/sys
Konstantin Belousov 3cf8254f1e Add a place for a driver to report rx timestamps in nanoseconds from
boot for the received packets.

The rcv_tstmp field overlaps the place of Ln header length indicators,
not used by received packets.  The basic pkthdr rearrangement change
in sys/mbuf.h was provided by gallatin.

There are two accompanying M_ flags: M_TSTMP means that there is the
timestamp (and it was generated by hardware).

Another flag M_TSTMP_HPREC indicates that the timestamp is
high-precision.  Practically M_TSTMP_HPREC means that hardware
provided additional precision comparing with the stamps when the flag
is not set.  E.g., for ConnectX all packets are stamped by hardware
when PCIe transaction to write out the completion descriptor is
performed, but PTP packet are stamped on port.  For Intel cards, when
PTP assist is enabled, only PTP packets are stamped in the limited
number of registers, so if Intel cards ever start support this
mechanism, they would always set M_TSTMP | M_TSTMP_HPREC if hardware
timestamp is present for the given packet.

Add IFCAP_HWRXTSTMP interface capability to indicate the support for
hardware rx timestamping, and ifconfig(8) command to toggle it.

Based on the patch by:	gallatin
Reviewed by:	gallatin (previous version), hselasky
Sponsored by:	Mellanox Technologies
MFC after:	2 weeks (? mbuf KBI issue)
X-Differential revision:	https://reviews.freebsd.org/D12638
2017-11-07 09:29:14 +00:00
..
amd64 Zero the structure instead of the pointer to it. 2017-11-05 20:03:57 +00:00
arm Remove support for ARMv6/v7 platform from elf_trampoline. 2017-11-05 17:14:44 +00:00
arm64 Allocate the ITS translation table with a 64k page alignment. This is the 2017-10-31 23:17:17 +00:00
boot Centralize all 32-bit builds on 64-bit platform stuff. 2017-11-06 15:22:24 +00:00
bsm
cam Send IDLE IMMEDIATE for warm boot. 2017-10-30 03:25:22 +00:00
cddl Disable posix_fallocate(2) for ZFS 2017-11-02 13:49:08 +00:00
compat Remove redundant dev->si_drv1 NULL checks in the LinuxKPI. 2017-11-03 13:43:05 +00:00
conf Add Freescale QorIQ SATA controller support. 2017-11-05 02:47:46 +00:00
contrib Rename a couple files to not conflict with ZFS filenames 2017-11-01 03:09:16 +00:00
crypto aesni(4): CRYPTO_AES_NIST_GCM_16 mandates MAC 2017-10-04 21:15:45 +00:00
ddb
dev Fix ixgbe(4) support for ifconfig's vlanhwtag flag. Disabling this flag 2017-11-06 18:08:59 +00:00
fs Allow CUSE(3) to free all memory mapped memory by using regular SWAP objects 2017-11-03 14:10:57 +00:00
gdb gdb kernel server: fixup Search:memory style 2017-10-17 01:12:17 +00:00
geom geom_slice: fix r325227, protect against multiple calls to g_slice_free 2017-11-01 10:53:10 +00:00
gnu dts: Update our device tree sources file fomr Linux 4.13 2017-10-21 15:47:40 +00:00
i386 x86: Do not emit unused TD_TID symbols. 2017-11-04 10:51:52 +00:00
isa
kern rwlock: fix up compilation without KDTRACE_HOOKS after r324787 2017-11-06 05:14:05 +00:00
kgssapi
libkern Continuing efforts to provide hardening of FFS, this change adds a 2017-09-22 12:45:15 +00:00
mips Remove badsect(8). 2017-11-05 22:00:54 +00:00
modules Enable i386 build of the Cavium LiquidIO driver (lio) module. 2017-10-25 17:49:17 +00:00
net Add a place for a driver to report rx timestamps in nanoseconds from 2017-11-07 09:29:14 +00:00
net80211 [net80211] don't try to follow a NULL rxs pointer down the sink. 2017-10-13 06:49:07 +00:00
netgraph Correction after r323873: #include <sys/lock.h> in addition to <sys/rmlock.h> 2017-09-28 11:26:37 +00:00
netinet Fix an accounting bug where data was counted twice if on the read 2017-11-05 11:59:33 +00:00
netinet6 Allow the setting of the MTU for future paths using an SCTP socket option. 2017-11-03 20:46:12 +00:00
netipsec Use correct pointer in key_updateaddresses() when updating NAT-T config. 2017-11-03 11:33:13 +00:00
netpfil Fix Dummynet AQM packet marking function ecn_mark() and fq_codel / 2017-10-26 10:11:35 +00:00
netsmb netsmb: Fix buggy/racy smb_strdupin() 2017-09-29 15:53:26 +00:00
nfs
nfsclient
nfsserver
nlm
ofed The remote DMA TCP portspace selector, RDMA_PS_TCP, is used for both 2017-10-20 08:20:15 +00:00
opencrypto crypto(9) is called from ipsec in CRYPTO_F_CBIFSYNC mode. This is working 2017-11-03 10:27:22 +00:00
powerpc Set the PRD extension list base address in little endian 2017-11-06 05:09:18 +00:00
riscv Update several more URLs 2017-10-29 08:17:03 +00:00
rpc
security Sprinkle __read_frequently on few obvious places. 2017-09-06 20:33:33 +00:00
sparc64 Update several more URLs 2017-10-29 08:17:03 +00:00
sys Add a place for a driver to report rx timestamps in nanoseconds from 2017-11-07 09:29:14 +00:00
teken
tests
tools embed_mfs: add error handling, usage 2017-10-17 21:13:26 +00:00
ufs Improve the message printed when the cylinder group checksum is wrong. 2017-11-05 13:28:48 +00:00
vm Micro-optimize the handling of fictitious pages in vm_page_free_prep(). 2017-10-24 17:14:53 +00:00
x86 Add AT_HWCAP2 ELF auxiliary vector. 2017-10-21 12:05:01 +00:00
xdr
xen
Makefile