aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/pcmcia/axnet_cs.c
diff options
context:
space:
mode:
authorBen Hutchings <bhutchings@solarflare.com>2010-08-17 05:31:15 -0400
committerDavid S. Miller <davem@davemloft.net>2010-08-17 05:31:15 -0400
commit01414802054c382072b6cb9a1bdc6e243c74b2d5 (patch)
treef09b05eb9fff16a69d83ec28653992d1bae8d74c /drivers/net/pcmcia/axnet_cs.c
parentbb8a10bbd10a45db0eb45bac520489bdbc0917ef (diff)
ethtool: Provide a default implementation of ethtool_ops::get_drvinfo
The driver name and bus address for a net_device can normally be found through the driver model now. Instead of requiring drivers to provide this information redundantly through the ethtool_ops::get_drvinfo operation, use the driver model to do so if the driver does not define the operation. Since ETHTOOL_GDRVINFO no longer requires the driver to implement any operations, do not require net_device::ethtool_ops to be set either. Remove implementations of get_drvinfo and ethtool_ops that provide only this information. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/pcmcia/axnet_cs.c')
-rw-r--r--drivers/net/pcmcia/axnet_cs.c13
1 files changed, 0 insertions, 13 deletions
diff --git a/drivers/net/pcmcia/axnet_cs.c b/drivers/net/pcmcia/axnet_cs.c
index 5f05ffb240cc..a6e37b29e3bf 100644
--- a/drivers/net/pcmcia/axnet_cs.c
+++ b/drivers/net/pcmcia/axnet_cs.c
@@ -32,7 +32,6 @@
32#include <linux/timer.h> 32#include <linux/timer.h>
33#include <linux/delay.h> 33#include <linux/delay.h>
34#include <linux/spinlock.h> 34#include <linux/spinlock.h>
35#include <linux/ethtool.h>
36#include <linux/netdevice.h> 35#include <linux/netdevice.h>
37#include <linux/etherdevice.h> 36#include <linux/etherdevice.h>
38#include <linux/crc32.h> 37#include <linux/crc32.h>
@@ -86,7 +85,6 @@ static netdev_tx_t axnet_start_xmit(struct sk_buff *skb,
86static struct net_device_stats *get_stats(struct net_device *dev); 85static struct net_device_stats *get_stats(struct net_device *dev);
87static void set_multicast_list(struct net_device *dev); 86static void set_multicast_list(struct net_device *dev);
88static void axnet_tx_timeout(struct net_device *dev); 87static void axnet_tx_timeout(struct net_device *dev);
89static const struct ethtool_ops netdev_ethtool_ops;
90static irqreturn_t ei_irq_wrapper(int irq, void *dev_id); 88static irqreturn_t ei_irq_wrapper(int irq, void *dev_id);
91static void ei_watchdog(u_long arg); 89static void ei_watchdog(u_long arg);
92static void axnet_reset_8390(struct net_device *dev); 90static void axnet_reset_8390(struct net_device *dev);
@@ -171,7 +169,6 @@ static int axnet_probe(struct pcmcia_device *link)
171 169
172 dev->netdev_ops = &axnet_netdev_ops; 170 dev->netdev_ops = &axnet_netdev_ops;
173 171
174 SET_ETHTOOL_OPS(dev, &netdev_ethtool_ops);
175 dev->watchdog_timeo = TX_TIMEOUT; 172 dev->watchdog_timeo = TX_TIMEOUT;
176 173
177 return axnet_config(link); 174 return axnet_config(link);
@@ -658,16 +655,6 @@ reschedule:
658 add_timer(&info->watchdog); 655 add_timer(&info->watchdog);
659} 656}
660 657
661static void netdev_get_drvinfo(struct net_device *dev,
662 struct ethtool_drvinfo *info)
663{
664 strcpy(info->driver, "axnet_cs");
665}
666
667static const struct ethtool_ops netdev_ethtool_ops = {
668 .get_drvinfo = netdev_get_drvinfo,
669};
670
671/*====================================================================*/ 658/*====================================================================*/
672 659
673static int axnet_ioctl(struct net_device *dev, struct ifreq *rq, int cmd) 660static int axnet_ioctl(struct net_device *dev, struct ifreq *rq, int cmd)