summaryrefslogtreecommitdiff
path: root/drivers/net/mlx5/mlx5_stats.c
diff options
context:
space:
mode:
authorShahaf Shuler <shahafs@mellanox.com>2018-10-07 15:55:25 +0300
committerFerruh Yigit <ferruh.yigit@intel.com>2018-10-11 18:56:02 +0200
commitd469f6a5eb47258bd0911bc75e14c312b83d0a41 (patch)
treefc8efc77d9ac3098ea093bc1d579bdf09ad7022f /drivers/net/mlx5/mlx5_stats.c
parent1a611fdaf6ec3d860d7b0f39cdd8b754ef51ebc3 (diff)
downloaddpdk-d469f6a5eb47258bd0911bc75e14c312b83d0a41.zip
dpdk-d469f6a5eb47258bd0911bc75e14c312b83d0a41.tar.gz
dpdk-d469f6a5eb47258bd0911bc75e14c312b83d0a41.tar.xz
net/mlx5: add representor specific statistics
Representor ports has a different set of extended statistics (as those are logical ports which cannot count all that the PF can). Cc: stable@dpdk.org Signed-off-by: Shahaf Shuler <shahafs@mellanox.com>
Diffstat (limited to 'drivers/net/mlx5/mlx5_stats.c')
-rw-r--r--drivers/net/mlx5/mlx5_stats.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/drivers/net/mlx5/mlx5_stats.c b/drivers/net/mlx5/mlx5_stats.c
index 9b89b9b..f24c736 100644
--- a/drivers/net/mlx5/mlx5_stats.c
+++ b/drivers/net/mlx5/mlx5_stats.c
@@ -107,6 +107,23 @@ static const struct mlx5_counter_ctrl mlx5_counters_init[] = {
.dpdk_name = "rx_bytes_phy",
.ctr_name = "rx_bytes_phy",
},
+ /* Representor only */
+ {
+ .dpdk_name = "rx_packets",
+ .ctr_name = "vport_rx_packets",
+ },
+ {
+ .dpdk_name = "rx_bytes",
+ .ctr_name = "vport_rx_bytes",
+ },
+ {
+ .dpdk_name = "tx_packets",
+ .ctr_name = "vport_tx_packets",
+ },
+ {
+ .dpdk_name = "tx_bytes",
+ .ctr_name = "vport_tx_bytes",
+ },
};
static const unsigned int xstats_n = RTE_DIM(mlx5_counters_init);