Commit c60882a4 authored by Juhee Kang's avatar Juhee Kang Committed by David S. Miller

hv_netvsc: use netif_is_bond_master() instead of open code

Use netif_is_bond_master() function instead of open code, which is
((event_dev->priv_flags & IFF_BONDING) && (event_dev->flags & IFF_MASTER)).
This patch doesn't change logic.
Signed-off-by: default avatarJuhee Kang <claudiajkang@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 4b70dce2
...@@ -2742,8 +2742,7 @@ static int netvsc_netdev_event(struct notifier_block *this, ...@@ -2742,8 +2742,7 @@ static int netvsc_netdev_event(struct notifier_block *this,
return NOTIFY_DONE; return NOTIFY_DONE;
/* Avoid Bonding master dev with same MAC registering as VF */ /* Avoid Bonding master dev with same MAC registering as VF */
if ((event_dev->priv_flags & IFF_BONDING) && if (netif_is_bond_master(event_dev))
(event_dev->flags & IFF_MASTER))
return NOTIFY_DONE; return NOTIFY_DONE;
switch (event) { switch (event) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment