]> git.karo-electronics.de Git - mv-sheeva.git/blobdiff - drivers/net/vxge/vxge-ethtool.c
net: vxge: convert to hw_features
[mv-sheeva.git] / drivers / net / vxge / vxge-ethtool.c
index 43c458323f83b160eaa0b0a11a02d59b6cc49696..5aef6c893aeef7d7d0891b30a318bd331e30d91f 100644 (file)
@@ -1071,35 +1071,6 @@ static int vxge_ethtool_get_regs_len(struct net_device *dev)
        return sizeof(struct vxge_hw_vpath_reg) * vdev->no_of_vpath;
 }
 
-static u32 vxge_get_rx_csum(struct net_device *dev)
-{
-       struct vxgedev *vdev = netdev_priv(dev);
-
-       return vdev->rx_csum;
-}
-
-static int vxge_set_rx_csum(struct net_device *dev, u32 data)
-{
-       struct vxgedev *vdev = netdev_priv(dev);
-
-       if (data)
-               vdev->rx_csum = 1;
-       else
-               vdev->rx_csum = 0;
-
-       return 0;
-}
-
-static int vxge_ethtool_op_set_tso(struct net_device *dev, u32 data)
-{
-       if (data)
-               dev->features |= (NETIF_F_TSO | NETIF_F_TSO6);
-       else
-               dev->features &= ~(NETIF_F_TSO | NETIF_F_TSO6);
-
-       return 0;
-}
-
 static int vxge_ethtool_get_sset_count(struct net_device *dev, int sset)
 {
        struct vxgedev *vdev = netdev_priv(dev);
@@ -1119,40 +1090,6 @@ static int vxge_ethtool_get_sset_count(struct net_device *dev, int sset)
        }
 }
 
-static int vxge_set_flags(struct net_device *dev, u32 data)
-{
-       struct vxgedev *vdev = netdev_priv(dev);
-       enum vxge_hw_status status;
-
-       if (ethtool_invalid_flags(dev, data, ETH_FLAG_RXHASH))
-               return -EINVAL;
-
-       if (!!(data & ETH_FLAG_RXHASH) == vdev->devh->config.rth_en)
-               return 0;
-
-       if (netif_running(dev) || (vdev->config.rth_steering == NO_STEERING))
-               return -EINVAL;
-
-       vdev->devh->config.rth_en = !!(data & ETH_FLAG_RXHASH);
-
-       /* Enabling RTH requires some of the logic in vxge_device_register and a
-        * vpath reset.  Due to these restrictions, only allow modification
-        * while the interface is down.
-        */
-       status = vxge_reset_all_vpaths(vdev);
-       if (status != VXGE_HW_OK) {
-               vdev->devh->config.rth_en = !vdev->devh->config.rth_en;
-               return -EFAULT;
-       }
-
-       if (vdev->devh->config.rth_en)
-               dev->features |= NETIF_F_RXHASH;
-       else
-               dev->features &= ~NETIF_F_RXHASH;
-
-       return 0;
-}
-
 static int vxge_fw_flash(struct net_device *dev, struct ethtool_flash *parms)
 {
        struct vxgedev *vdev = netdev_priv(dev);
@@ -1181,19 +1118,10 @@ static const struct ethtool_ops vxge_ethtool_ops = {
        .get_link               = ethtool_op_get_link,
        .get_pauseparam         = vxge_ethtool_getpause_data,
        .set_pauseparam         = vxge_ethtool_setpause_data,
-       .get_rx_csum            = vxge_get_rx_csum,
-       .set_rx_csum            = vxge_set_rx_csum,
-       .get_tx_csum            = ethtool_op_get_tx_csum,
-       .set_tx_csum            = ethtool_op_set_tx_ipv6_csum,
-       .get_sg                 = ethtool_op_get_sg,
-       .set_sg                 = ethtool_op_set_sg,
-       .get_tso                = ethtool_op_get_tso,
-       .set_tso                = vxge_ethtool_op_set_tso,
        .get_strings            = vxge_ethtool_get_strings,
        .set_phys_id            = vxge_ethtool_idnic,
        .get_sset_count         = vxge_ethtool_get_sset_count,
        .get_ethtool_stats      = vxge_get_ethtool_stats,
-       .set_flags              = vxge_set_flags,
        .flash_device           = vxge_fw_flash,
 };