Skip to content

Commit

Permalink
Apply ingress and egress latency corrections in P2P one step mode.
Browse files Browse the repository at this point in the history
When using peer to peer one step mode, the normal time stamp handling
of peer delay request messages is bypassed.  The hardware subtracts
the ingress time stamp from the correction field and then adds the
egress time into the correction of the response.  The configured
latency values are never applied since the hardware has no knowledge
of them.  This patch adds in the correction values in this special
case.

Signed-off-by: Richard Cochran <[email protected]>
  • Loading branch information
richardcochran committed Aug 6, 2018
1 parent da06ea5 commit a274076
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions port.c
Original file line number Diff line number Diff line change
Expand Up @@ -1968,6 +1968,8 @@ int process_pdelay_req(struct port *p, struct ptp_message *m)
*/
if (p->timestamping == TS_P2P1STEP) {
rsp->header.correction = m->header.correction;
rsp->header.correction += p->tx_timestamp_offset;
rsp->header.correction += p->rx_timestamp_offset;
} else {
rsp->header.flagField[0] |= TWO_STEP;
rsp->pdelay_resp.requestReceiptTimestamp =
Expand Down

0 comments on commit a274076

Please sign in to comment.