On Mon, 2018-10-01 at 18:26 -0700, Richard Cochran wrote:
> On Mon, Oct 01, 2018 at 06:11:16PM +0000, Patel, Vedang wrote:
> > 
> > On Mon, 2018-10-01 at 10:59 -0700, Richard Cochran wrote:
> > > 
> > > On Mon, Oct 01, 2018 at 05:24:48PM +0000, Patel, Vedang wrote:
> > > > 
> > > > 
> > > > I will add the comment for clearing the SYNC_RX_TIMER. It is
> > > > basically
> > > > to clear out the event returned by poll().
> > > But why?  Does the original code have a bug?  Please explain.
> > > 
> > In the original code, whenever we receive a FD_SYNC_RX_TIMER
> > timeout,
> > it is usually accompanied by a state transition. So,
> > port_*_transition() will take care of clearing the event for us (by
> > calling port_clr_tmo() at the beginning). But, when BMCA == 'noop',
> > there is nothing to do, so we are not clearing out the event and
> > poll()
> > will report the event in every loop. I am just taking care of
> > clearing
> > this event here.
> Then you should have followed through and removed the redundant clear
> in the state transition code.  Or what am I missing?
> 
We still need to clear out the timer when the device transitions out of
slave state for other events like EV_FAULT_DETECTED. So, I think we
still need to keep it there.

Thanks,
Vedang
> Thanks,
> Richard
_______________________________________________
Linuxptp-devel mailing list
Linuxptp-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linuxptp-devel

Reply via email to