Re: [patch net-next v3 1/3] net: devlink: allow to change namespaces

2019-08-13 Thread Jakub Kicinski
On Tue, 13 Aug 2019 08:13:55 +0200, Jiri Pirko wrote: > Tue, Aug 13, 2019 at 03:21:22AM CEST, jakub.kicin...@netronome.com wrote: > >On Mon, 12 Aug 2019 15:47:49 +0200, Jiri Pirko wrote: > >> @@ -6953,9 +7089,33 @@ int devlink_compat_switch_id_get(struct net_device > >> *dev, > >>return 0; >

Re: [patch net-next v3 1/3] net: devlink: allow to change namespaces

2019-08-12 Thread Jiri Pirko
Tue, Aug 13, 2019 at 03:21:22AM CEST, jakub.kicin...@netronome.com wrote: >On Mon, 12 Aug 2019 15:47:49 +0200, Jiri Pirko wrote: >> @@ -6953,9 +7089,33 @@ int devlink_compat_switch_id_get(struct net_device >> *dev, >> return 0; >> } >> >> +static void __net_exit devlink_pernet_exit(struct

Re: [patch net-next v3 1/3] net: devlink: allow to change namespaces

2019-08-12 Thread Jakub Kicinski
On Mon, 12 Aug 2019 15:47:49 +0200, Jiri Pirko wrote: > @@ -6953,9 +7089,33 @@ int devlink_compat_switch_id_get(struct net_device > *dev, > return 0; > } > > +static void __net_exit devlink_pernet_exit(struct net *net) > +{ > + struct devlink *devlink; > + > + mutex_lock(&devlink_

[patch net-next v3 1/3] net: devlink: allow to change namespaces

2019-08-12 Thread Jiri Pirko
From: Jiri Pirko All devlink instances are created in init_net and stay there for a lifetime. Allow user to be able to move devlink instances into namespaces. Signed-off-by: Jiri Pirko --- v2->v3: - added notifications for all objects v1->v2: - change the check for multiple attributes - add war