|
@@ -1138,7 +1138,10 @@ static int be_vlan_add_vid(struct net_device *netdev, __be16 proto, u16 vid)
|
|
|
|
|
|
/* Packets with VID 0 are always received by Lancer by default */
|
|
/* Packets with VID 0 are always received by Lancer by default */
|
|
if (lancer_chip(adapter) && vid == 0)
|
|
if (lancer_chip(adapter) && vid == 0)
|
|
- goto ret;
|
|
|
|
|
|
+ return status;
|
|
|
|
+
|
|
|
|
+ if (adapter->vlan_tag[vid])
|
|
|
|
+ return status;
|
|
|
|
|
|
adapter->vlan_tag[vid] = 1;
|
|
adapter->vlan_tag[vid] = 1;
|
|
adapter->vlans_added++;
|
|
adapter->vlans_added++;
|
|
@@ -1148,7 +1151,7 @@ static int be_vlan_add_vid(struct net_device *netdev, __be16 proto, u16 vid)
|
|
adapter->vlans_added--;
|
|
adapter->vlans_added--;
|
|
adapter->vlan_tag[vid] = 0;
|
|
adapter->vlan_tag[vid] = 0;
|
|
}
|
|
}
|
|
-ret:
|
|
|
|
|
|
+
|
|
return status;
|
|
return status;
|
|
}
|
|
}
|
|
|
|
|