From patchwork Thu Oct 24 12:46:42 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dekel Peled X-Patchwork-Id: 61899 X-Patchwork-Delegate: rasland@nvidia.com Return-Path: X-Original-To: patchwork@dpdk.org Delivered-To: patchwork@dpdk.org Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 898C71EA4D; Thu, 24 Oct 2019 14:49:37 +0200 (CEST) Received: from mellanox.co.il (mail-il-dmz.mellanox.com [193.47.165.129]) by dpdk.org (Postfix) with ESMTP id 281D51EA4A for ; Thu, 24 Oct 2019 14:49:36 +0200 (CEST) Received: from Internal Mail-Server by MTLPINE1 (envelope-from dekelp@mellanox.com) with ESMTPS (AES256-SHA encrypted); 24 Oct 2019 14:49:34 +0200 Received: from mtl-vdi-280.wap.labs.mlnx. (mtl-vdi-280.wap.labs.mlnx [10.128.130.87]) by labmailer.mlnx (8.13.8/8.13.8) with ESMTP id x9OCnXk8005377; Thu, 24 Oct 2019 15:49:33 +0300 From: Dekel Peled To: matan@mellanox.com, viacheslavo@mellanox.com, shahafs@mellanox.com Cc: orika@mellanox.com, dev@dpdk.org, stable@dpdk.org Date: Thu, 24 Oct 2019 15:46:42 +0300 Message-Id: <8fd5a11fbe9cde80ac55b2cbec9d79e3fac56bf5.1571921204.git.dekelp@mellanox.com> X-Mailer: git-send-email 1.7.1 Subject: [dpdk-dev] [PATCH] net/mlx5: fix LRO dependency to include DV flow X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Rx queue for LRO is created using DevX. Flows created on this queue must use the DV flow engine. This patch adds check of dv_flow_en=1 when configuring LRO support on device spawn. Documentation is updated accordingly. Fixes: 175f1c21d033 ("net/mlx5: check conditions to enable LRO") Cc: stable@dpdk.org Signed-off-by: Dekel Peled Acked-by: Viacheslav Ovsiienko --- doc/guides/nics/mlx5.rst | 2 +- drivers/net/mlx5/mlx5.c | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/doc/guides/nics/mlx5.rst b/doc/guides/nics/mlx5.rst index 600cea7..45fa968 100644 --- a/doc/guides/nics/mlx5.rst +++ b/doc/guides/nics/mlx5.rst @@ -203,7 +203,7 @@ Limitations - LRO: - - Requires DevX to be enabled. + - Requires DevX and DV flow to be enabled. - KEEP_CRC offload cannot be supported with LRO. - The first mbuf length, without head-room, must be big enough to include the TCP header (122B). diff --git a/drivers/net/mlx5/mlx5.c b/drivers/net/mlx5/mlx5.c index b99c5a9..5977d06 100644 --- a/drivers/net/mlx5/mlx5.c +++ b/drivers/net/mlx5/mlx5.c @@ -2033,7 +2033,8 @@ struct mlx5_dev_spawn_data { if (priv->counter_fallback) DRV_LOG(INFO, "Use fall-back DV counter management\n"); /* Check for LRO support. */ - if (config.dest_tir && config.hca_attr.lro_cap) { + if (config.dest_tir && config.hca_attr.lro_cap && + config.dv_flow_en) { /* TBD check tunnel lro caps. */ config.lro.supported = config.hca_attr.lro_cap; DRV_LOG(DEBUG, "Device supports LRO");