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>
This commit is contained in:

committed by
David S. Miller

parent
c2962897c9
commit
f646968f8f
@@ -332,8 +332,8 @@ ixgb_fix_features(struct net_device *netdev, netdev_features_t features)
|
||||
* Tx VLAN insertion does not work per HW design when Rx stripping is
|
||||
* disabled.
|
||||
*/
|
||||
if (!(features & NETIF_F_HW_VLAN_RX))
|
||||
features &= ~NETIF_F_HW_VLAN_TX;
|
||||
if (!(features & NETIF_F_HW_VLAN_CTAG_RX))
|
||||
features &= ~NETIF_F_HW_VLAN_CTAG_TX;
|
||||
|
||||
return features;
|
||||
}
|
||||
@@ -344,7 +344,7 @@ ixgb_set_features(struct net_device *netdev, netdev_features_t features)
|
||||
struct ixgb_adapter *adapter = netdev_priv(netdev);
|
||||
netdev_features_t changed = features ^ netdev->features;
|
||||
|
||||
if (!(changed & (NETIF_F_RXCSUM|NETIF_F_HW_VLAN_RX)))
|
||||
if (!(changed & (NETIF_F_RXCSUM|NETIF_F_HW_VLAN_CTAG_RX)))
|
||||
return 0;
|
||||
|
||||
adapter->rx_csum = !!(features & NETIF_F_RXCSUM);
|
||||
@@ -479,10 +479,10 @@ ixgb_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
|
||||
netdev->hw_features = NETIF_F_SG |
|
||||
NETIF_F_TSO |
|
||||
NETIF_F_HW_CSUM |
|
||||
NETIF_F_HW_VLAN_TX |
|
||||
NETIF_F_HW_VLAN_RX;
|
||||
NETIF_F_HW_VLAN_CTAG_TX |
|
||||
NETIF_F_HW_VLAN_CTAG_RX;
|
||||
netdev->features = netdev->hw_features |
|
||||
NETIF_F_HW_VLAN_FILTER;
|
||||
NETIF_F_HW_VLAN_CTAG_FILTER;
|
||||
netdev->hw_features |= NETIF_F_RXCSUM;
|
||||
|
||||
if (pci_using_dac) {
|
||||
@@ -1140,7 +1140,7 @@ ixgb_set_multi(struct net_device *netdev)
|
||||
}
|
||||
|
||||
alloc_failed:
|
||||
if (netdev->features & NETIF_F_HW_VLAN_RX)
|
||||
if (netdev->features & NETIF_F_HW_VLAN_CTAG_RX)
|
||||
ixgb_vlan_strip_enable(adapter);
|
||||
else
|
||||
ixgb_vlan_strip_disable(adapter);
|
||||
|
Reference in New Issue
Block a user