aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/mellanox/mlx5/core/en_stats.h
diff options
context:
space:
mode:
authorKamal Heib <kamalh@mellanox.com>2017-08-23 14:51:27 +0300
committerSaeed Mahameed <saeedm@mellanox.com>2017-10-31 14:20:47 -0700
commitfc8e64a3118ee13bc4cafa6a31ea74daf2d644d9 (patch)
tree38017dfa47eb1335328d1ad346aca875f3ca30f3 /drivers/net/ethernet/mellanox/mlx5/core/en_stats.h
parentnet/mlx5e: Switch IEEE 802.3 counters to use stats group API (diff)
downloadlinux-dev-fc8e64a3118ee13bc4cafa6a31ea74daf2d644d9.tar.xz
linux-dev-fc8e64a3118ee13bc4cafa6a31ea74daf2d644d9.zip
net/mlx5e: Switch RFC 2863 counters to use stats group API
Switch the RFC 2863 counters to use the new stats group API. Signed-off-by: Kamal Heib <kamalh@mellanox.com> Reviewed-by: Gal Pressman <galp@mellanox.com> Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
Diffstat (limited to '')
-rw-r--r--drivers/net/ethernet/mellanox/mlx5/core/en_stats.h13
1 files changed, 1 insertions, 12 deletions
diff --git a/drivers/net/ethernet/mellanox/mlx5/core/en_stats.h b/drivers/net/ethernet/mellanox/mlx5/core/en_stats.h
index 5a489aa8fef3..58dc22e5ac53 100644
--- a/drivers/net/ethernet/mellanox/mlx5/core/en_stats.h
+++ b/drivers/net/ethernet/mellanox/mlx5/core/en_stats.h
@@ -105,9 +105,6 @@ struct mlx5e_vport_stats {
#define PPORT_802_3_GET(pstats, c) \
MLX5_GET64(ppcnt_reg, pstats->IEEE_802_3_counters, \
counter_set.eth_802_3_cntrs_grp_data_layout.c##_high)
-#define PPORT_2863_OFF(c) \
- MLX5_BYTE_OFF(ppcnt_reg, \
- counter_set.eth_2863_cntrs_grp_data_layout.c##_high)
#define PPORT_2863_GET(pstats, c) \
MLX5_GET64(ppcnt_reg, pstats->RFC_2863_counters, \
counter_set.eth_2863_cntrs_grp_data_layout.c##_high)
@@ -147,12 +144,6 @@ struct mlx5e_pport_stats {
__be64 eth_ext_counters[MLX5_ST_SZ_QW(ppcnt_reg)];
};
-static const struct counter_desc pport_2863_stats_desc[] = {
- { "rx_discards_phy", PPORT_2863_OFF(if_in_discards) },
- { "tx_discards_phy", PPORT_2863_OFF(if_out_discards) },
- { "tx_errors_phy", PPORT_2863_OFF(if_out_errors) },
-};
-
static const struct counter_desc pport_2819_stats_desc[] = {
{ "rx_undersize_pkts_phy", PPORT_2819_OFF(ether_stats_undersize_pkts) },
{ "rx_fragments_phy", PPORT_2819_OFF(ether_stats_fragments) },
@@ -312,7 +303,6 @@ static const struct counter_desc sq_stats_desc[] = {
{ MLX5E_DECLARE_TX_STAT(struct mlx5e_sq_stats, xmit_more) },
};
-#define NUM_PPORT_2863_COUNTERS ARRAY_SIZE(pport_2863_stats_desc)
#define NUM_PPORT_2819_COUNTERS ARRAY_SIZE(pport_2819_stats_desc)
#define NUM_PPORT_PHY_STATISTICAL_COUNTERS(priv) \
(ARRAY_SIZE(pport_phy_statistical_stats_desc) * \
@@ -333,8 +323,7 @@ static const struct counter_desc sq_stats_desc[] = {
#define NUM_PPORT_ETH_EXT_COUNTERS(priv) \
(ARRAY_SIZE(pport_eth_ext_stats_desc) * \
MLX5_CAP_PCAM_FEATURE((priv)->mdev, rx_buffer_fullness_counters))
-#define NUM_PPORT_COUNTERS(priv) (NUM_PPORT_2863_COUNTERS + \
- NUM_PPORT_2819_COUNTERS + \
+#define NUM_PPORT_COUNTERS(priv) (NUM_PPORT_2819_COUNTERS + \
NUM_PPORT_PHY_STATISTICAL_COUNTERS(priv) + \
NUM_PPORT_PER_PRIO_TRAFFIC_COUNTERS * \
NUM_PPORT_PRIO + \