ntp: save PTP correction from NTP-over-PTP messages

When the RX duration is known (HW timestamping), save the PTP correction
from received PTP messages in the local RX timestamp.
This commit is contained in:
Miroslav Lichvar
2023-09-26 12:22:47 +02:00
parent b0267475e3
commit 6372a9f93f
3 changed files with 19 additions and 6 deletions

View File

@@ -64,7 +64,7 @@ extern int NIO_IsServerSocketOpen(void);
extern int NIO_IsServerConnectable(NTP_Remote_Address *remote_addr);
/* Function to unwrap an NTP message from non-native transport (e.g. PTP) */
extern int NIO_UnwrapMessage(SCK_Message *message, int sock_fd);
extern int NIO_UnwrapMessage(SCK_Message *message, int sock_fd, double *net_correction);
/* Function to transmit a packet */
extern int NIO_SendPacket(NTP_Packet *packet, NTP_Remote_Address *remote_addr,