Hi Richard,

Here are my thoughts.
phc2sys is a piece of code with some twists 😊

1) Regarding "After all, perhaps the motherboard has a quartz crystal and the 
PHC has a simple R/C circuit.  The system clock could very well have better 
holdover qualities than the PHC.": 
        - I'd rather claim that typically all clocks of a SoC are derived from 
a single crystal oscillator. For our TI Sitara based HW this is certainly the 
case.
        - with -r / -rr it can be already controlled if system clock is a 
possible sync dest/source.
2) If the system clock is eligible a sync destination I would claim that it 
should also get synced if there is no source. This would be consistent as also 
all PHCs are kept in sync.

Best regards, Chris

-----Original Message-----
From: Richard Cochran <richardcoch...@gmail.com> 
Sent: Samstag, 18. April 2020 05:10
To: Christian Leeb <christian.l...@ch.abb.com>
Cc: linuxptp-users@lists.sourceforge.net; Henrik Pind <henrik.p...@se.abb.com>; 
Erdahl, Michael <m-erd...@ti.com>
Subject: Re: [Linuxptp-users] phc2sys with REALTIMECLOCK

CAUTION: This email originated from outside of the organization. Do not click 
links or open attachments unless you recognize the sender and know the content 
is safe.


On Fri, Apr 17, 2020 at 06:47:57AM +0000, Christian Leeb wrote:

> ok. So far. But the CLOCK_REALTIME is not added to list of dst clocks! As a 
> consequence, CLOCK_REALTIME is not synced anymore.
>
> phc2sys[1530254.251]: eth0 phc offset    -89483 s0 freq   -9955
> phc2sys[1530256.350]: eth0 phc offset    -39106 s0 freq  +34863
>
> Is this the intended behaviour?

I'm not 100% sure what was intended.  This program grew over time, but I can 
certainly come up with an explanation for this behavior...

Originally, the phc2sys program did something very simple, namely just 
synchronizing the system clock to a single PHC (or the reverse).

When the program grew to support multiple PHCs, then it had to determine which 
PHC was the slave and synchronize everything else to it.

But if no PHC in the slave state, what then is the correct choice?

The best choice might be to simply let the system time act as a free running 
clock.  After all, perhaps the motherboard has a quartz crystal and the PHC has 
a simple R/C circuit.  The system clock could very well have better holdover 
qualities than the PHC.

So you might not like this explanation, but there it is.

Thoughts?

Thanks,
Richard






_______________________________________________
Linuxptp-users mailing list
Linuxptp-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linuxptp-users

Reply via email to