boundarydevices / linux

Kernel tree for Boundary Devices platforms
194 stars 290 forks source link

Can't sync time using hardware stamps #37

Closed cobras closed 6 years ago

cobras commented 7 years ago

Hi, I wish to use PTP to sync device using the fec driver with kernel 2.10.17. 10.0.2_ga. To do it, I'm using ptp version 1.8. I'm using the following simple command :+1:

When I add -S to ptp (SOFTWARE STAMP), every things work right. But when I remove -S, I can see raw and path delay not equal to zero. Sep 1 02:27:20 ptp4l: [3959.206] port 1: delay timeout Sep 1 02:27:20 ptp4l: [3959.207] delay filtered 73190 raw 73999 Sep 1 02:27:20 ptp4l: [3959.827] master offset 4211 s2 freq +6490 path delay 73190 Sep 1 02:27:20 ptp4l: [3959.880] port 1: delay timeout Sep 1 02:27:20 ptp4l: [3959.881] delay filtered 73190 raw 74690 ptp4l[3960.828]: master offset 14026 s2 freq +7485 path delay 73190

In the packet capture, we can see precisionOriginTime is always the same with HARDWARE mode when it changes in SOFTWARE mode (See attached). I have tried to merge commit to this driver using patches from other branch, but I never succeed to fix it. Can you help me ? Thanks in advance. ptp_18.zip

gibsson commented 6 years ago

Hi,

Can you please try with a newer kernel? It has changed quite a lot since 3.10.17: https://github.com/boundarydevices/linux-imx6/tree/boundary-imx_4.1.15_2.0.0_ga

Regards, Gary

gibsson commented 6 years ago

Hi, Since there's no answer to our previous suggestion, we consider this issue fixed. Regards, Gary