diff options
Diffstat (limited to 'drivers/net/tg3.c')
-rw-r--r-- | drivers/net/tg3.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/net/tg3.c b/drivers/net/tg3.c index c26011eaa2be..ada1d0d11045 100644 --- a/drivers/net/tg3.c +++ b/drivers/net/tg3.c | |||
@@ -8466,6 +8466,11 @@ static inline unsigned long get_stat64(tg3_stat64_t *val) | |||
8466 | return ret; | 8466 | return ret; |
8467 | } | 8467 | } |
8468 | 8468 | ||
8469 | static inline u64 get_estat64(tg3_stat64_t *val) | ||
8470 | { | ||
8471 | return ((u64)val->high << 32) | ((u64)val->low); | ||
8472 | } | ||
8473 | |||
8469 | static unsigned long calc_crc_errors(struct tg3 *tp) | 8474 | static unsigned long calc_crc_errors(struct tg3 *tp) |
8470 | { | 8475 | { |
8471 | struct tg3_hw_stats *hw_stats = tp->hw_stats; | 8476 | struct tg3_hw_stats *hw_stats = tp->hw_stats; |
@@ -8494,7 +8499,7 @@ static unsigned long calc_crc_errors(struct tg3 *tp) | |||
8494 | 8499 | ||
8495 | #define ESTAT_ADD(member) \ | 8500 | #define ESTAT_ADD(member) \ |
8496 | estats->member = old_estats->member + \ | 8501 | estats->member = old_estats->member + \ |
8497 | get_stat64(&hw_stats->member) | 8502 | get_estat64(&hw_stats->member) |
8498 | 8503 | ||
8499 | static struct tg3_ethtool_stats *tg3_get_estats(struct tg3 *tp) | 8504 | static struct tg3_ethtool_stats *tg3_get_estats(struct tg3 *tp) |
8500 | { | 8505 | { |