search for: netdev_notifier_change_info

Displaying 11 results from an estimated 11 matches for "netdev_notifier_change_info".

2019 Mar 29
1
[PATCH net v4] failover: allow name change on IFF_UP slave interfaces
On Thu, 28 Mar 2019 19:47:27 -0400 Si-Wei Liu <si-wei.liu at oracle.com> wrote: > + if (unlikely(dev->flags & IFF_UP)) { > + struct netdev_notifier_change_info change_info; > + > + change_info.flags_changed = 0; Simpler to use structure initialization, which also avoid any chance of unititialized fields. struct netdev_notifier_change_info change_info = { .flags_changed = 0 };
2019 Apr 05
2
[PATCH net v6] failover: allow name change on IFF_UP slave interfaces
On Wed, 3 Apr 2019 00:52:47 -0400 Si-Wei Liu <si-wei.liu at oracle.com> wrote: > > + if (unlikely(dev->flags & IFF_UP)) { > + struct netdev_notifier_change_info change_info = { > + .info.dev = dev, > + }; > + > + call_netdevice_notifiers_info(NETDEV_CHANGE, > + &change_info.info); > + } This notifier is not really necessary, there already is a CHANGENAME that gets sent. NETDEV_CHANGE is used in other cases to mean that...
2019 Apr 05
2
[PATCH net v6] failover: allow name change on IFF_UP slave interfaces
On Wed, 3 Apr 2019 00:52:47 -0400 Si-Wei Liu <si-wei.liu at oracle.com> wrote: > > + if (unlikely(dev->flags & IFF_UP)) { > + struct netdev_notifier_change_info change_info = { > + .info.dev = dev, > + }; > + > + call_netdevice_notifiers_info(NETDEV_CHANGE, > + &change_info.info); > + } This notifier is not really necessary, there already is a CHANGENAME that gets sent. NETDEV_CHANGE is used in other cases to mean that...
2019 Apr 05
0
[PATCH net v6] failover: allow name change on IFF_UP slave interfaces
On Fri, Apr 05, 2019 at 02:47:01PM -0700, Stephen Hemminger wrote: > On Wed, 3 Apr 2019 00:52:47 -0400 > Si-Wei Liu <si-wei.liu at oracle.com> wrote: > > > > > + if (unlikely(dev->flags & IFF_UP)) { > > + struct netdev_notifier_change_info change_info = { > > + .info.dev = dev, > > + }; > > + > > + call_netdevice_notifiers_info(NETDEV_CHANGE, > > + &change_info.info); > > + } > > This notifier is not really necessary, there already is a CHANGENAME > that gets sent. >...
2019 Mar 29
0
[PATCH net v4] failover: allow name change on IFF_UP slave interfaces
...ock); 1241 1242 synchronize_rcu(); 1243 1244 write_lock_bh(&dev_base_lock); 1245 hlist_add_head_rcu(&dev->name_hlist, dev_name_hash(net, dev->name)); 1246 write_unlock_bh(&dev_base_lock); 1247 1248 if (unlikely(dev->flags & IFF_UP)) { 1249 struct netdev_notifier_change_info change_info; 1250 1251 change_info.flags_changed = 0; > 1252 call_netdevice_notifiers_info(NETDEV_CHANGE, dev, 1253 &change_info.info); 1254 } 1255 1256 ret = call_netdevice_notifiers(NETDEV_CHANGENAME, dev); 1257 ret = notifier_to_errno(ret); 1258 1259...
2019 Apr 02
0
[PATCH net v5] failover: allow name change on IFF_UP slave interfaces
...> @@ -1232,6 +1246,15 @@ int dev_change_name(struct net_device *dev, const char *newname) > hlist_add_head_rcu(&dev->name_hlist, dev_name_hash(net, dev->name)); > write_unlock_bh(&dev_base_lock); > > + if (unlikely(dev->flags & IFF_UP)) { > + struct netdev_notifier_change_info change_info = { > + .info.dev = dev, > + }; > + > + call_netdevice_notifiers_info(NETDEV_CHANGE, > + &change_info.info); > + } > + > ret = call_netdevice_notifiers(NETDEV_CHANGENAME, dev); > ret = notifier_to_errno(ret); > >
2019 Apr 02
0
[PATCH net v5] failover: allow name change on IFF_UP slave interfaces
...q); > @@ -1232,6 +1246,15 @@ int dev_change_name(struct net_device *dev, const char *newname) > hlist_add_head_rcu(&dev->name_hlist, dev_name_hash(net, dev->name)); > write_unlock_bh(&dev_base_lock); > > + if (unlikely(dev->flags & IFF_UP)) { > + struct netdev_notifier_change_info change_info = { > + .info.dev = dev, > + }; > + > + call_netdevice_notifiers_info(NETDEV_CHANGE, > + &change_info.info); > + } > + > ret = call_netdevice_notifiers(NETDEV_CHANGENAME, dev); > ret = notifier_to_errno(ret); > > -- > 1.8.3.1
2019 Mar 29
0
[PATCH net v4] failover: allow name change on IFF_UP slave interfaces
...> @@ -1227,6 +1241,14 @@ int dev_change_name(struct net_device *dev, const char *newname) > hlist_add_head_rcu(&dev->name_hlist, dev_name_hash(net, dev->name)); > write_unlock_bh(&dev_base_lock); > > + if (unlikely(dev->flags & IFF_UP)) { > + struct netdev_notifier_change_info change_info; > + > + change_info.flags_changed = 0; > + call_netdevice_notifiers_info(NETDEV_CHANGE, dev, > + &change_info.info); This function no longer takes the dev parameter in the net-next kernel. Did you consider calling netdev_state_change() although it does sen...
2019 Mar 29
0
[PATCH net v4] failover: allow name change on IFF_UP slave interfaces
...gt; > const char *newname) > > > hlist_add_head_rcu(&dev->name_hlist, dev_name_hash(net, > > > dev->name)); > > > write_unlock_bh(&dev_base_lock); > > > + if (unlikely(dev->flags & IFF_UP)) { > > > + struct netdev_notifier_change_info change_info; > > > + > > > + change_info.flags_changed = 0; > > > + call_netdevice_notifiers_info(NETDEV_CHANGE, dev, > > > + &change_info.info); > > > > This function no longer takes the dev parameter in th...
2019 Apr 05
2
[PATCH net v6] failover: allow name change on IFF_UP slave interfaces
...q); > @@ -1232,6 +1246,15 @@ int dev_change_name(struct net_device *dev, const char *newname) > hlist_add_head_rcu(&dev->name_hlist, dev_name_hash(net, dev->name)); > write_unlock_bh(&dev_base_lock); > > + if (unlikely(dev->flags & IFF_UP)) { > + struct netdev_notifier_change_info change_info = { > + .info.dev = dev, > + }; > + > + call_netdevice_notifiers_info(NETDEV_CHANGE, > + &change_info.info); > + } > + > ret = call_netdevice_notifiers(NETDEV_CHANGENAME, dev); > ret = notifier_to_errno(ret); > > diff --git a/net/...
2019 Apr 05
2
[PATCH net v6] failover: allow name change on IFF_UP slave interfaces
...q); > @@ -1232,6 +1246,15 @@ int dev_change_name(struct net_device *dev, const char *newname) > hlist_add_head_rcu(&dev->name_hlist, dev_name_hash(net, dev->name)); > write_unlock_bh(&dev_base_lock); > > + if (unlikely(dev->flags & IFF_UP)) { > + struct netdev_notifier_change_info change_info = { > + .info.dev = dev, > + }; > + > + call_netdevice_notifiers_info(NETDEV_CHANGE, > + &change_info.info); > + } > + > ret = call_netdevice_notifiers(NETDEV_CHANGENAME, dev); > ret = notifier_to_errno(ret); > > diff --git a/net/...