From: Sanjay B. <sa...@zi...> - 2019-05-20 16:31:29
|
Not sure if these actually have anything to do with each other - but with my limited insight, it seems like they do. Some help please. In the man page it says: > With the *-a* option, the clocks to synchronize are fetched from the running *ptp4l* daemon and the direction of synchronization automatically follows changes of the PTP port states. Is this talking about multiple PTP ports (clocks)? Is it saying that phc2sys will follow the roles decided by the PTP protocol, and set the PHC on ports that happen to be masters from a port that is a slave? All I can think is that this applies when the node is a boundary clock. Can someone comment? How does this play with the scenario where the node is the grandmaster? What is the direction of time synchronization in that case? |
From: Richard C. <ric...@gm...> - 2019-05-21 04:53:48
|
On Mon, May 20, 2019 at 12:31:07PM -0400, Sanjay Bhandari wrote: > > With the *-a* option, the clocks to synchronize are fetched from the > running *ptp4l* daemon and the direction of synchronization automatically > follows changes of the PTP port states. > > Is this talking about multiple PTP ports (clocks)? Yes. > Is it saying that > phc2sys will follow the roles decided by the PTP protocol, and set the PHC > on ports that happen to be masters from a port that is a slave? You got it! > All I can > think is that this applies when the node is a boundary clock. Can someone > comment? Um hm. > How does this play with the scenario where the node is the grandmaster? > What is the direction of time synchronization in that case? It picks the first interface from the ptp4l command line (or config. file) as the master clock. With -r -r you can also serve CLOCK_REALTIME. HTH, Richard |
From: Sanjay B. <sa...@zi...> - 2019-05-22 19:18:28
|
Have a followup question on this. It says in the man page that: > When running as a boundary clock ... all of the ports share the same hardware clock device. And then: > For this mode, the collection of clocks must be synchronized by an external program, for example phc2sys <http://manpages.ubuntu.com/manpages/cosmic/man8/phc2sys.8.html>(8) in "automatic" mode. I am confused about what this external program is supposed to do. If all the ports share the same hardware clock device, then aren't these ports synchronized already? Once ptp4l sets the PHC on a slave port, won't all the other ports see the same exact time automatically? How can 2 clocks that share the same hardware clock device be even out of sync? On Tue, May 21, 2019 at 12:53 AM Richard Cochran <ric...@gm...> wrote: > On Mon, May 20, 2019 at 12:31:07PM -0400, Sanjay Bhandari wrote: > > > With the *-a* option, the clocks to synchronize are fetched from the > > running *ptp4l* daemon and the direction of synchronization automatically > > follows changes of the PTP port states. > > > > Is this talking about multiple PTP ports (clocks)? > > Yes. > > > Is it saying that > > phc2sys will follow the roles decided by the PTP protocol, and set the > PHC > > on ports that happen to be masters from a port that is a slave? > > You got it! > > > All I can > > think is that this applies when the node is a boundary clock. Can someone > > comment? > > Um hm. > > > How does this play with the scenario where the node is the grandmaster? > > What is the direction of time synchronization in that case? > > It picks the first interface from the ptp4l command line (or > config. file) as the master clock. > > With -r -r you can also serve CLOCK_REALTIME. > > HTH, > Richard > |
From: Lynch, M. <mik...@hb...> - 2019-05-22 20:32:25
|
It is possible to have PTP hardware that does NOT share timestamping hardware. In that case you must configure ptp4l to use “just a bunch of devices” (boundary_clock_jbod) and use phc2sys (or the like) to synchronize the independent timestamping hardware. The one platform I have experienced this with is the Cyclone V SOC (arm). From: Sanjay Bhandari <sa...@zi...> Sent: Wednesday, May 22, 2019 2:18 PM To: Richard Cochran <ric...@gm...> Cc: lin...@li... Subject: Re: [Linuxptp-users] question on "-a" option in phc2sys (and boundary clock etc.) Have a followup question on this. It says in the man page that: > When running as a boundary clock ... all of the ports share the same hardware clock device. And then: > For this mode, the collection of clocks must be synchronized by an external program, for example phc2sys<https://eur01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fmanpages.ubuntu.com%2Fmanpages%2Fcosmic%2Fman8%2Fphc2sys.8.html&data=01%7C01%7Cmike.lynch%40hbm.com%7C29e44de4211041057cd708d6deea64e4%7C6cce74a3397545e09893b072988b30b6%7C0&sdata=bbokgjlR%2BjMwYLylu5k%2Bc52xFBZ663k5n5pRbYiOMfw%3D&reserved=0>(8) in "automatic" mode. I am confused about what this external program is supposed to do. If all the ports share the same hardware clock device, then aren't these ports synchronized already? Once ptp4l sets the PHC on a slave port, won't all the other ports see the same exact time automatically? How can 2 clocks that share the same hardware clock device be even out of sync? On Tue, May 21, 2019 at 12:53 AM Richard Cochran <ric...@gm...<mailto:ric...@gm...>> wrote: On Mon, May 20, 2019 at 12:31:07PM -0400, Sanjay Bhandari wrote: > > With the *-a* option, the clocks to synchronize are fetched from the > running *ptp4l* daemon and the direction of synchronization automatically > follows changes of the PTP port states. > > Is this talking about multiple PTP ports (clocks)? Yes. > Is it saying that > phc2sys will follow the roles decided by the PTP protocol, and set the PHC > on ports that happen to be masters from a port that is a slave? You got it! > All I can > think is that this applies when the node is a boundary clock. Can someone > comment? Um hm. > How does this play with the scenario where the node is the grandmaster? > What is the direction of time synchronization in that case? It picks the first interface from the ptp4l command line (or config. file) as the master clock. With -r -r you can also serve CLOCK_REALTIME. HTH, Richard |
From: Sanjay B. <sa...@zi...> - 2019-05-22 20:01:41
|
My question is about the scenario where they do share the same hardware clock (as described in the manual). On Wed, May 22, 2019, 3:57 PM Lynch, Mike <mik...@hb...> wrote: > It is possible to have PTP hardware that does NOT share timestamping > hardware. In that case you must configure ptp4l to use “just a bunch of > devices” (boundary_clock_jbod) and use phc2sys (or the like) to synchronize > the independent timestamping hardware. The one platform I have experienced > this with is the Cyclone V SOC (arm). > > > > *From:* Sanjay Bhandari <sa...@zi...> > *Sent:* Wednesday, May 22, 2019 2:18 PM > *To:* Richard Cochran <ric...@gm...> > *Cc:* lin...@li... > *Subject:* Re: [Linuxptp-users] question on "-a" option in phc2sys (and > boundary clock etc.) > > > > Have a followup question on this. > > > > It says in the man page that: > > > > > When running as a boundary clock ... all of the ports share the same > hardware clock device. > > > > And then: > > > > > For this mode, the collection of clocks must be synchronized by an > external program, for example phc2sys > <https://eur01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fmanpages.ubuntu.com%2Fmanpages%2Fcosmic%2Fman8%2Fphc2sys.8.html&data=01%7C01%7Cmike.lynch%40hbm.com%7C29e44de4211041057cd708d6deea64e4%7C6cce74a3397545e09893b072988b30b6%7C0&sdata=bbokgjlR%2BjMwYLylu5k%2Bc52xFBZ663k5n5pRbYiOMfw%3D&reserved=0>(8) > in "automatic" mode. > > > > I am confused about what this external program is supposed to do. If all > the ports share the same hardware clock device, then aren't these ports > synchronized already? Once ptp4l sets the PHC on a slave port, won't all > the other ports see the same exact time automatically? How can 2 clocks > that share the same hardware clock device be even out of sync? > > > > On Tue, May 21, 2019 at 12:53 AM Richard Cochran <ric...@gm...> > wrote: > > On Mon, May 20, 2019 at 12:31:07PM -0400, Sanjay Bhandari wrote: > > > With the *-a* option, the clocks to synchronize are fetched from the > > running *ptp4l* daemon and the direction of synchronization automatically > > follows changes of the PTP port states. > > > > Is this talking about multiple PTP ports (clocks)? > > Yes. > > > Is it saying that > > phc2sys will follow the roles decided by the PTP protocol, and set the > PHC > > on ports that happen to be masters from a port that is a slave? > > You got it! > > > All I can > > think is that this applies when the node is a boundary clock. Can someone > > comment? > > Um hm. > > > How does this play with the scenario where the node is the grandmaster? > > What is the direction of time synchronization in that case? > > It picks the first interface from the ptp4l command line (or > config. file) as the master clock. > > With -r -r you can also serve CLOCK_REALTIME. > > HTH, > Richard > > |
From: Richard C. <ric...@gm...> - 2019-05-23 02:03:32
|
On Wed, May 22, 2019 at 04:01:18PM -0400, Sanjay Bhandari wrote: > My question is about the scenario where they do share the same hardware > clock (as described in the manual). The only HW I know is the Freescale (nxp) ETSEC with three ports, all sharing one clock. Maybe there are other such devices, but I haven't seen them or even heard of them. Thanks, Richard |
From: David M. <da...@ar...> - 2019-05-23 04:41:00
|
For what it's worth, the Mellanox-based 1/10G devices I have access to seem to share one PHC between both ports: bash-4.4# ethtool -T ma5 | grep Clock PTP Hardware Clock: 4 bash-4.4# ethtool -T ma6 | grep Clock PTP Hardware Clock: 4 bash-4.4# ethtool -i ma5 driver: mlx4_en bash-4.4# lspci | grep Mellanox 05:00.0 Ethernet controller: Mellanox Technologies MT27520 Family [ConnectX-3 Pro] We don't use them in this way, and I haven't played or tested this aspect but if'd be happy to poke them a little if anyone has any requests. - David On Thu, 23 May 2019 at 12:04, Richard Cochran <ric...@gm...> wrote: > On Wed, May 22, 2019 at 04:01:18PM -0400, Sanjay Bhandari wrote: > > My question is about the scenario where they do share the same hardware > > clock (as described in the manual). > > The only HW I know is the Freescale (nxp) ETSEC with three ports, all > sharing one clock. > > Maybe there are other such devices, but I haven't seen them or even > heard of them. > > Thanks, > Richard > > > _______________________________________________ > Linuxptp-users mailing list > Lin...@li... > https://lists.sourceforge.net/lists/listinfo/linuxptp-users > |
From: Keller, J. E <jac...@in...> - 2019-05-29 16:58:07
|
> -----Original Message----- > From: Richard Cochran [mailto:ric...@gm...] > Sent: Wednesday, May 22, 2019 7:03 PM > To: Sanjay Bhandari <sa...@zi...> > Cc: lin...@li... > Subject: Re: [Linuxptp-users] question on "-a" option in phc2sys (and boundary clock > etc.) > > On Wed, May 22, 2019 at 04:01:18PM -0400, Sanjay Bhandari wrote: > > My question is about the scenario where they do share the same hardware > > clock (as described in the manual). > > The only HW I know is the Freescale (nxp) ETSEC with three ports, all > sharing one clock. > > Maybe there are other such devices, but I haven't seen them or even > heard of them. > > Thanks, > Richard > Several of the Intel cards share the same clock source internally, but there's no way to keep all the registers in sync, so they have to be treated as just a bunch of clocks. Thanks, Jake |