From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id C7F7DA0577; Mon, 13 Apr 2020 15:16:02 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 8E2F5FFA; Mon, 13 Apr 2020 15:16:01 +0200 (CEST) Received: from integrity.niometrics.com (integrity.niometrics.com [42.61.70.122]) by dpdk.org (Postfix) with ESMTP id 2459CF12; Mon, 13 Apr 2020 15:16:00 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by integrity.niometrics.com (Postfix) with ESMTP id E509E409CBA9; Mon, 13 Apr 2020 21:15:57 +0800 (+08) DKIM-Filter: OpenDKIM Filter v2.11.0 integrity.niometrics.com E509E409CBA9 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=niometrics.com; s=default; t=1586783758; bh=X3DeivjiNo72gtzQi3NArazxlCTvf5ohltqaJzXZ3Hg=; h=From:To:Cc:Subject:Date:From; b=CgeAihwdychcyKsLgiO6sBCjg4yz5oGu2fhCigXsTFkZq20/vvXMJz5Havi4k55qw dEDEe5Y75ga9rjclJ2Xx9BcEOpuFQ39fsMzF0wDn0k5Ch0mc3Xq4gtgXYIlE6ekJJs qp2h4qf4bAOc+Hwpyq0XNyGIZHmvsgDWhF/UGJ3I= X-Virus-Scanned: amavisd-new at niometrics.com Received: from integrity.niometrics.com ([127.0.0.1]) by localhost (integrity.niometrics.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id xabe18OgIi9j; Mon, 13 Apr 2020 21:15:57 +0800 (+08) Received: from monkey-island.localdomain (unknown [10.15.0.132]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by integrity.niometrics.com (Postfix) with ESMTPSA id E20A4409CBA8; Mon, 13 Apr 2020 21:15:56 +0800 (+08) DMARC-Filter: OpenDMARC Filter v1.3.2 integrity.niometrics.com E20A4409CBA8 DKIM-Filter: OpenDKIM Filter v2.11.0 integrity.niometrics.com E20A4409CBA8 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=niometrics.com; s=default; t=1586783757; bh=X3DeivjiNo72gtzQi3NArazxlCTvf5ohltqaJzXZ3Hg=; h=From:To:Cc:Subject:Date:From; b=VaMrwyZSQX0+OifvI5nQfmPOKV1b7oBh2EEgK78ylfBYUHWecJLo/p9RwuNVykzKT H+kH+m5FkpMbVfv07gDH3dsI5w7iZCW0I3g3WnrJdpcpgOK5IgvlF6qsiuInTOkasq 7v4xt5KFyEKZqPkdpKBSz9M9bVyOFOidNY8/yHhQ= From: Mohsin Shaikh To: dev@dpdk.org Cc: stable@dpdk.org, akozyrev@mellanox.com, Mohsin Shaikh Date: Mon, 13 Apr 2020 21:15:44 +0800 Message-Id: <1586783744-8962-1-git-send-email-mohsinshaikh@niometrics.com> X-Mailer: git-send-email 1.8.3.1 X-Spam-Status: No, score=-1.1 required=3.5 tests=ALL_TRUSTED, AWL, DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU autolearn=disabled version=3.4.0 X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on integrity.niometrics.com Subject: [dpdk-dev] [PATCH] net/mlx5: Allow configuring mlx5 port for TX only 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" Configuring mlx5 port with 0 rx rings and 1 or more tx rings causes following error in dev_start: net_mlx5: port 1 cannot allocate RSS queue list (0) net_mlx5: port 1 reta config failed: Cannot allocate memory Skip mlx5_dev_configure_rss_reta() when there are no rx rings. Cc: stable@dpdk.org Signed-off-by: Mohsin Shaikh --- drivers/net/mlx5/mlx5_ethdev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/mlx5/mlx5_ethdev.c b/drivers/net/mlx5/mlx5_ethdev.c index d7d3bc7..1d443c1 100644 --- a/drivers/net/mlx5/mlx5_ethdev.c +++ b/drivers/net/mlx5/mlx5_ethdev.c @@ -463,7 +463,7 @@ struct ethtool_link_settings { unsigned int *rss_queue_arr = NULL; unsigned int rss_queue_n = 0; - if (priv->skip_default_rss_reta) + if (priv->skip_default_rss_reta || !rxqs_n) return ret; rss_queue_arr = rte_malloc("", rxqs_n * sizeof(unsigned int), 0); if (!rss_queue_arr) { -- 1.8.3.1