[Linuxptp-devel] [PATCH V2 5/8] config: Add a configuration option for TC mode.

2018-04-20 Thread Richard Cochran
This patch adds a new configuation option that enables transparent clock mode. When TC mode is specified, the configured delay mechanism must also match. The legacy behavior of upgrading a multi-port clock from OC to BC is preserved. Signed-off-by: Richard Cochran ---

[Linuxptp-devel] [PATCH V2 6/8] config: Add a configuration option for preventing loops in TC mode.

2018-04-20 Thread Richard Cochran
According to 1588, PTP message loops are simply someone else's problem with respect to transparent clocks. Since we are running the BMCA for syntonization anyway, we might as well go ahead and implement the spanning tree for PTP messages. Signed-off-by: Richard Cochran

[Linuxptp-devel] [PATCH V2 3/8] p2p_tc: Implement a peer to peer transparent clock.

2018-04-20 Thread Richard Cochran
The P2P TC forwards Announce, Management, Signaling, and Sync messages, consumes P2P Delay messages, and drops E2E Delay messages. This implementation tracks the GM using the BMCA in order to syntonize (or possibly even synchronize) with it. Signed-off-by: Richard Cochran

[Linuxptp-devel] [PATCH V2 7/8] Add an example configuration for a peer to peer transparent clock.

2018-04-20 Thread Richard Cochran
Signed-off-by: Richard Cochran --- P2P-TC.cfg | 92 ++ 1 file changed, 92 insertions(+) create mode 100644 P2P-TC.cfg diff --git a/P2P-TC.cfg b/P2P-TC.cfg new file mode 100644 index 000..94029bb ---

[Linuxptp-devel] [PATCH V2 4/8] e2e_tc: Implement an end to end transparent clock.

2018-04-20 Thread Richard Cochran
The E2E TC forwards Announce, Delay_Req, Delay_Resp, Management, Signaling, and Sync messages, and drops P2P Delay messages. This implementation tracks the GM using the BMCA in order to syntonize (or possibly even synchronize) with it. Signed-off-by: Richard Cochran

[Linuxptp-devel] [PATCH V2 8/8] Add an example configuration for an end to end transparent clock.

2018-04-20 Thread Richard Cochran
Signed-off-by: Richard Cochran --- E2E-TC.cfg | 92 ++ 1 file changed, 92 insertions(+) create mode 100644 E2E-TC.cfg diff --git a/E2E-TC.cfg b/E2E-TC.cfg new file mode 100644 index 000..b87a07f ---

[Linuxptp-devel] [PATCH V2 0/8] Transparent Clock - third and final part

2018-04-20 Thread Richard Cochran
This series add support for running a TC over multiple ports. This applies on top of my recently posted telecom series. Comments, testing, and review are most welcome. Changed in V2: ~~ - Detect and drop frames that arrive with time stamps. - Add an option to enforce a spanning

[Linuxptp-devel] [PATCH V2 2/8] tc: Add the transparent clock implementation.

2018-04-20 Thread Richard Cochran
This patch adds code that sends an event messages received on one port out all the other ports and calculates the residence time. The correction, ingress port, and the original message are remembered in a TC transmit descriptor. These descriptors are recycled in a memory pool in a similar way to

Re: [Linuxptp-devel] [PATCH 6/7] bmc: Added dscmp_alternate

2018-04-20 Thread Richard Cochran
On Fri, Apr 20, 2018 at 12:14:27PM +0200, Anders Selhammer wrote: > @@ -81,7 +81,7 @@ int dscmp2(struct dataset *a, struct dataset *b) > return 0; > } > > -int dscmp_ieee1588(struct dataset *a, struct dataset *b) > +static int dscmp(struct dataset *a, struct dataset *b, enum bmca_type

[Linuxptp-devel] [PATCH V2 6/6] telecom: Introduce the G.8275.masterOnly option.

2018-04-20 Thread Richard Cochran
When G.8275.masterOnly is true, the port always returns NULL when computing its best foreign master. As a result, the port will never enter the SLAVE state, and the clock will ignore Announce messages received on that port. This attribute is specifically called out in G.8275.1 and G.8275.2, and

[Linuxptp-devel] [PATCH V2 4/6] telecom: Add a configuration option for G.8275.portDS.localPriority.

2018-04-20 Thread Richard Cochran
Signed-off-by: Richard Cochran --- config.c | 1 + default.cfg| 1 + gPTP.cfg | 1 + port.c | 3 ++- port_private.h | 1 + ptp4l.8| 15 +++ 6 files changed, 21 insertions(+), 1 deletion(-) diff --git a/config.c

[Linuxptp-devel] [PATCH V2 3/6] telecom: Add a configuration option for G.8275.defaultDS.localPriority.

2018-04-20 Thread Richard Cochran
Signed-off-by: Richard Cochran --- clock.c | 3 ++- config.c| 1 + default.cfg | 1 + gPTP.cfg| 1 + ptp4l.8 | 14 ++ 5 files changed, 19 insertions(+), 1 deletion(-) diff --git a/clock.c b/clock.c index cd7f850..1886c26 100644 ---

[Linuxptp-devel] [PATCH V2 1/6] telecom: Introduce the local priority attribute into the data set.

2018-04-20 Thread Richard Cochran
The Telecom Profiles G.8275.1 and G.8275.2 have invented a new per-port and per-clock attribute, not in 1588, called "localPriority". The use of this attribute is a distinguishing feature of the telecom data set comparison algorithm. This patch adds the attribute, hard coded to its default value.

[Linuxptp-devel] [PATCH V2 2/6] telecom: Add the data set comparison algorithm from the Telecom Profiles.

2018-04-20 Thread Richard Cochran
The first half of the telecom algorithm from G.8275.1 and G.8275.2 differs from the one in 1588, making use of profile specific "localPriority" attributes. Signed-off-by: Richard Cochran --- bmc.h | 12 +++ makefile | 2 +- telecom.c | 73

[Linuxptp-devel] [PATCH V2 5/6] telecom: Add a configuration option to use the alternate BMCA.

2018-04-20 Thread Richard Cochran
Signed-off-by: Richard Cochran --- bmc.h | 5 + clock.c | 6 +- config.c| 9 + default.cfg | 1 + gPTP.cfg| 1 + port.c | 6 +- 6 files changed, 26 insertions(+), 2 deletions(-) diff --git a/bmc.h b/bmc.h index

[Linuxptp-devel] [PATCH V2 0/6] Telecom profile support

2018-04-20 Thread Richard Cochran
This series adds support for the alternate BMCA and custom attributes needed to support the various telecom profiles. Version 1 of the series was posted back on August 18, 2017. Changes in V2: ~~ - Address review comments regarding configuration variable naming - change "notSlave"

Re: [Linuxptp-devel] [PATCH 6/7] bmc: Added dscmp_alternate

2018-04-20 Thread Keller, Jacob E
> -Original Message- > From: Anders Selhammer [mailto:anders.selham...@est.tech] > Sent: Friday, April 20, 2018 3:14 AM > To: linuxptp-devel@lists.sourceforge.net > Subject: [Linuxptp-devel] [PATCH 6/7] bmc: Added dscmp_alternate > > /** > * BMC state decision algorithm. > * @param

Re: [Linuxptp-devel] [PATCH 1/1] nsm: Allow commands on command line.

2018-04-20 Thread Richard Cochran
On Thu, Apr 19, 2018 at 01:43:23PM +0200, Ethel wrote: > Add a batch mode, where the commands are taken from the command line > instead of the standard input. Applied. Thanks, Richard -- Check out the vibrant tech

[Linuxptp-devel] [PATCH 5/7] ds: Added localPriority attribute

2018-04-20 Thread Anders Selhammer
Signed-off-by: Anders Selhammer --- clock.c| 7 +++ clock.h| 7 +++ ds.h | 1 + port.c | 20 +--- port.h | 9 - port_private.h | 1 + 6 files changed, 37 insertions(+), 8 deletions(-) diff

[Linuxptp-devel] [PATCH 4/7] bmc: Renamed dscmp to dscmp_ieee1588

2018-04-20 Thread Anders Selhammer
Signed-off-by: Anders Selhammer --- bmc.c | 2 +- bmc.h | 2 +- clock.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/bmc.c b/bmc.c index b6f8a92..d346397 100644 --- a/bmc.c +++ b/bmc.c @@ -81,7 +81,7 @@ int dscmp2(struct dataset *a, struct

[Linuxptp-devel] [PATCH 3/7] clock: Renamed get function for clock dataset

2018-04-20 Thread Anders Selhammer
Signed-off-by: Anders Selhammer --- bmc.c | 2 +- clock.c | 6 +++--- clock.h | 6 +++--- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/bmc.c b/bmc.c index a2103b5..b6f8a92 100644 --- a/bmc.c +++ b/bmc.c @@ -146,7 +146,7 @@ enum port_state

[Linuxptp-devel] [PATCH 6/7] bmc: Added dscmp_alternate

2018-04-20 Thread Anders Selhammer
Signed-off-by: Anders Selhammer --- bmc.c | 48 +++- bmc.h | 15 +++ 2 files changed, 54 insertions(+), 9 deletions(-) diff --git a/bmc.c b/bmc.c index d346397..a86148d 100644 --- a/bmc.c +++ b/bmc.c @@ -81,7

[Linuxptp-devel] [PATCH 0/7] Adding option to select alternate bmca defined in ITU-T G.8275.1

2018-04-20 Thread Anders Selhammer
In profile ITU-T G.8275.1 and Alternate Best Master Clock Algorithm is defined. This includes the new attribute local priority for both the clock and the port. This set of patches makes it possible to configure local priority and select the alternate BCMA instead of default IEEE1588 BCMA. Anders

[Linuxptp-devel] [PATCH 7/7] Add a configuration file option for bmca and local priority

2018-04-20 Thread Anders Selhammer
Signed-off-by: Anders Selhammer --- clock.c | 15 --- config.c| 12 +++- default.cfg | 3 +++ gPTP.cfg| 3 +++ port.c | 1 + 5 files changed, 30 insertions(+), 4 deletions(-) diff --git a/clock.c b/clock.c index 272c7da..15bd6c5

[Linuxptp-devel] [PATCH 2/7] clock: Added getter for dscmp configured for the clock

2018-04-20 Thread Anders Selhammer
Signed-off-by: Anders Selhammer --- bmc.c | 2 ++ bmc.h | 9 ++--- clock.c| 7 ++- clock.h| 8 port.c | 5 +++-- port_private.h | 1 - 6 files changed, 25 insertions(+), 7 deletions(-) diff --git a/bmc.c