ntp: add PTP rxfilter

Setting rxfilter to ptp enables timestamping of PTPv2 packets (UDP or
all transports). It will be needed for NTP-over-PTP support.
This commit is contained in:
Miroslav Lichvar
2021-08-18 10:44:48 +02:00
parent b2c2132e4b
commit 2f1d5d9255
4 changed files with 13 additions and 0 deletions

2
conf.c
View File

@@ -1556,6 +1556,8 @@ parse_hwtimestamp(char *line)
iface->rxfilter = CNF_HWTS_RXFILTER_NONE;
else if (!strcasecmp(filter, "ntp"))
iface->rxfilter = CNF_HWTS_RXFILTER_NTP;
else if (!strcasecmp(filter, "ptp"))
iface->rxfilter = CNF_HWTS_RXFILTER_PTP;
else if (!strcasecmp(filter, "all"))
iface->rxfilter = CNF_HWTS_RXFILTER_ALL;
else