Re: [Linuxptp-devel] [PATCH v3 6/6] Add example Common Mean Link Delay Service configuration files.
On Wed, Dec 06, 2023 at 03:43:15PM +0100, Andrew Zaborowski wrote: > Again feel free to include it or leave it for us to send separately. I prefer to roll your fixes into this series. Thanks, Richard ___ Linuxptp-devel mailing list Linuxptp-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linuxptp-devel
Re: [Linuxptp-devel] [PATCH v3 6/6] Add example Common Mean Link Delay Service configuration files.
On Tue, 5 Dec 2023 at 02:44, Andrew Zaborowski wrote: > * if I stop a CMLDS client and rerun it, it will receive the CMLDS > notifications twice until the old subscription expires. If I restart > it again quickly enough it'll receive each notification 3 times. This > is because pmc_recv doesn't filter by .targetPortIdentity. It could > but it wouldn't be bullet proof anyway because the PMC port's identity > is based on the pid, which is not unique, so I'm not sure if it's > worth doing. On a second thought, if the pid ends up being reused, when the client re-subscribes to the CMLDS notifications, the server will update the existing subscription so duplicate notifications wouldn't be sent. So at least this specific use case would be covered. Additionally we found we needed to exit early from port_capable() so as not to overwrite the p->asCapable value set by process_cmlds(). Again feel free to include it or leave it for us to send separately. @@ -700,6 +700,11 @@ int port_capable(struct port *p) goto capable; } +if (p->delayMechanism == DM_COMMON_P2P) { +/* asCapable is calculated by the CMLDS. */ +return p->asCapable != NOT_CAPABLE ? 1 : 0; +} + if (tmv_to_nanoseconds(p->peer_delay) >p->neighborPropDelayThresh) { if (p->asCapable) pr_debug("%s: peer_delay (%" PRId64 ") > neighborPropDelayThresh " Best regards ___ Linuxptp-devel mailing list Linuxptp-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linuxptp-devel
Re: [Linuxptp-devel] [PATCH v3 6/6] Add example Common Mean Link Delay Service configuration files.
On Tue, Dec 05, 2023 at 02:44:18AM +0100, Andrew Zaborowski wrote: > * if I stop a CMLDS client and rerun it, it will receive the CMLDS > notifications twice until the old subscription expires. If I restart > it again quickly enough it'll receive each notification 3 times. This > is because pmc_recv doesn't filter by .targetPortIdentity. It could > but it wouldn't be bullet proof anyway because the PMC port's identity > is based on the pid, which is not unique, so I'm not sure if it's > worth doing. Yeah, super annoying. Maybe the cure is to first cancel push notifications unconditionally? > * inhibit_delay_req / logMinPdelayReqInterval / > operLogPdelayReqInterval should not be used in the CMLDS client config > (which wouldn't be useful anyway) because they'll affect the > subscription renewals. Right, a check should be added to avoid this combination. > * I had two extra changes, one to always calculate the NRR in the > CMLDS port, Can't this be taken from the Link Port? Thanks, Richard ___ Linuxptp-devel mailing list Linuxptp-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linuxptp-devel
Re: [Linuxptp-devel] [PATCH v3 6/6] Add example Common Mean Link Delay Service configuration files.
On Mon, Dec 04, 2023 at 10:51:15PM +0100, Andrew Zaborowski wrote: > I assume ignore_transport_specific can be dropped in this version. Actually it is critical, if you care about being able to inter-operate. After all, nothing guarantees that the link partner is also running CMLDS. Experience teaches us that the very first thing users will do is the thing we think they shouldn't. Thanks, Richard ___ Linuxptp-devel mailing list Linuxptp-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linuxptp-devel
Re: [Linuxptp-devel] [PATCH v3 6/6] Add example Common Mean Link Delay Service configuration files.
I tested a basic 802.1AS type scenario with this v3 patchset on both ends, and it worked! We may have more test results in a few days if my colleague runs a real test suite. The only caveats were: * if I stop a CMLDS client and rerun it, it will receive the CMLDS notifications twice until the old subscription expires. If I restart it again quickly enough it'll receive each notification 3 times. This is because pmc_recv doesn't filter by .targetPortIdentity. It could but it wouldn't be bullet proof anyway because the PMC port's identity is based on the pid, which is not unique, so I'm not sure if it's worth doing. * inhibit_delay_req / logMinPdelayReqInterval / operLogPdelayReqInterval should not be used in the CMLDS client config (which wouldn't be useful anyway) because they'll affect the subscription renewals. * I had two extra changes, one to always calculate the NRR in the CMLDS port, and one to handle an exception specified in 802.1AS-2020 section 11.2.17.1 above NOTE 3 -- this can be added later separately from this CMLDS patchset Best regards configs/802.1as-2020-master-cmlds.cfg| 19 ++ configs/802.1as-2020-master-domain-0.cfg | 43 ++ configs/802.1as-2020-slave-cmlds.cfg | 19 ++ configs/802.1as-2020-slave-domain-0.cfg | 45 msg.h| 3 +- port.c | 7 ++-- 6 files changed, 130 insertions(+), 6 deletions(-) create mode 100644 configs/802.1as-2020-master-cmlds.cfg create mode 100644 configs/802.1as-2020-master-domain-0.cfg create mode 100644 configs/802.1as-2020-slave-cmlds.cfg create mode 100644 configs/802.1as-2020-slave-domain-0.cfg diff --git a/configs/802.1as-2020-master-cmlds.cfg b/configs/802.1as-2020-master-cmlds.cfg new file mode 100644 index 000..2e09c6d --- /dev/null +++ b/configs/802.1as-2020-master-cmlds.cfg @@ -0,0 +1,19 @@ +# +# Common Mean Link Delay Service (CMLDS) example configuration, +# containing those attributes which differ from the defaults. +# See the file default.cfg for the complete list of available options. +# +[global] +# Set this for CMLDS regardless of actual port roles on this node +clientOnly1 +free_running1 +assume_two_step1 +follow_up_info1 +asCapabletrue +network_transportL2 +uds_address/var/run/master-cmlds + +transportSpecific2 +clockIdentity01..80 + +delay_mechanismP2P diff --git a/configs/802.1as-2020-master-domain-0.cfg b/configs/802.1as-2020-master-domain-0.cfg new file mode 100644 index 000..0e69565 --- /dev/null +++ b/configs/802.1as-2020-master-domain-0.cfg @@ -0,0 +1,43 @@ +# +# 802.1AS configuration example for a single domain out of many (or not +# so many) on a multidomain-capable node. Uses a local CMLDS instance, +# see configs/802.1as-2020-master-cmlds.cfg. +# +[global] +gmCapable1 +priority1248 +priority2248 +logAnnounceInterval0 +logSyncInterval-3 +syncReceiptTimeout3 +neighborPropDelayThresh800 +min_neighbor_prop_delay-2000 +assume_two_step1 +path_trace_enabled1 +follow_up_info1 +asCapabletrue +network_transportL2 +BMCAnoop +# Required to quickly correct Time Jumps in master +step_threshold1 +inhibit_announce1 +operLogSyncInterval0 +operLogPdelayReqInterval2 +msg_interval_request1 +servo_offset_threshold30 +servo_num_offset_values10 + +# Master only bits +serverOnly1 +inhibit_announce1 + +uds_address/var/run/master-domain-0 +cmlds.server_address/var/run/master-cmlds +# FIXME: must set client_address per port +cmlds.client_address/var/run/master-client-0 + +domainNumber0 +transportSpecific1 +clockIdentity01..00 + +delay_mechanismCOMMON_P2P diff --git a/configs/802.1as-2020-slave-cmlds.cfg b/configs/802.1as-2020-slave-cmlds.cfg new file mode 100644 index 000..e78e468 --- /dev/null +++ b/configs/802.1as-2020-slave-cmlds.cfg @@ -0,0 +1,19 @@ +# +# Common Mean Link Delay Service (CMLDS) example configuration, +# containing those attributes which differ from the defaults. +# See the file default.cfg for the complete list of available options. +# +[global] +# Set this for CMLDS regardless of actual port roles on this node +clientOnly1 +free_running1 +assume_two_step1 +follow_up_info1 +asCapabletrue +network_transportL2 +uds_address/var/run/slave-cmlds + +transportSpecific2 +clockIdentity02..80 + +delay_mechanismP2P diff --git a/configs/802.1as-2020-slave-domain-0.cfg b/configs/802.1as-2020-slave-domain-0.cfg new file mode 100644
Re: [Linuxptp-devel] [PATCH v3 6/6] Add example Common Mean Link Delay Service configuration files.
On Sun, 3 Dec 2023 at 00:39, Richard Cochran wrote: > +# Common Mean Link Delay Service (CMLDS) example configuration for a > +# CMLDS Link Port, containing those attributes which differ from the While there's only one Link Port here I wouldn't mention this because the CMLDS config basically has to cover all of the ports. > +# defaults. See the file, default.cfg, for the complete list of > +# available options. > +# > +[global] > +clientOnly 1 > +clockIdentity C37D50..00 > +free_running 1 > +ignore_transport_specific 1 I assume ignore_transport_specific can be dropped in this version. > +transportSpecific 2 > +uds_address/var/run/cmlds_server > + > +[eth1] > +delay_mechanismP2P This line has to be the same for all interfaces in use by the CMLDS so I'd move this to [global] to avoid repetition. This way you basically have nothing port-specific to configure and can pass the interface names on the command line instead of listing here. On the client side cmlds.client_address will not allow this because I believe the source address has to be different for each port's socket. I thought (even before this came up) it would be nice for uds_address to default to something that includes the domainNumber, and now for cmlds.client_address to include the domainNumber and port number. I'm going to try test this patchset in an 802.1AS configuration and report back. Best regards ___ Linuxptp-devel mailing list Linuxptp-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linuxptp-devel
[Linuxptp-devel] [PATCH v3 6/6] Add example Common Mean Link Delay Service configuration files.
Signed-off-by: Richard Cochran --- configs/CMLDS_client.cfg | 10 ++ configs/CMLDS_server.cfg | 16 2 files changed, 26 insertions(+) create mode 100644 configs/CMLDS_client.cfg create mode 100644 configs/CMLDS_server.cfg diff --git a/configs/CMLDS_client.cfg b/configs/CMLDS_client.cfg new file mode 100644 index 000..ef10fef --- /dev/null +++ b/configs/CMLDS_client.cfg @@ -0,0 +1,10 @@ +# +# Common Mean Link Delay Service (CMLDS) example configuration for a +# CMLDS client, containing those attributes which differ from the +# defaults. See the file, default.cfg, for the complete list of +# available options. +# +[global] + +[eth1] +delay_mechanismCOMMON_P2P diff --git a/configs/CMLDS_server.cfg b/configs/CMLDS_server.cfg new file mode 100644 index 000..36f118c --- /dev/null +++ b/configs/CMLDS_server.cfg @@ -0,0 +1,16 @@ +# +# Common Mean Link Delay Service (CMLDS) example configuration for a +# CMLDS Link Port, containing those attributes which differ from the +# defaults. See the file, default.cfg, for the complete list of +# available options. +# +[global] +clientOnly 1 +clockIdentity C37D50..00 +free_running 1 +ignore_transport_specific 1 +transportSpecific 2 +uds_address/var/run/cmlds_server + +[eth1] +delay_mechanismP2P -- 2.39.2 ___ Linuxptp-devel mailing list Linuxptp-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linuxptp-devel