summaryrefslogtreecommitdiff
path: root/net/8021q/vlan.c
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2017-11-12 03:17:05 +0300
committerDavid S. Miller <davem@davemloft.net>2017-11-12 03:17:05 +0300
commitfdae5f37a88caed9d2105f5a1ff609322f9e5416 (patch)
tree086808d640803b16286a318eb4d0895006de5c19 /net/8021q/vlan.c
parent7c5556decd0a629e9ee02e93653f75ba7b7da03c (diff)
parentb39545684a90ef3374abc0969d64c7bc540d128d (diff)
downloadlinux-fdae5f37a88caed9d2105f5a1ff609322f9e5416.tar.xz
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Diffstat (limited to 'net/8021q/vlan.c')
-rw-r--r--net/8021q/vlan.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/net/8021q/vlan.c b/net/8021q/vlan.c
index a0103500cc6d..8dfdd94e430f 100644
--- a/net/8021q/vlan.c
+++ b/net/8021q/vlan.c
@@ -379,6 +379,9 @@ static int vlan_device_event(struct notifier_block *unused, unsigned long event,
dev->name);
vlan_vid_add(dev, htons(ETH_P_8021Q), 0);
}
+ if (event == NETDEV_DOWN &&
+ (dev->features & NETIF_F_HW_VLAN_CTAG_FILTER))
+ vlan_vid_del(dev, htons(ETH_P_8021Q), 0);
vlan_info = rtnl_dereference(dev->vlan_info);
if (!vlan_info)
@@ -426,9 +429,6 @@ static int vlan_device_event(struct notifier_block *unused, unsigned long event,
struct net_device *tmp;
LIST_HEAD(close_list);
- if (dev->features & NETIF_F_HW_VLAN_CTAG_FILTER)
- vlan_vid_del(dev, htons(ETH_P_8021Q), 0);
-
/* Put all VLANs for this dev in the down state too. */
vlan_group_for_each_dev(grp, i, vlandev) {
flgs = vlandev->flags;