a7d42145cc
When capturing packets into a PCAP file, DPDK currently uses microseconds for the timestamps. But libpcap supports interpreting tv_usec as nanoseconds depending on the file timestamp precision, as of commit ba89e4a18e8b ("Make timestamps precision configurable"). To support this, use PCAP_TSTAMP_PRECISION_NANO when creating the empty PCAP file as specified by PCAP_OPEN_DEAD(3PCAP) and implement nanosecond timeval addition. This also ensures that the precision reported by capinfos is nanoseconds (9). Note that NSEC_PER_SEC is defined as 1000000000L instead of 1e9 since the latter might be interpreted as floating point. Signed-off-by: Vivien Didelot <vivien.didelot@gmail.com> Acked-by: Ferruh Yigit <ferruh.yigit@intel.com> |
||
---|---|---|
.ci | ||
app | ||
buildtools | ||
config | ||
devtools | ||
doc | ||
drivers | ||
examples | ||
kernel | ||
lib | ||
license | ||
mk | ||
usertools | ||
.editorconfig | ||
.gitattributes | ||
.gitignore | ||
.travis.yml | ||
ABI_VERSION | ||
GNUmakefile | ||
MAINTAINERS | ||
Makefile | ||
meson_options.txt | ||
meson.build | ||
README | ||
VERSION |
DPDK is a set of libraries and drivers for fast packet processing. It supports many processor architectures and both FreeBSD and Linux. The DPDK uses the Open Source BSD-3-Clause license for the core libraries and drivers. The kernel components are GPL-2.0 licensed. Please check the doc directory for release notes, API documentation, and sample application information. For questions and usage discussions, subscribe to: users@dpdk.org Report bugs and issues to the development mailing list: dev@dpdk.org