diff options
author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-10-11 22:40:14 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-10-11 22:40:14 -0400 |
commit | 038a5008b2f395c85e6e71d6ddf3c684e7c405b0 (patch) | |
tree | 4735eab577e97e5a22c3141e3f60071c8065585e /drivers/net/ucc_geth_ethtool.c | |
parent | dd6d1844af33acb4edd0a40b1770d091a22c94be (diff) | |
parent | 266918303226cceac7eca38ced30f15f277bd89c (diff) |
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6
* 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6: (867 commits)
[SKY2]: status polling loop (post merge)
[NET]: Fix NAPI completion handling in some drivers.
[TCP]: Limit processing lost_retrans loop to work-to-do cases
[TCP]: Fix lost_retrans loop vs fastpath problems
[TCP]: No need to re-count fackets_out/sacked_out at RTO
[TCP]: Extract tcp_match_queue_to_sack from sacktag code
[TCP]: Kill almost unused variable pcount from sacktag
[TCP]: Fix mark_head_lost to ignore R-bit when trying to mark L
[TCP]: Add bytes_acked (ABC) clearing to FRTO too
[IPv6]: Update setsockopt(IPV6_MULTICAST_IF) to support RFC 3493, try2
[NETFILTER]: x_tables: add missing ip6t_modulename aliases
[NETFILTER]: nf_conntrack_tcp: fix connection reopening
[QETH]: fix qeth_main.c
[NETLINK]: fib_frontend build fixes
[IPv6]: Export userland ND options through netlink (RDNSS support)
[9P]: build fix with !CONFIG_SYSCTL
[NET]: Fix dev_put() and dev_hold() comments
[NET]: make netlink user -> kernel interface synchronious
[NET]: unify netlink kernel socket recognition
[NET]: cleanup 3rd argument in netlink_sendskb
...
Fix up conflicts manually in Documentation/feature-removal-schedule.txt
and my new least favourite crap, the "mod_devicetable" support in the
files include/linux/mod_devicetable.h and scripts/mod/file2alias.c.
(The latter files seem to be explicitly _designed_ to get conflicts when
different subsystems work with them - that have an absolutely horrid
lack of subsystem separation!)
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/net/ucc_geth_ethtool.c')
-rw-r--r-- | drivers/net/ucc_geth_ethtool.c | 28 |
1 files changed, 15 insertions, 13 deletions
diff --git a/drivers/net/ucc_geth_ethtool.c b/drivers/net/ucc_geth_ethtool.c index 64bef7c12365..9a9622c13e2b 100644 --- a/drivers/net/ucc_geth_ethtool.c +++ b/drivers/net/ucc_geth_ethtool.c | |||
@@ -276,20 +276,26 @@ uec_set_ringparam(struct net_device *netdev, | |||
276 | return ret; | 276 | return ret; |
277 | } | 277 | } |
278 | 278 | ||
279 | static int uec_get_stats_count(struct net_device *netdev) | 279 | static int uec_get_sset_count(struct net_device *netdev, int sset) |
280 | { | 280 | { |
281 | struct ucc_geth_private *ugeth = netdev_priv(netdev); | 281 | struct ucc_geth_private *ugeth = netdev_priv(netdev); |
282 | u32 stats_mode = ugeth->ug_info->statisticsMode; | 282 | u32 stats_mode = ugeth->ug_info->statisticsMode; |
283 | int len = 0; | 283 | int len = 0; |
284 | 284 | ||
285 | if (stats_mode & UCC_GETH_STATISTICS_GATHERING_MODE_HARDWARE) | 285 | switch (sset) { |
286 | len += UEC_HW_STATS_LEN; | 286 | case ETH_SS_STATS: |
287 | if (stats_mode & UCC_GETH_STATISTICS_GATHERING_MODE_FIRMWARE_TX) | 287 | if (stats_mode & UCC_GETH_STATISTICS_GATHERING_MODE_HARDWARE) |
288 | len += UEC_TX_FW_STATS_LEN; | 288 | len += UEC_HW_STATS_LEN; |
289 | if (stats_mode & UCC_GETH_STATISTICS_GATHERING_MODE_FIRMWARE_RX) | 289 | if (stats_mode & UCC_GETH_STATISTICS_GATHERING_MODE_FIRMWARE_TX) |
290 | len += UEC_RX_FW_STATS_LEN; | 290 | len += UEC_TX_FW_STATS_LEN; |
291 | if (stats_mode & UCC_GETH_STATISTICS_GATHERING_MODE_FIRMWARE_RX) | ||
292 | len += UEC_RX_FW_STATS_LEN; | ||
293 | |||
294 | return len; | ||
291 | 295 | ||
292 | return len; | 296 | default: |
297 | return -EOPNOTSUPP; | ||
298 | } | ||
293 | } | 299 | } |
294 | 300 | ||
295 | static void uec_get_strings(struct net_device *netdev, u32 stringset, u8 *buf) | 301 | static void uec_get_strings(struct net_device *netdev, u32 stringset, u8 *buf) |
@@ -353,8 +359,6 @@ uec_get_drvinfo(struct net_device *netdev, | |||
353 | strncpy(drvinfo->version, DRV_VERSION, 32); | 359 | strncpy(drvinfo->version, DRV_VERSION, 32); |
354 | strncpy(drvinfo->fw_version, "N/A", 32); | 360 | strncpy(drvinfo->fw_version, "N/A", 32); |
355 | strncpy(drvinfo->bus_info, "QUICC ENGINE", 32); | 361 | strncpy(drvinfo->bus_info, "QUICC ENGINE", 32); |
356 | drvinfo->n_stats = uec_get_stats_count(netdev); | ||
357 | drvinfo->testinfo_len = 0; | ||
358 | drvinfo->eedump_len = 0; | 362 | drvinfo->eedump_len = 0; |
359 | drvinfo->regdump_len = uec_get_regs_len(netdev); | 363 | drvinfo->regdump_len = uec_get_regs_len(netdev); |
360 | } | 364 | } |
@@ -373,10 +377,8 @@ static const struct ethtool_ops uec_ethtool_ops = { | |||
373 | .set_ringparam = uec_set_ringparam, | 377 | .set_ringparam = uec_set_ringparam, |
374 | .get_pauseparam = uec_get_pauseparam, | 378 | .get_pauseparam = uec_get_pauseparam, |
375 | .set_pauseparam = uec_set_pauseparam, | 379 | .set_pauseparam = uec_set_pauseparam, |
376 | .get_sg = ethtool_op_get_sg, | ||
377 | .set_sg = ethtool_op_set_sg, | 380 | .set_sg = ethtool_op_set_sg, |
378 | .get_tso = ethtool_op_get_tso, | 381 | .get_sset_count = uec_get_sset_count, |
379 | .get_stats_count = uec_get_stats_count, | ||
380 | .get_strings = uec_get_strings, | 382 | .get_strings = uec_get_strings, |
381 | .get_ethtool_stats = uec_get_ethtool_stats, | 383 | .get_ethtool_stats = uec_get_ethtool_stats, |
382 | }; | 384 | }; |