aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/cxgb4/cxgb4_main.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/cxgb4/cxgb4_main.c')
-rw-r--r--drivers/net/cxgb4/cxgb4_main.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/drivers/net/cxgb4/cxgb4_main.c b/drivers/net/cxgb4/cxgb4_main.c
index 5f582dba928f..1bad50041427 100644
--- a/drivers/net/cxgb4/cxgb4_main.c
+++ b/drivers/net/cxgb4/cxgb4_main.c
@@ -1711,6 +1711,18 @@ static int set_tso(struct net_device *dev, u32 value)
1711 return 0; 1711 return 0;
1712} 1712}
1713 1713
1714static int set_flags(struct net_device *dev, u32 flags)
1715{
1716 if (flags & ~ETH_FLAG_RXHASH)
1717 return -EOPNOTSUPP;
1718
1719 if (flags & ETH_FLAG_RXHASH)
1720 dev->features |= NETIF_F_RXHASH;
1721 else
1722 dev->features &= ~NETIF_F_RXHASH;
1723 return 0;
1724}
1725
1714static struct ethtool_ops cxgb_ethtool_ops = { 1726static struct ethtool_ops cxgb_ethtool_ops = {
1715 .get_settings = get_settings, 1727 .get_settings = get_settings,
1716 .set_settings = set_settings, 1728 .set_settings = set_settings,
@@ -1741,6 +1753,7 @@ static struct ethtool_ops cxgb_ethtool_ops = {
1741 .get_wol = get_wol, 1753 .get_wol = get_wol,
1742 .set_wol = set_wol, 1754 .set_wol = set_wol,
1743 .set_tso = set_tso, 1755 .set_tso = set_tso,
1756 .set_flags = set_flags,
1744 .flash_device = set_flash, 1757 .flash_device = set_flash,
1745}; 1758};
1746 1759
@@ -3203,7 +3216,7 @@ static int __devinit init_one(struct pci_dev *pdev,
3203 3216
3204 netdev->features |= NETIF_F_SG | NETIF_F_TSO | NETIF_F_TSO6; 3217 netdev->features |= NETIF_F_SG | NETIF_F_TSO | NETIF_F_TSO6;
3205 netdev->features |= NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM; 3218 netdev->features |= NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM;
3206 netdev->features |= NETIF_F_GRO | highdma; 3219 netdev->features |= NETIF_F_GRO | NETIF_F_RXHASH | highdma;
3207 netdev->features |= NETIF_F_HW_VLAN_TX | NETIF_F_HW_VLAN_RX; 3220 netdev->features |= NETIF_F_HW_VLAN_TX | NETIF_F_HW_VLAN_RX;
3208 netdev->vlan_features = netdev->features & VLAN_FEAT; 3221 netdev->vlan_features = netdev->features & VLAN_FEAT;
3209 3222