Re: [RFC] switchdev: generate phys_port_name in the core

2017-07-28 Thread Andrew Lunn
On Thu, Jul 27, 2017 at 07:31:22PM -0700, Jakub Kicinski wrote: > On Thu, 27 Jul 2017 13:30:44 +0300, Or Gerlitz wrote: > > > want to add port splitting support, for example, reporting the name on > > > physical ports will become more of a necessity. > > > > > If we adopt Jiri's suggestion of re

Re: [RFC] switchdev: generate phys_port_name in the core

2017-07-28 Thread Jakub Kicinski
On Fri, 28 Jul 2017 07:58:15 +0200, Jiri Pirko wrote: > Fri, Jul 28, 2017 at 07:35:07AM CEST, j...@resnulli.us wrote: > >Fri, Jul 28, 2017 at 04:31:22AM CEST, jakub.kicin...@netronome.com wrote: > >>On Thu, 27 Jul 2017 13:30:44 +0300, Or Gerlitz wrote: > >>> > want to add port splitting support

Re: [RFC] switchdev: generate phys_port_name in the core

2017-07-28 Thread Jakub Kicinski
On Fri, 28 Jul 2017 07:35:07 +0200, Jiri Pirko wrote: > >+enum { > >+NETDEV_PORT_EXTERNAL, > >+NETDEV_PORT_EXTERNAL_SPLIT, > >+NETDEV_PORT_PCI_PF, > > Isn't PF also EXTERNAL? Cant VF be split? What I'm getting at, shoudn't > these be flags? By external PF do you mean not connected t

Re: [RFC] switchdev: generate phys_port_name in the core

2017-07-27 Thread Jiri Pirko
Fri, Jul 28, 2017 at 07:35:07AM CEST, j...@resnulli.us wrote: >Fri, Jul 28, 2017 at 04:31:22AM CEST, jakub.kicin...@netronome.com wrote: >>On Thu, 27 Jul 2017 13:30:44 +0300, Or Gerlitz wrote: >>> > want to add port splitting support, for example, reporting the name on >>> > physical ports will bec

Re: [RFC] switchdev: generate phys_port_name in the core

2017-07-27 Thread Jiri Pirko
Fri, Jul 28, 2017 at 04:31:22AM CEST, jakub.kicin...@netronome.com wrote: >On Thu, 27 Jul 2017 13:30:44 +0300, Or Gerlitz wrote: >> > want to add port splitting support, for example, reporting the name on >> > physical ports will become more of a necessity. >> >> > If we adopt Jiri's suggestion

Re: [RFC] switchdev: generate phys_port_name in the core

2017-07-27 Thread Jakub Kicinski
On Thu, 27 Jul 2017 19:31:22 -0700, Jakub Kicinski wrote: > +static size_t rtnl_port_info_size(void) > +{ > + size_t port_info_size = nla_total_size(0) + /* nest IFLA_PORT_INFO */ nla_total_size(4) + /* TYPE */ > + nla_total_size(4)

[RFC] switchdev: generate phys_port_name in the core

2017-07-27 Thread Jakub Kicinski
On Thu, 27 Jul 2017 13:30:44 +0300, Or Gerlitz wrote: > > want to add port splitting support, for example, reporting the name on > > physical ports will become more of a necessity. > > > If we adopt Jiri's suggestion of returning structured data it will be > > very easy to give user space type a