Re: [Linuxptp-devel] [PATCHv2 8/9] transport: pass struct interface to transport_open
PTP IEEE 1588 stack for Linux
Brought to you by:
rcochran
From: Richard C. <ric...@gm...> - 2017-08-05 08:21:53
|
On Sat, Jul 15, 2017 at 09:33:10PM +0800, Hangbin Liu wrote: > Pass struct interface so we can use ts_iface in HW filter. So the problem is that the raw layer should use name = iface->ts_iface but the others need name = iface->name Let's avoid touching so many files by solving this differently... > -int transport_open(struct transport *t, const char *name, > +int transport_open(struct transport *t, struct interface *iface, > struct fdarray *fda, enum timestamp_type tt) > { const char *name; switch (t->type) { case TRANS_IEEE_802_3: name = iface->ts_iface; break; default: name = iface->name; break; } > return t->open(t, name, fda, tt); > } |