From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 64198A0543 for ; Tue, 21 Jun 2022 10:07:16 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 5EEDE40151; Tue, 21 Jun 2022 10:07:16 +0200 (CEST) Received: from NAM12-MW2-obe.outbound.protection.outlook.com (mail-mw2nam12on2075.outbound.protection.outlook.com [40.107.244.75]) by mails.dpdk.org (Postfix) with ESMTP id AE79B40151 for ; Tue, 21 Jun 2022 10:07:14 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=XLWNXBxDcKpvaH0q4m0dKACyAaqmkRD6Xj7UxR0thHzIhOuYItvHkyE5gtQ0F6ccvMlgWXor7/ZXvQz2ie1KK7W3mCLXnrzlRyJtk/1tfcIpl6PpUJy79oZ1FKf+jP6R0mVKViBeB1jwFm54jQuqyOR0/wODByEUm55CCv0gzF6p3Yph7HwpN2vLCOpcahRaqE9xD1VDMtv0SDn6I2nwjLXDVa84wxdK1A7afa+UmAOxTQDp+sgMMG46RxDq2q7AVqJlqpZ0mcmKvAhP2uv33txmLY4GXni2o0ePzROKI3+G7W23ue2SWlfIh2YF5g0JVZ1Nw7HBIp+zMniVAH9HjQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=tUZ8ySW8ZOgq7H7YEkdTvIim3l8yt8Gufsfy6Xuh51o=; b=AX5sGWHv/wfH8+HzcmNW2KPo46Bpx6b/5dCr6P+txl5sbJklZgeBwzjBjSn/CeMsCz7WB/plUiEFFDxWnKhEApunQyYraIW0EDvfJ9M38zgYGZis6Mls5gxc2tZ1SfwMrQ2vO087fvL7rka6xEEUmeYzrIsud/BQ87mk6CZI4I+W0DF10YgWotrpsjP26OGvYvm/Ra9ZFjbw35eGsO9kURyIrUt9hXo34f5r3dYKR16I1GMHLrqCCwW5L8hhN6iaKqPten2GrcRb2xFObowfrFQXD+OmFMbaFYFnmAQCxdJaIuv64uPANx45+XVvq6ECMn5aUEFI2pWRaT2EQ1TrUA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 12.22.5.238) smtp.rcpttodomain=broadcom.com smtp.mailfrom=nvidia.com; dmarc=pass (p=reject sp=reject pct=100) action=none header.from=nvidia.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Nvidia.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=tUZ8ySW8ZOgq7H7YEkdTvIim3l8yt8Gufsfy6Xuh51o=; b=hV/Jk48UvbIS7O5IAVhaoiOH3D3z6sJ1Ft24QFMxQeDxOqCt4/LD2iMSzDqnb2BE9W8ldJ+OJIC/mycjxFE7bI+IBsbShabf9VIg3GcdqzdV0sXw/qCkB0YwnL7U9XQ3rYBsaEilTOJRusPUpqX6XgXTx+8ODdn4bGYuILLROczV5/wsLMKjaSkiI80rXX/PgMQWsMzI6QgcCJNjWrZpuIZRcB7NQbDoGME9no5tbh/PKf2Dad08BiRoDvRDlXfObHqqqf4dIukBN9FJEmRvz2fsoX3oqccv0r/jCHCLfhsdP4A9NIvdYhvvzvo4F2bUNgB70C9mF5PmXditQ8Gmow== Received: from MWHPR08CA0041.namprd08.prod.outlook.com (2603:10b6:300:c0::15) by BY5PR12MB4242.namprd12.prod.outlook.com (2603:10b6:a03:203::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5353.15; Tue, 21 Jun 2022 08:07:12 +0000 Received: from CO1NAM11FT059.eop-nam11.prod.protection.outlook.com (2603:10b6:300:c0:cafe::b7) by MWHPR08CA0041.outlook.office365.com (2603:10b6:300:c0::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5353.14 via Frontend Transport; Tue, 21 Jun 2022 08:07:12 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 12.22.5.238) smtp.mailfrom=nvidia.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=nvidia.com; Received-SPF: Pass (protection.outlook.com: domain of nvidia.com designates 12.22.5.238 as permitted sender) receiver=protection.outlook.com; client-ip=12.22.5.238; helo=mail.nvidia.com; pr=C Received: from mail.nvidia.com (12.22.5.238) by CO1NAM11FT059.mail.protection.outlook.com (10.13.174.160) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.5353.14 via Frontend Transport; Tue, 21 Jun 2022 08:07:12 +0000 Received: from rnnvmail201.nvidia.com (10.129.68.8) by DRHQMAIL105.nvidia.com (10.27.9.14) with Microsoft SMTP Server (TLS) id 15.0.1497.32; Tue, 21 Jun 2022 08:07:12 +0000 Received: from nvidia.com (10.126.230.35) by rnnvmail201.nvidia.com (10.129.68.8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.22; Tue, 21 Jun 2022 01:07:10 -0700 From: Xueming Li To: Kalesh AP CC: Ajit Khaparde , Somnath Kotur , dpdk stable Subject: patch 'net/bnxt: fix Rx configuration' has been queued to stable release 20.11.6 Date: Tue, 21 Jun 2022 11:01:51 +0300 Message-ID: <20220621080301.2315720-46-xuemingl@nvidia.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20220621080301.2315720-1-xuemingl@nvidia.com> References: <20220621080301.2315720-1-xuemingl@nvidia.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.126.230.35] X-ClientProxiedBy: rnnvmail202.nvidia.com (10.129.68.7) To rnnvmail201.nvidia.com (10.129.68.8) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 3c3ead36-8338-40e9-2782-08da535d0bfc X-MS-TrafficTypeDiagnostic: BY5PR12MB4242:EE_ X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: tyun59mPazj6UDkNze9nF67mwN3/DcxLYzXnJC9rdRqIymUni0zM9HUT2Fn0ngyxzez0hy2D47joH4LbAL+jJDKyT04rfWrSxBsg+50kf3m6MrYjTOJ+zQ7sUWph/ysikhp9bZptD2ZOXPusPme3J7ma2fZubpni4G+nFAHnmKrQqv9YWk7ouVZvShsyw8N/XlJihkiHa17DMDTPlgyIR7o2GlFDaMDn3w8wLVWHe2wkMUBGweIla+OnoDlYIEblUjCtnzEV9EYxbpoE/s9fCQjXwT8uXaoAiKnmt4OXm8zX+h29+1DH89tYdKrDn27BQ/XedaS962nud7T8N+9AHD46Mqkcvp/qcrd+8WsA/9JJ1G7XgcI/TPkN3Vf7TUXoULYXE5QC06McqtwpGkh0vmTD5fUA4X2/PvRBcqM3jHYxfm2my6cKCFN3VraEwFZPm5mMp5fFpp0SG3LwQZF2R7a2+4qhyklxFRSXOq/pG+Bd1euaBD5+f7lneoC73qMfM72CQPW2N0EVWVBFrYIJJ7k6AxmIH2NuCLDMwk+cNIkPcxIxxTaP0poxjWSGNUJ5FQFEy8Q9YHH1sRcnygf7jhsvBTUHrSCekY3ncvREb8HybD95/NjoEEhn64UVhO/mBbe9y+Ar+LytlkdpDh4z7EmsNWCS8NkLC45t9s3x2urmo/MBB7Uw/X0OVsnK/fTFyYDHNcUu8nUBQ808eBuN34HrervyKu+r2n9Y+hb0O/+ysqAd5Blm8nJN2yzxFFomK1LgWQgqriOpvSZQgDjVHMhEDL2yaVvj2h1KisIjd95kGfADZT2iF5TyvvU6dnr0cCqkztsE2x0xYe9JEMuBf5JHgmUuRaopKUw5QJ+6+vg= X-Forefront-Antispam-Report: CIP:12.22.5.238; CTRY:US; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:mail.nvidia.com; PTR:InfoNoRecords; CAT:NONE; SFS:(13230016)(4636009)(346002)(376002)(39860400002)(396003)(136003)(36840700001)(40470700004)(46966006)(426003)(6916009)(36756003)(4326008)(54906003)(336012)(2616005)(356005)(36860700001)(8936002)(86362001)(5660300002)(186003)(53546011)(966005)(478600001)(47076005)(40480700001)(8676002)(55016003)(41300700001)(70586007)(16526019)(83380400001)(2906002)(40460700003)(82740400003)(1076003)(6286002)(6666004)(81166007)(26005)(70206006)(82310400005)(316002)(7696005)(36900700001); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 21 Jun 2022 08:07:12.3235 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 3c3ead36-8338-40e9-2782-08da535d0bfc X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=43083d15-7273-40c1-b7db-39efd9ccc17a; Ip=[12.22.5.238]; Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: CO1NAM11FT059.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BY5PR12MB4242 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Hi, FYI, your patch has been queued to stable release 20.11.6 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 06/23/22. So please shout if anyone has objections. Also note that after the patch there's a diff of the upstream commit vs the patch applied to the branch. This will indicate if there was any rebasing needed to apply to the stable branch. If there were code changes for rebasing (ie: not only metadata diffs), please double check that the rebase was correctly done. Queued patches are on a temporary branch at: https://github.com/steevenlee/dpdk This queued commit can be viewed at: https://github.com/steevenlee/dpdk/commit/c69db7f7f738f18d616bce1ddff29623f8e2db1c Thanks. Xueming Li --- >From c69db7f7f738f18d616bce1ddff29623f8e2db1c Mon Sep 17 00:00:00 2001 From: Kalesh AP Date: Wed, 27 Apr 2022 20:28:08 +0530 Subject: [PATCH] net/bnxt: fix Rx configuration Cc: Xueming Li [ upstream commit 0a90c56eacd5e345b42c7f152d33ca4c39343a52 ] We are currently not handling RX/RSS modes correctly. After launching testpmd with multiple RXQs, if the user tries to set the number of RXQs to 1, driver is not updating the "hash_type" and "hash_mode" values of the VNICs. As a result, driver issues bnxt_vnic_rss_configure() unnecessarily and the FW command fails. Fixed bnxt_mq_rx_configure() to update VNIC RSS fields unconditionally. Fixes: 4191bc8f79a8 ("net/bnxt: handle multi queue mode properly") Signed-off-by: Kalesh AP Reviewed-by: Ajit Khaparde Reviewed-by: Somnath Kotur --- drivers/net/bnxt/bnxt_rxq.c | 37 ++++++++++++++----------------------- 1 file changed, 14 insertions(+), 23 deletions(-) diff --git a/drivers/net/bnxt/bnxt_rxq.c b/drivers/net/bnxt/bnxt_rxq.c index 828b8e00aa..8145264950 100644 --- a/drivers/net/bnxt/bnxt_rxq.c +++ b/drivers/net/bnxt/bnxt_rxq.c @@ -54,6 +54,7 @@ void bnxt_free_rxq_stats(struct bnxt_rx_queue *rxq) int bnxt_mq_rx_configure(struct bnxt *bp) { struct rte_eth_conf *dev_conf = &bp->eth_dev->data->dev_conf; + struct rte_eth_rss_conf *rss = &bp->rss_conf; const struct rte_eth_vmdq_rx_conf *conf = &dev_conf->rx_adv_conf.vmdq_rx_conf; unsigned int i, j, nb_q_per_grp = 1, ring_idx = 0; @@ -161,29 +162,19 @@ skip_filter_allocation: bp->rx_num_qs_per_vnic = nb_q_per_grp; - if (dev_conf->rxmode.mq_mode & ETH_MQ_RX_RSS_FLAG) { - struct rte_eth_rss_conf *rss = &bp->rss_conf; - - for (i = 0; i < bp->nr_vnics; i++) { - uint32_t lvl = ETH_RSS_LEVEL(rss->rss_hf); - - vnic = &bp->vnic_info[i]; - vnic->hash_type = - bnxt_rte_to_hwrm_hash_types(rss->rss_hf); - vnic->hash_mode = - bnxt_rte_to_hwrm_hash_level(bp, - rss->rss_hf, - lvl); - - /* - * Use the supplied key if the key length is - * acceptable and the rss_key is not NULL - */ - if (rss->rss_key && - rss->rss_key_len <= HW_HASH_KEY_SIZE) - memcpy(vnic->rss_hash_key, - rss->rss_key, rss->rss_key_len); - } + for (i = 0; i < bp->nr_vnics; i++) { + uint32_t lvl = ETH_RSS_LEVEL(rss->rss_hf); + + vnic = &bp->vnic_info[i]; + vnic->hash_type = bnxt_rte_to_hwrm_hash_types(rss->rss_hf); + vnic->hash_mode = bnxt_rte_to_hwrm_hash_level(bp, rss->rss_hf, lvl); + + /* + * Use the supplied key if the key length is + * acceptable and the rss_key is not NULL + */ + if (rss->rss_key && rss->rss_key_len <= HW_HASH_KEY_SIZE) + memcpy(vnic->rss_hash_key, rss->rss_key, rss->rss_key_len); } return rc; -- 2.35.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2022-06-21 15:37:51.370956340 +0800 +++ 0045-net-bnxt-fix-Rx-configuration.patch 2022-06-21 15:37:49.051117966 +0800 @@ -1 +1 @@ -From 0a90c56eacd5e345b42c7f152d33ca4c39343a52 Mon Sep 17 00:00:00 2001 +From c69db7f7f738f18d616bce1ddff29623f8e2db1c Mon Sep 17 00:00:00 2001 @@ -4,0 +5,3 @@ +Cc: Xueming Li + +[ upstream commit 0a90c56eacd5e345b42c7f152d33ca4c39343a52 ] @@ -15 +17,0 @@ -Cc: stable@dpdk.org @@ -25 +27 @@ -index 3c2283b8c6..8977138012 100644 +index 828b8e00aa..8145264950 100644 @@ -28 +30 @@ -@@ -65,6 +65,7 @@ void bnxt_free_rxq_stats(struct bnxt_rx_queue *rxq) +@@ -54,6 +54,7 @@ void bnxt_free_rxq_stats(struct bnxt_rx_queue *rxq) @@ -36 +38 @@ -@@ -172,29 +173,19 @@ skip_filter_allocation: +@@ -161,29 +162,19 @@ skip_filter_allocation: @@ -40 +42 @@ -- if (dev_conf->rxmode.mq_mode & RTE_ETH_MQ_RX_RSS_FLAG) { +- if (dev_conf->rxmode.mq_mode & ETH_MQ_RX_RSS_FLAG) { @@ -44 +46 @@ -- uint32_t lvl = RTE_ETH_RSS_LEVEL(rss->rss_hf); +- uint32_t lvl = ETH_RSS_LEVEL(rss->rss_hf); @@ -64 +66 @@ -+ uint32_t lvl = RTE_ETH_RSS_LEVEL(rss->rss_hf); ++ uint32_t lvl = ETH_RSS_LEVEL(rss->rss_hf);