Gitweb: http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=73eac0640ebfb30fee99e06ee029444af0d7ae8d Commit: 73eac0640ebfb30fee99e06ee029444af0d7ae8d Parent: 5b825ed22b02691e39774e8b2a077d1807969ec7 Author: Al Viro <[EMAIL PROTECTED]> AuthorDate: Fri Dec 21 06:20:23 2007 +0000 Committer: Jeff Garzik <[EMAIL PROTECTED]> CommitDate: Sat Dec 22 22:53:05 2007 -0500
typhoon: endianness bug in tx/rx byte counters txBytes and rxBytesGood are both 64bit; using le32_to_cpu() won't work on big-endian for obvious reasons. Signed-off-by: Al Viro <[EMAIL PROTECTED]> Signed-off-by: Jeff Garzik <[EMAIL PROTECTED]> --- drivers/net/typhoon.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/typhoon.c b/drivers/net/typhoon.c index 94ac586..67f31a2 100644 --- a/drivers/net/typhoon.c +++ b/drivers/net/typhoon.c @@ -977,12 +977,12 @@ typhoon_do_get_stats(struct typhoon *tp) * ethtool_ops->get_{strings,stats}() */ stats->tx_packets = le32_to_cpu(s->txPackets); - stats->tx_bytes = le32_to_cpu(s->txBytes); + stats->tx_bytes = le64_to_cpu(s->txBytes); stats->tx_errors = le32_to_cpu(s->txCarrierLost); stats->tx_carrier_errors = le32_to_cpu(s->txCarrierLost); stats->collisions = le32_to_cpu(s->txMultipleCollisions); stats->rx_packets = le32_to_cpu(s->rxPacketsGood); - stats->rx_bytes = le32_to_cpu(s->rxBytesGood); + stats->rx_bytes = le64_to_cpu(s->rxBytesGood); stats->rx_fifo_errors = le32_to_cpu(s->rxFifoOverruns); stats->rx_errors = le32_to_cpu(s->rxFifoOverruns) + le32_to_cpu(s->BadSSD) + le32_to_cpu(s->rxCrcErrors); - To unsubscribe from this list: send the line "unsubscribe git-commits-head" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html