On Tue, Jul 24, 2018 at 05:38:32PM +0000, Patel, Vedang wrote:
> So, following is what we think will do the job:
> - Add inhibit_announce option to stop announce messages as well as
> timeouts. (default: 0 - disabled)

Sounds okay.

> - Add source_port_identity_check option to disable checking for source
> port identities in sync and follow-up messages (default: 1 - enabled)

Or keeping with the negative tone, "ignore_source_id".  (Ignore and
inhibit sound good together.)

> - Add static_roles config which is a tristate - master, slave and
> disabled. When master or slave roles are selected, the FSM will
> directly assign those roles. (default: 'disabled')

We already have slaveOnly and masterOnly.  All you need is a new
option for your different BCMA, say "BCMA = noop".

Then provide two functions for p->state_machine, something like the
following pseudo code.

enum port_state designated_master_fsm() {
        return PS_GRAND_MASTER;
}
enum port_state designated_slave_fsm() {
        return PS_SLAVE;
}

port_open() {
        ...
        if (BMCA == noop) {
                p->state_machine = clock_slave_only(clock) ?
                        designated_slave_fsm : designated_master_fsm;
        }
}
 
> We also looked into the slaveOnly FSM for slave. But, we cannot use
> that because it still expects the announce message from the master
> before transitioning to UNCALIBRATED state.

You can surely use the slaveOnly option, but of course you wouldn't
use the ptp_slave_fsm function itself.

Thanks,
Richard

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Linuxptp-devel mailing list
Linuxptp-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linuxptp-devel

Reply via email to