aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/tg3.c
diff options
context:
space:
mode:
authorJeff Garzik <jeff@garzik.org>2007-10-03 21:07:32 -0400
committerDavid S. Miller <davem@sunset.davemloft.net>2007-10-10 19:51:45 -0400
commitb9f2c0440d806e01968c3ed4def930a43be248ad (patch)
treeb8e4668b0a4eab842fc33402e92b15f6c63cbc18 /drivers/net/tg3.c
parent753f492093da7a40141bfe083073400f518f4c68 (diff)
[netdrvr] Stop using legacy hooks ->self_test_count, ->get_stats_count
These have been superceded by the new ->get_sset_count() hook. Signed-off-by: Jeff Garzik <jeff@garzik.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/tg3.c')
-rw-r--r--drivers/net/tg3.c19
1 files changed, 10 insertions, 9 deletions
diff --git a/drivers/net/tg3.c b/drivers/net/tg3.c
index 1b860e0817f6..d4ac6e9ef6db 100644
--- a/drivers/net/tg3.c
+++ b/drivers/net/tg3.c
@@ -8347,14 +8347,16 @@ static int tg3_set_tx_csum(struct net_device *dev, u32 data)
8347 return 0; 8347 return 0;
8348} 8348}
8349 8349
8350static int tg3_get_stats_count (struct net_device *dev) 8350static int tg3_get_sset_count (struct net_device *dev, int sset)
8351{ 8351{
8352 return TG3_NUM_STATS; 8352 switch (sset) {
8353} 8353 case ETH_SS_TEST:
8354 8354 return TG3_NUM_TEST;
8355static int tg3_get_test_count (struct net_device *dev) 8355 case ETH_SS_STATS:
8356{ 8356 return TG3_NUM_STATS;
8357 return TG3_NUM_TEST; 8357 default:
8358 return -EOPNOTSUPP;
8359 }
8358} 8360}
8359 8361
8360static void tg3_get_strings (struct net_device *dev, u32 stringset, u8 *buf) 8362static void tg3_get_strings (struct net_device *dev, u32 stringset, u8 *buf)
@@ -9281,14 +9283,13 @@ static const struct ethtool_ops tg3_ethtool_ops = {
9281 .set_tx_csum = tg3_set_tx_csum, 9283 .set_tx_csum = tg3_set_tx_csum,
9282 .set_sg = ethtool_op_set_sg, 9284 .set_sg = ethtool_op_set_sg,
9283 .set_tso = tg3_set_tso, 9285 .set_tso = tg3_set_tso,
9284 .self_test_count = tg3_get_test_count,
9285 .self_test = tg3_self_test, 9286 .self_test = tg3_self_test,
9286 .get_strings = tg3_get_strings, 9287 .get_strings = tg3_get_strings,
9287 .phys_id = tg3_phys_id, 9288 .phys_id = tg3_phys_id,
9288 .get_stats_count = tg3_get_stats_count,
9289 .get_ethtool_stats = tg3_get_ethtool_stats, 9289 .get_ethtool_stats = tg3_get_ethtool_stats,
9290 .get_coalesce = tg3_get_coalesce, 9290 .get_coalesce = tg3_get_coalesce,
9291 .set_coalesce = tg3_set_coalesce, 9291 .set_coalesce = tg3_set_coalesce,
9292 .get_sset_count = tg3_get_sset_count,
9292}; 9293};
9293 9294
9294static void __devinit tg3_get_eeprom_size(struct tg3 *tp) 9295static void __devinit tg3_get_eeprom_size(struct tg3 *tp)