aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/broadcom/bnx2.c
diff options
context:
space:
mode:
authorPatrick McHardy <kaber@trash.net>2013-04-18 22:04:27 -0400
committerDavid S. Miller <davem@davemloft.net>2013-04-19 14:45:26 -0400
commitf646968f8f7c624587de729115d802372b9063dd (patch)
tree2b8c6604306f5e74af9e16c17e2b611610982b65 /drivers/net/ethernet/broadcom/bnx2.c
parentc2962897c94605bc8f158a37dee8d867dda9f116 (diff)
net: vlan: rename NETIF_F_HW_VLAN_* feature flags to NETIF_F_HW_VLAN_CTAG_*
Rename the hardware VLAN acceleration features to include "CTAG" to indicate that they only support CTAGs. Follow up patches will introduce 802.1ad server provider tagging (STAGs) and require the distinction for hardware not supporting acclerating both. Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/broadcom/bnx2.c')
-rw-r--r--drivers/net/ethernet/broadcom/bnx2.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/net/ethernet/broadcom/bnx2.c b/drivers/net/ethernet/broadcom/bnx2.c
index f27b549b692d..42a8bc8df5dd 100644
--- a/drivers/net/ethernet/broadcom/bnx2.c
+++ b/drivers/net/ethernet/broadcom/bnx2.c
@@ -3553,7 +3553,7 @@ bnx2_set_rx_mode(struct net_device *dev)
3553 rx_mode = bp->rx_mode & ~(BNX2_EMAC_RX_MODE_PROMISCUOUS | 3553 rx_mode = bp->rx_mode & ~(BNX2_EMAC_RX_MODE_PROMISCUOUS |
3554 BNX2_EMAC_RX_MODE_KEEP_VLAN_TAG); 3554 BNX2_EMAC_RX_MODE_KEEP_VLAN_TAG);
3555 sort_mode = 1 | BNX2_RPM_SORT_USER0_BC_EN; 3555 sort_mode = 1 | BNX2_RPM_SORT_USER0_BC_EN;
3556 if (!(dev->features & NETIF_F_HW_VLAN_RX) && 3556 if (!(dev->features & NETIF_F_HW_VLAN_CTAG_RX) &&
3557 (bp->flags & BNX2_FLAG_CAN_KEEP_VLAN)) 3557 (bp->flags & BNX2_FLAG_CAN_KEEP_VLAN))
3558 rx_mode |= BNX2_EMAC_RX_MODE_KEEP_VLAN_TAG; 3558 rx_mode |= BNX2_EMAC_RX_MODE_KEEP_VLAN_TAG;
3559 if (dev->flags & IFF_PROMISC) { 3559 if (dev->flags & IFF_PROMISC) {
@@ -7695,7 +7695,7 @@ bnx2_fix_features(struct net_device *dev, netdev_features_t features)
7695 struct bnx2 *bp = netdev_priv(dev); 7695 struct bnx2 *bp = netdev_priv(dev);
7696 7696
7697 if (!(bp->flags & BNX2_FLAG_CAN_KEEP_VLAN)) 7697 if (!(bp->flags & BNX2_FLAG_CAN_KEEP_VLAN))
7698 features |= NETIF_F_HW_VLAN_RX; 7698 features |= NETIF_F_HW_VLAN_CTAG_RX;
7699 7699
7700 return features; 7700 return features;
7701} 7701}
@@ -7706,12 +7706,12 @@ bnx2_set_features(struct net_device *dev, netdev_features_t features)
7706 struct bnx2 *bp = netdev_priv(dev); 7706 struct bnx2 *bp = netdev_priv(dev);
7707 7707
7708 /* TSO with VLAN tag won't work with current firmware */ 7708 /* TSO with VLAN tag won't work with current firmware */
7709 if (features & NETIF_F_HW_VLAN_TX) 7709 if (features & NETIF_F_HW_VLAN_CTAG_TX)
7710 dev->vlan_features |= (dev->hw_features & NETIF_F_ALL_TSO); 7710 dev->vlan_features |= (dev->hw_features & NETIF_F_ALL_TSO);
7711 else 7711 else
7712 dev->vlan_features &= ~NETIF_F_ALL_TSO; 7712 dev->vlan_features &= ~NETIF_F_ALL_TSO;
7713 7713
7714 if ((!!(features & NETIF_F_HW_VLAN_RX) != 7714 if ((!!(features & NETIF_F_HW_VLAN_CTAG_RX) !=
7715 !!(bp->rx_mode & BNX2_EMAC_RX_MODE_KEEP_VLAN_TAG)) && 7715 !!(bp->rx_mode & BNX2_EMAC_RX_MODE_KEEP_VLAN_TAG)) &&
7716 netif_running(dev)) { 7716 netif_running(dev)) {
7717 bnx2_netif_stop(bp, false); 7717 bnx2_netif_stop(bp, false);
@@ -8551,7 +8551,7 @@ bnx2_init_one(struct pci_dev *pdev, const struct pci_device_id *ent)
8551 dev->hw_features |= NETIF_F_IPV6_CSUM | NETIF_F_TSO6; 8551 dev->hw_features |= NETIF_F_IPV6_CSUM | NETIF_F_TSO6;
8552 8552
8553 dev->vlan_features = dev->hw_features; 8553 dev->vlan_features = dev->hw_features;
8554 dev->hw_features |= NETIF_F_HW_VLAN_TX | NETIF_F_HW_VLAN_RX; 8554 dev->hw_features |= NETIF_F_HW_VLAN_CTAG_TX | NETIF_F_HW_VLAN_CTAG_RX;
8555 dev->features |= dev->hw_features; 8555 dev->features |= dev->hw_features;
8556 dev->priv_flags |= IFF_UNICAST_FLT; 8556 dev->priv_flags |= IFF_UNICAST_FLT;
8557 8557