DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH 1/2] doc: update mlx5 statistics query
@ 2017-11-29 11:29 Shahaf Shuler
  2017-11-29 11:29 ` [dpdk-dev] [PATCH 2/2] net/mlx5: add physical port counters Shahaf Shuler
  2017-11-29 12:14 ` [dpdk-dev] [PATCH 1/2] doc: update mlx5 statistics query Nelio Laranjeiro
  0 siblings, 2 replies; 4+ messages in thread
From: Shahaf Shuler @ 2017-11-29 11:29 UTC (permalink / raw)
  To: nelio.laranjeiro, adrien.mazarguil, yskoh; +Cc: dev

Update the guide with more details on the different statistics query
possible with MLX5 PMD.

Signed-off-by: Shahaf Shuler <shahafs@mellanox.com>
---
 doc/guides/nics/mlx5.rst | 13 +++++++++++--
 1 file changed, 11 insertions(+), 2 deletions(-)

diff --git a/doc/guides/nics/mlx5.rst b/doc/guides/nics/mlx5.rst
index f9558da89..154db64d7 100644
--- a/doc/guides/nics/mlx5.rst
+++ b/doc/guides/nics/mlx5.rst
@@ -105,8 +105,6 @@ Limitations
 -----------
 
 - Inner RSS for VXLAN frames is not supported yet.
-- Port statistics through software counters only. Flow statistics are
-  supported by hardware counters.
 - Hardware checksum RX offloads for VXLAN inner header are not supported yet.
 - Forked secondary process not supported.
 - Flow pattern without any specific vlan will match for vlan packets as well:
@@ -134,6 +132,17 @@ Limitations
   to 0 are not supported.
 - VXLAN TSO and checksum offloads are not supported on VM.
 
+Statistics
+----------
+
+MLX5 supports various of methods to report statistics:
+
+Port statistics can be queried using ``rte_eth_stats_get()``. The port statistics are through SW only and counts the number of packets received or sent successfully by the PMD.
+
+Extended statistics can be queried using ``rte_eth_xstats_get()``. The extended statistics expose a wider set of counters counted by the device. The extended port statistics counts the number of packets received or sent successfully by the port. As Mellanox NICs are using the :ref:`Bifurcated Linux Driver <linux_gsg_linux_drivers>` those counters counts also packet received or sent by the Linux kernel. The counters with ``_phy`` suffix counts the total events on the physical port, therefore not valid for VF.
+
+Finally per-flow statistics can by queried using ``rte_flow_query`` when attaching a count action for specific flow. The flow counter counts the number of packets received successfully by the port and match the specific flow.
+
 Configuration
 -------------
 
-- 
2.12.0

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [dpdk-dev] [PATCH 2/2] net/mlx5: add physical port counters
  2017-11-29 11:29 [dpdk-dev] [PATCH 1/2] doc: update mlx5 statistics query Shahaf Shuler
@ 2017-11-29 11:29 ` Shahaf Shuler
  2017-11-29 12:14 ` [dpdk-dev] [PATCH 1/2] doc: update mlx5 statistics query Nelio Laranjeiro
  1 sibling, 0 replies; 4+ messages in thread
From: Shahaf Shuler @ 2017-11-29 11:29 UTC (permalink / raw)
  To: nelio.laranjeiro, adrien.mazarguil, yskoh; +Cc: dev

Extend the PMD extended statistics with more counters on the physical
port.

Signed-off-by: Shahaf Shuler <shahafs@mellanox.com>
---
 drivers/net/mlx5/mlx5_stats.c | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/drivers/net/mlx5/mlx5_stats.c b/drivers/net/mlx5/mlx5_stats.c
index 5e225d374..ae55edaa4 100644
--- a/drivers/net/mlx5/mlx5_stats.c
+++ b/drivers/net/mlx5/mlx5_stats.c
@@ -122,6 +122,22 @@ static const struct mlx5_counter_ctrl mlx5_counters_init[] = {
 		.dpdk_name = "rx_out_of_buffer",
 		.ctr_name = "out_of_buffer",
 	},
+	{
+		.dpdk_name = "tx_packets_phy",
+		.ctr_name = "tx_packets_phy",
+	},
+	{
+		.dpdk_name = "rx_packets_phy",
+		.ctr_name = "rx_packets_phy",
+	},
+	{
+		.dpdk_name = "tx_bytes_phy",
+		.ctr_name = "tx_bytes_phy",
+	},
+	{
+		.dpdk_name = "rx_bytes_phy",
+		.ctr_name = "rx_bytes_phy",
+	},
 };
 
 static const unsigned int xstats_n = RTE_DIM(mlx5_counters_init);
-- 
2.12.0

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [dpdk-dev] [PATCH 1/2] doc: update mlx5 statistics query
  2017-11-29 11:29 [dpdk-dev] [PATCH 1/2] doc: update mlx5 statistics query Shahaf Shuler
  2017-11-29 11:29 ` [dpdk-dev] [PATCH 2/2] net/mlx5: add physical port counters Shahaf Shuler
@ 2017-11-29 12:14 ` Nelio Laranjeiro
  2017-11-29 13:34   ` Shahaf Shuler
  1 sibling, 1 reply; 4+ messages in thread
From: Nelio Laranjeiro @ 2017-11-29 12:14 UTC (permalink / raw)
  To: Shahaf Shuler; +Cc: adrien.mazarguil, yskoh, dev

On Wed, Nov 29, 2017 at 01:29:07PM +0200, Shahaf Shuler wrote:
> Update the guide with more details on the different statistics query
> possible with MLX5 PMD.
> 
> Signed-off-by: Shahaf Shuler <shahafs@mellanox.com>
> ---
>  doc/guides/nics/mlx5.rst | 13 +++++++++++--
>  1 file changed, 11 insertions(+), 2 deletions(-)
> 
> diff --git a/doc/guides/nics/mlx5.rst b/doc/guides/nics/mlx5.rst
> index f9558da89..154db64d7 100644
> --- a/doc/guides/nics/mlx5.rst
> +++ b/doc/guides/nics/mlx5.rst
> @@ -105,8 +105,6 @@ Limitations
>  -----------
>  
>  - Inner RSS for VXLAN frames is not supported yet.
> -- Port statistics through software counters only. Flow statistics are
> -  supported by hardware counters.
>  - Hardware checksum RX offloads for VXLAN inner header are not supported yet.
>  - Forked secondary process not supported.
>  - Flow pattern without any specific vlan will match for vlan packets as well:
> @@ -134,6 +132,17 @@ Limitations
>    to 0 are not supported.
>  - VXLAN TSO and checksum offloads are not supported on VM.
>  
> +Statistics
> +----------
> +
> +MLX5 supports various of methods to report statistics:
> +
> +Port statistics can be queried using ``rte_eth_stats_get()``. The port statistics are through SW only and counts the number of packets received or sent successfully by the PMD.
> +
> +Extended statistics can be queried using ``rte_eth_xstats_get()``. The extended statistics expose a wider set of counters counted by the device. The extended port statistics counts the number of packets received or sent successfully by the port. As Mellanox NICs are using the :ref:`Bifurcated Linux Driver <linux_gsg_linux_drivers>` those counters counts also packet received or sent by the Linux kernel. The counters with ``_phy`` suffix counts the total events on the physical port, therefore not valid for VF.
> +
> +Finally per-flow statistics can by queried using ``rte_flow_query`` when attaching a count action for specific flow. The flow counter counts the number of packets received successfully by the port and match the specific flow.
> +
>  Configuration
>  -------------
>  
> -- 
> 2.12.0
 
For the series,

Acked-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>

Thanks,

-- 
Nélio Laranjeiro
6WIND

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [dpdk-dev] [PATCH 1/2] doc: update mlx5 statistics query
  2017-11-29 12:14 ` [dpdk-dev] [PATCH 1/2] doc: update mlx5 statistics query Nelio Laranjeiro
@ 2017-11-29 13:34   ` Shahaf Shuler
  0 siblings, 0 replies; 4+ messages in thread
From: Shahaf Shuler @ 2017-11-29 13:34 UTC (permalink / raw)
  To: Nélio Laranjeiro; +Cc: Adrien Mazarguil, Yongseok Koh, dev

Wednesday, November 29, 2017 2:14 PM, Nelio Laranjeiro:
> On Wed, Nov 29, 2017 at 01:29:07PM +0200, Shahaf Shuler wrote:
> > Update the guide with more details on the different statistics query
> > possible with MLX5 PMD.
> >
> > Signed-off-by: Shahaf Shuler <shahafs@mellanox.com>
> > ---
> >  doc/guides/nics/mlx5.rst | 13 +++++++++++--
> >  1 file changed, 11 insertions(+), 2 deletions(-)
> >
> For the series,
> 
> Acked-by: Nelio Laranjeiro <nelio.laranjeiro@6wind.com>

Series applied to next-net-mlx5, thanks.

> 
> Thanks,
> 
> --
> Nélio Laranjeiro
> 6WIND

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2017-11-29 13:34 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-11-29 11:29 [dpdk-dev] [PATCH 1/2] doc: update mlx5 statistics query Shahaf Shuler
2017-11-29 11:29 ` [dpdk-dev] [PATCH 2/2] net/mlx5: add physical port counters Shahaf Shuler
2017-11-29 12:14 ` [dpdk-dev] [PATCH 1/2] doc: update mlx5 statistics query Nelio Laranjeiro
2017-11-29 13:34   ` Shahaf Shuler

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).