Re: [Linuxptp-devel] [PATCH v3 00/11] synce4l: add software for Synchronous Ethernet
PTP IEEE 1588 stack for Linux
Brought to you by:
rcochran
From: Aya L. <ay...@nv...> - 2022-06-08 11:04:29
|
On 5/30/2022 10:34 PM, Arkadiusz Kubalewski wrote: > synce4l is a software implementation of Synchronous Ethernet (Sync-E) > according to ITU-T Recommendation G.8264. The design goal is to provide > logic to supported hardware by processing Ethernet Synchronization > Messaging Channel (ESMC) and control Digital Phase Locked Loop (DPLL) We should use EEC rather than DPLL (more abstract less HW related) > clock on Network Card Interface (NIC). > > Application can operate in two mutually exclusive modes. If both modes > are configured simultaneously, the external input takes precedence over > internal one (internal is disabled implicitly). AFAIU there is one selection process which regards all the sources and select according to the quality/priority. What is the benefit of two mutually exclusive modes? > > External input mode > If synce4l is configured to run in "external input" mode, then DPLL > needs to have external 1PPS source attached (GPS or another generator). > In this scenario synce4l always broadcasts clock quality level (QL) > defined in configuration file. Additionally, for this mode > incoming Sync-E frames do not participate in best source selection > algorithm for DPLL. > > Internal input mode Lets use the standard (G.8264 - Annex A) naming of traffic reference source. Internal may refer internal oscillator. > In "internal input" mode incoming Sync-E frames are processed and best > clock source is extracted from the link having the best quality level. > synce4l configures such "best quality" port as a source to recover > clock for DPLL. The recovered QL is broadcasted to all other interfaces > then. An external clock cannot be used in this mode. > > Hardware > synce4l is not bound to any specific NIC hardware. In this level HW should be hidden totally - please see my comment in patch #5 > > Theoretically any NIC could be used for enabling Sync-E device in Lets use SyncE and not Sync-E > External input mode - the NIC in this mode is in leader role (similar > to Grand Master role in PTP), providing its Quality Level information > in ESMC frames to its neighbors. How do we monitor the quality and validity of an external source? > It will not syntonize to any of its neighbor ports, since RX frames > are not monitored. Only other Sync-E enabled neighbor ports could > recover clock from that peer and syntonize to it. > Practically this mode shall be used only if the NIC PHY ports are fed > with stable and reliable frequency clock, Quality Level values that are > sent to the peers are configured by the user. This is user > responsibility to decide and set proper Quality-Level value for the > device, corresponding to the quality of frequency clock generator of > used hardware. > > When enabling Internal input mode, the NIC must be a device that > actually, supports Synchronous Ethernet, which means it is able to > syntonize frequency of all configured ports within the device > to one chosen port - clock is recovered from its RX path, then is fed > to other ports with Phase-Locked Loop (PLL) circuit powering clock of > other ports. > The NIC driver or dedicated software must provide a user with ability > to: > > obtain current state of a DPLL used to syntonize the ports > select one of the ports as a candidate for clock recovery. > Both abilities are configurable in config file - the user must provide > a shell commands - as explained in manual and descriptions inside of > example config file. > > Arkadiusz Kubalewski (11): > synce4l: add config knobs for SyncE > synce4l: add synce in interface and util code > synce4l: add esmc_socket interface > synce4l: add synce_clock interface > synce4l: add synce_dev interface > synce4l: add synce_dev_ctrl interface > synce4l: add synce_port interface > synce4l: add synce_port_ctrl interface > synce4l: add synce_msg interface > synce4l: add synce_transport interface > synce4l: add synce4l application > > .gitignore | 1 + > README.org | 2 + > config.c | 197 +++++-- > config.h | 8 + > configs/synce.cfg | 194 +++++++ > esmc_socket.c | 99 ++++ > esmc_socket.h | 42 ++ > interface.c | 29 +- > interface.h | 24 + > makefile | 9 +- > synce4l.8 | 239 ++++++++ > synce4l.c | 132 +++++ > synce4l_README.md | 194 +++++++ > synce_clock.c | 284 +++++++++ > synce_clock.h | 40 ++ > synce_dev.c | 622 ++++++++++++++++++++ > synce_dev.h | 64 ++ > synce_dev_ctrl.c | 153 +++++ > synce_dev_ctrl.h | 64 ++ > synce_msg.c | 259 +++++++++ > synce_msg.h | 174 ++++++ > synce_msg_private.h | 87 +++ > synce_port.c | 491 ++++++++++++++++ > synce_port.h | 184 ++++++ > synce_port_ctrl.c | 1161 +++++++++++++++++++++++++++++++++++++ > synce_port_ctrl.h | 165 ++++++ > synce_transport.c | 102 ++++ > synce_transport.h | 55 ++ > synce_transport_private.h | 18 + > util.c | 22 + > util.h | 8 + > 31 files changed, 5077 insertions(+), 46 deletions(-) > create mode 100644 configs/synce.cfg > create mode 100644 esmc_socket.c > create mode 100644 esmc_socket.h > create mode 100644 synce4l.8 > create mode 100644 synce4l.c > create mode 100644 synce4l_README.md > create mode 100644 synce_clock.c > create mode 100644 synce_clock.h > create mode 100644 synce_dev.c > create mode 100644 synce_dev.h > create mode 100644 synce_dev_ctrl.c > create mode 100644 synce_dev_ctrl.h > create mode 100644 synce_msg.c > create mode 100644 synce_msg.h > create mode 100644 synce_msg_private.h > create mode 100644 synce_port.c > create mode 100644 synce_port.h > create mode 100644 synce_port_ctrl.c > create mode 100644 synce_port_ctrl.h > create mode 100644 synce_transport.c > create mode 100644 synce_transport.h > create mode 100644 synce_transport_private.h > |