diff options
author | Igor Russkikh <igor.russkikh@aquantia.com> | 2017-12-14 12:34:42 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-12-15 12:46:41 -0500 |
commit | be08d839d9ef1c9b0e4ed809ec852ff100f9970d (patch) | |
tree | ab61e7bccdf588746c705c85e79119c6d4944de9 /drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_utils.h | |
parent | net: aquantia: Fix hardware DMA stream overload on large MRRS (diff) | |
download | linux-dev-be08d839d9ef1c9b0e4ed809ec852ff100f9970d.tar.xz linux-dev-be08d839d9ef1c9b0e4ed809ec852ff100f9970d.zip |
net: aquantia: Extend stat counters to 64bit values
Device hardware provides only 32bit counters. Using these directly
causes byte counters to overflow soon. A separate nic level structure
with 64 bit counters is now used to collect incrementally all the stats
and report these counters to ethtool stats and ndev stats.
Signed-off-by: Igor Russkikh <igor.russkikh@aquantia.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to '')
-rw-r--r-- | drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_utils.h | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_utils.h b/drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_utils.h index c99cc690e425..21aeca6908d3 100644 --- a/drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_utils.h +++ b/drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_utils.h @@ -129,7 +129,7 @@ struct __packed hw_aq_atl_utils_mbox { struct __packed hw_atl_s { struct aq_hw_s base; struct hw_atl_stats_s last_stats; - struct hw_atl_stats_s curr_stats; + struct aq_stats_s curr_stats; u64 speed; unsigned int chip_features; u32 fw_ver_actual; @@ -207,8 +207,6 @@ int hw_atl_utils_get_fw_version(struct aq_hw_s *self, u32 *fw_version); int hw_atl_utils_update_stats(struct aq_hw_s *self); -int hw_atl_utils_get_hw_stats(struct aq_hw_s *self, - u64 *data, - unsigned int *p_count); +struct aq_stats_s *hw_atl_utils_get_hw_stats(struct aq_hw_s *self); #endif /* HW_ATL_UTILS_H */ |