DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] net/mlx5: revert DevX API preferred for Rx objects
@ 2020-05-20 12:37 Dekel Peled
  2020-05-21 16:28 ` Ferruh Yigit
  0 siblings, 1 reply; 2+ messages in thread
From: Dekel Peled @ 2020-05-20 12:37 UTC (permalink / raw)
  To: ferruh.yigit, thomas, matan, viacheslavo, rasland; +Cc: dev

Recent patch [1] exposed a minor performance issue.
In order to properly test it, this patch reverts commit [1].

[1] commit d237d22fbe62 ("net/mlx5: prefer DevX API to create Rx objects")

Signed-off-by: Dekel Peled <dekelp@mellanox.com>
Acked-by: Matan Azrad <matan@mellanox.com>
---
 drivers/net/mlx5/mlx5_trigger.c | 15 ++++++++++-----
 1 file changed, 10 insertions(+), 5 deletions(-)

diff --git a/drivers/net/mlx5/mlx5_trigger.c b/drivers/net/mlx5/mlx5_trigger.c
index 8d53648..8106598 100644
--- a/drivers/net/mlx5/mlx5_trigger.c
+++ b/drivers/net/mlx5/mlx5_trigger.c
@@ -107,11 +107,16 @@
 	struct mlx5_priv *priv = dev->data->dev_private;
 	unsigned int i;
 	int ret = 0;
-	enum mlx5_rxq_obj_type obj_type =
-			priv->config.dv_flow_en && priv->config.devx &&
-			priv->config.dest_tir ?
-			MLX5_RXQ_OBJ_TYPE_DEVX_RQ : MLX5_RXQ_OBJ_TYPE_IBV;
-
+	enum mlx5_rxq_obj_type obj_type = MLX5_RXQ_OBJ_TYPE_IBV;
+	struct mlx5_rxq_data *rxq = NULL;
+
+	for (i = 0; i < priv->rxqs_n; ++i) {
+		rxq = (*priv->rxqs)[i];
+		if (rxq && rxq->lro) {
+			obj_type =  MLX5_RXQ_OBJ_TYPE_DEVX_RQ;
+			break;
+		}
+	}
 	/* Allocate/reuse/resize mempool for Multi-Packet RQ. */
 	if (mlx5_mprq_alloc_mp(dev)) {
 		/* Should not release Rx queues but return immediately. */
-- 
1.8.3.1


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

* Re: [dpdk-dev] [PATCH] net/mlx5: revert DevX API preferred for Rx objects
  2020-05-20 12:37 [dpdk-dev] [PATCH] net/mlx5: revert DevX API preferred for Rx objects Dekel Peled
@ 2020-05-21 16:28 ` Ferruh Yigit
  0 siblings, 0 replies; 2+ messages in thread
From: Ferruh Yigit @ 2020-05-21 16:28 UTC (permalink / raw)
  To: Dekel Peled, thomas, matan, viacheslavo, rasland; +Cc: dev

On 5/20/2020 1:37 PM, Dekel Peled wrote:
> Recent patch [1] exposed a minor performance issue.
> In order to properly test it, this patch reverts commit [1].
> 
> [1] commit d237d22fbe62 ("net/mlx5: prefer DevX API to create Rx objects")
> 
> Signed-off-by: Dekel Peled <dekelp@mellanox.com>
> Acked-by: Matan Azrad <matan@mellanox.com>

Applied to dpdk-next-net/master, thanks.



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

end of thread, other threads:[~2020-05-21 16:28 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-20 12:37 [dpdk-dev] [PATCH] net/mlx5: revert DevX API preferred for Rx objects Dekel Peled
2020-05-21 16:28 ` Ferruh Yigit

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).