On Wed, Dec 06, 2017 at 02:44:23PM +0100, Miroslav Lichvar wrote: > A better option might be to forward only responses to the UDS port. We > don't expect a PTP clock to be listening there, right?
Right, but we should also forward the ACKNOWLEDGE messages. > --- a/clock.c > +++ b/clock.c > @@ -1265,7 +1266,8 @@ static void clock_forward_mgmt_msg(struct clock *c, > struct port *p, struct ptp_m > pr_err("port %d: management forward failed", > port_number(piter)); > } > - if (clock_do_forward_mgmt(c, p, c->uds_port, msg, &msg_ready)) > + if (management_action(msg) == RESPONSE && > + clock_do_forward_mgmt(c, p, c->uds_port, msg, &msg_ready)) > pr_err("uds port: management forward failed"); > if (msg_ready) { > msg_post_recv(msg, pdulen); > > > Does it make sense? Yes, but the check should be made in this function static int forwarding(struct clock *c, struct port *p) by passing in the 'msg' as well. 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