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 A8F0645E41 for ; Sat, 7 Dec 2024 09:06:27 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 9C0A340281; Sat, 7 Dec 2024 09:06:27 +0100 (CET) Received: from NAM04-MW2-obe.outbound.protection.outlook.com (mail-mw2nam04on2058.outbound.protection.outlook.com [40.107.101.58]) by mails.dpdk.org (Postfix) with ESMTP id 057A740281 for ; Sat, 7 Dec 2024 09:06:26 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=TFWa3qPGVqI8SSwkHQ0D/mFaR4W+ib8emCrf5y5ePcgFfjtlZw3eNC+6U9bJmL+p1SX4dL9In5iBEBk8xtDzg9xaVwCch4hEXtzcHm/qhBgpmsPAoa+5SRoIEyfxZprVJF3Rs398xrHh5q4rtZXFsxvU1/ALJCWAypeLgfrMPd3Aw3FsU1K2cK5zpJkimOKRj1zJx1frWiXGyfiBQ5sUgl587jsqlnOPcHsTTGedEF5UbvL7hsIx0FN5nEw9PgUwlZIjN1bcICBnCbSw6BNRZceQDjWSItWN0BkLM1rrlBeQS/uDbv1ilHEah4oIFl28JPHwGRUngLoeW4wDX0GJOw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; 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=GKOBrslHpLXzbDBTSHiLrbkT33exOmsFQEznoYKXnT8=; b=pcLgTjsu4BhVAQVm1Fb2KkpKUDxOWvVPu50tpX/VQHl3kmhdA0qRdttOWBlDdVG4VIQuI7nYqZTUl3mDY5N0A8HcTzokL78cFyhwmShRO82LGKTErtL4WOPiLFJrERoHUuVCq1U7NFJtAB8zJVU4xZyWNvJgexkqsjfnkjCj6bHexkrECOerCV6elzqO5qqPUdDenn0Wdr2obp+yOI3pOtwwacyhLv8O26y0m2A2yunm5QI4Pwq4Tx0qyV/zuITxI+OPhhSGc5JjPW16xWTIvkcVW5eeBmXkcC95YNizHJJG+XX8Z+6UUjPIt2mzKz1kznGp4DBImUaASvwyv3Bhtg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.117.161) 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 (0) 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=GKOBrslHpLXzbDBTSHiLrbkT33exOmsFQEznoYKXnT8=; b=dOIqdMv1w5PLkDod7ayEtQ5tA44KNHwct3CEUCf0S3TQ0zadkSHwXkoGKl0ox5iye3FDyFIt3zFo3gDHeDCVgZ1M6JXhAMGePz+19JpJVONTnxmLWuGaqZylCquHMhF8YOggH5FG16Npi9yIpe/8iQLtl3hwpHyM7RM9/62DHtuZxyPdWxhbGoaGbewVZplnODkd2P76fzGvEbRv0iS/AufIrnOaDhmj9rMF2Zhldv0BVkU15KD8zrIXvNvJ03Ng+yLmuitPYgN2hcE+YIdx+SG+FtXkJmheSt/TGTi9nYUxr+mYJyCfPMpue6c1xz+aHyuO0gK+LBf2DJra8oBLog== Received: from MN2PR04CA0033.namprd04.prod.outlook.com (2603:10b6:208:d4::46) by DS0PR12MB7945.namprd12.prod.outlook.com (2603:10b6:8:153::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8207.24; Sat, 7 Dec 2024 08:06:21 +0000 Received: from BL02EPF00021F6D.namprd02.prod.outlook.com (2603:10b6:208:d4:cafe::bc) by MN2PR04CA0033.outlook.office365.com (2603:10b6:208:d4::46) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.20.8207.14 via Frontend Transport; Sat, 7 Dec 2024 08:06:21 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 216.228.117.161) 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 216.228.117.161 as permitted sender) receiver=protection.outlook.com; client-ip=216.228.117.161; helo=mail.nvidia.com; pr=C Received: from mail.nvidia.com (216.228.117.161) by BL02EPF00021F6D.mail.protection.outlook.com (10.167.249.9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8230.7 via Frontend Transport; Sat, 7 Dec 2024 08:06:21 +0000 Received: from rnnvmail201.nvidia.com (10.129.68.8) by mail.nvidia.com (10.129.200.67) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1544.4; Sat, 7 Dec 2024 00:06:04 -0800 Received: from nvidia.com (10.126.231.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.1544.4; Sat, 7 Dec 2024 00:06:02 -0800 From: Xueming Li To: Sangtani Parag Satishbhai CC: Xueming Li , Sriharsha Basavapatna , Ajit Khaparde , dpdk stable Subject: patch 'net/bnxt/tf_core: fix slice count in case of HA entry move' has been queued to stable release 23.11.3 Date: Sat, 7 Dec 2024 16:00:12 +0800 Message-ID: <20241207080055.488538-55-xuemingl@nvidia.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20241207080055.488538-1-xuemingl@nvidia.com> References: <20241111062847.216344-122-xuemingl@nvidia.com> <20241207080055.488538-1-xuemingl@nvidia.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.126.231.35] X-ClientProxiedBy: rnnvmail201.nvidia.com (10.129.68.8) To rnnvmail201.nvidia.com (10.129.68.8) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: BL02EPF00021F6D:EE_|DS0PR12MB7945:EE_ X-MS-Office365-Filtering-Correlation-Id: 941ef8eb-f0bf-4ec4-3a10-08dd16960967 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|376014|1800799024|36860700013|82310400026|7053199007; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?H/1hfrS/iwA+hFtfoxUbKYlpgt7iqH5kPSDNguxxGINfhSvbdbcC3UU7qdBx?= =?us-ascii?Q?IRQgyXPbh7COvsIiXSBpBOwuUqClLUNCrM5h8k/9lQAtNbLVhgIKs5UDGFqA?= =?us-ascii?Q?06VpU11gkGCY9DgzBfew348CTb76jvrnQomMGeSibZxHa06/CzVz2ANdkiOY?= =?us-ascii?Q?q+h1N5eD7fTpaa5SADm25qgdQ0Kc5nQyrwlV0YC3FnNyUdH3kpgPIel6Ivdt?= =?us-ascii?Q?tEniJSNM7xSxcoDKm1fay9j3sTKQIzMo9V1Vz3dPcyAWLUghLjtGkkTpmE9K?= =?us-ascii?Q?jVURHlXbg/syQ+ljaQ66FjZwpFwrgBXAmNzoEx++7+Pdncc7Jz/vTWiUdny6?= =?us-ascii?Q?rI+gcYSE++4G77NuwLFSLXxuZygjr11BCaz68Vnc+9JvhNB3CagX2zEU+oit?= =?us-ascii?Q?rFOMZNim/Q3FlLHnxUHDo7QQHMDEf29AfkVZqCks4l7iDifAwe1tCmuvKw/f?= =?us-ascii?Q?jU/mcn7AIounzlQn31Iprew+hUB2LWW2nKK9/sVnacORGVNsv3NDp0y54RRk?= =?us-ascii?Q?kP1oxLSADhUPawviuSAJ89yYJ3WieWhqpjr0wl2lft58leB8s6Joe/gk5C/C?= =?us-ascii?Q?rJlxUR/1eL3m+60cYlk+2FMwKJMc55pjtX0oAzR/TjFdFgcdliZfphgXN0/R?= =?us-ascii?Q?9o386eOqyx1/pOkPIAzyJe+fkrqpRZjpHa+B8JuDg5llY1VKXepVFZDPRM++?= =?us-ascii?Q?Pm13johHxMdAQZ8T/yoN4+rpJo3kfprFuKFJoYg+QUuwvHsEqdCASF4v4M+C?= =?us-ascii?Q?TLT9VA7IfqMmwK8aGtcaBszqAkEiPqjfxdn2AZP/MNdMTQHU1GNr6Pfq011B?= =?us-ascii?Q?Z5aAgE3hZF3h+aFuFunkFVFc578smnbkPtM0igSIWb4l8tWyecc3FA64wE64?= =?us-ascii?Q?x6A9EyJYX19TzJhQY9AdKKyccyo/KFLHOO/oSxOEkwOTteMd9+HBic7RBn0n?= =?us-ascii?Q?7pNfRHGWZCYvI5FPHhurJecw585xD1a2wAORY/Mqp8T21BClZNfzFfyOKQCw?= =?us-ascii?Q?CrjWMdJP/UKMvhztpXtNnrQJhWrAHtTOCbJdZW5oTqbjAzj8WCkJikjLecKB?= =?us-ascii?Q?7ZYrPlIl/DiqElI+sioxtMfyZuZoo68tzh0aI/cM42mcWKTQ9fWynb4lwsOF?= =?us-ascii?Q?WWD4lOX5ESkoDqld/PCWNK+ihNu/i82u+RUYdjNsMcKtm6o1PsPalOg1Sm75?= =?us-ascii?Q?duR9AVeHPXilw2UUMUzNX1wMlSwPcJe8qRPJ791y5myGVK2CVrfM9Ayci2Ao?= =?us-ascii?Q?Kj1MXEGtDIB7clmePLuBVRU5HUw4UFupRjhBU73gkN2+wPLs0i8mPpZW1VeB?= =?us-ascii?Q?bcOq/44ndBPRp1yQ5O7wMfr3chuG0QFnWKR58TYAZ6IQddMGjwcZwH/S8tZY?= =?us-ascii?Q?V7L6nIiUC0ui2J0RxymF71XSRbtLXqSqaPK6YAyX7eOZn1uKr4PHssz284gc?= =?us-ascii?Q?4RlTB3mdoE3XUIBognGCD8jggAHnSTwf?= X-Forefront-Antispam-Report: CIP:216.228.117.161; CTRY:US; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:mail.nvidia.com; PTR:dc6edge2.nvidia.com; CAT:NONE; SFS:(13230040)(376014)(1800799024)(36860700013)(82310400026)(7053199007); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 Dec 2024 08:06:21.2956 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 941ef8eb-f0bf-4ec4-3a10-08dd16960967 X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=43083d15-7273-40c1-b7db-39efd9ccc17a; Ip=[216.228.117.161]; Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: BL02EPF00021F6D.namprd02.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DS0PR12MB7945 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 23.11.3 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 12/10/24. 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://git.dpdk.org/dpdk-stable/log/?h=23.11-staging This queued commit can be viewed at: https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=c1606948da25d750aca4e3879c041fefa71286ef Thanks. Xueming Li --- >From c1606948da25d750aca4e3879c041fefa71286ef Mon Sep 17 00:00:00 2001 From: Sangtani Parag Satishbhai Date: Thu, 7 Nov 2024 19:22:14 +0530 Subject: [PATCH] net/bnxt/tf_core: fix slice count in case of HA entry move Cc: Xueming Li [ upstream commit 1190f2f8d5abf82c843ad071ad4c7d0aea202cce ] When entries are moved during HA, a shared move function transfers TCAM entries by using get/set message APIs, and the slice number of the entry is required to accomplish the movement. The slice number is calculated as the product of row_slice and entry size. Before calling get/set message APIs, the source entry size should be updated with the destination entry size; otherwise, it might corrupt the slice number field, which may result in writing an incorrect entry. A fix is made which now copies the entry size from the source to the destination before calling get/set message APIs, ensuring the correct slice number is modified. Fixes: 97435d7906d7 ("net/bnxt: update Truflow core") Signed-off-by: Sangtani Parag Satishbhai Reviewed-by: Sriharsha Basavapatna Reviewed-by: Ajit Khaparde --- .mailmap | 1 + drivers/net/bnxt/tf_core/cfa_tcam_mgr.c | 6 +++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/.mailmap b/.mailmap index 879d0fd81c..67ff5b21c6 100644 --- a/.mailmap +++ b/.mailmap @@ -1264,6 +1264,7 @@ Sampath Peechu Samuel Gauthier Sandilya Bhagi Sangjin Han +Sangtani Parag Satishbhai Sankar Chokkalingam Santoshkumar Karanappa Rastapur Santosh Shukla diff --git a/drivers/net/bnxt/tf_core/cfa_tcam_mgr.c b/drivers/net/bnxt/tf_core/cfa_tcam_mgr.c index 9df2d2b937..130985f92a 100644 --- a/drivers/net/bnxt/tf_core/cfa_tcam_mgr.c +++ b/drivers/net/bnxt/tf_core/cfa_tcam_mgr.c @@ -1678,6 +1678,11 @@ cfa_tcam_mgr_shared_entry_move(int sess_idx, struct cfa_tcam_mgr_context *contex uint8_t key[CFA_TCAM_MGR_MAX_KEY_SIZE]; uint8_t mask[CFA_TCAM_MGR_MAX_KEY_SIZE]; uint8_t result[CFA_TCAM_MGR_MAX_KEY_SIZE]; + /* + * Copy entry size before moving else if + * slice number is non zero and entry size is zero it will cause issues + */ + dst_row->entry_size = src_row->entry_size; int rc; @@ -1752,7 +1757,6 @@ cfa_tcam_mgr_shared_entry_move(int sess_idx, struct cfa_tcam_mgr_context *contex ROW_ENTRY_SET(dst_row, dst_row_slice); dst_row->entries[dst_row_slice] = entry_id; - dst_row->entry_size = src_row->entry_size; dst_row->priority = src_row->priority; ROW_ENTRY_CLEAR(src_row, entry->slice); entry->row = dst_row_index; -- 2.34.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2024-12-06 23:26:45.882001506 +0800 +++ 0054-net-bnxt-tf_core-fix-slice-count-in-case-of-HA-entry.patch 2024-12-06 23:26:43.963044828 +0800 @@ -1 +1 @@ -From 1190f2f8d5abf82c843ad071ad4c7d0aea202cce Mon Sep 17 00:00:00 2001 +From c1606948da25d750aca4e3879c041fefa71286ef Mon Sep 17 00:00:00 2001 @@ -4,0 +5,3 @@ +Cc: Xueming Li + +[ upstream commit 1190f2f8d5abf82c843ad071ad4c7d0aea202cce ] @@ -17 +19,0 @@ -Cc: stable@dpdk.org @@ -28 +30 @@ -index 4dbb8cf8a7..f293f89167 100644 +index 879d0fd81c..67ff5b21c6 100644 @@ -31 +33 @@ -@@ -1326,6 +1326,7 @@ Sampath Peechu +@@ -1264,6 +1264,7 @@ Sampath Peechu @@ -40 +42 @@ -index 349f52caba..33b1e4121e 100644 +index 9df2d2b937..130985f92a 100644 @@ -43 +45 @@ -@@ -1717,6 +1717,11 @@ cfa_tcam_mgr_shared_entry_move(int sess_idx, struct cfa_tcam_mgr_context *contex +@@ -1678,6 +1678,11 @@ cfa_tcam_mgr_shared_entry_move(int sess_idx, struct cfa_tcam_mgr_context *contex @@ -55 +57 @@ -@@ -1791,7 +1796,6 @@ cfa_tcam_mgr_shared_entry_move(int sess_idx, struct cfa_tcam_mgr_context *contex +@@ -1752,7 +1757,6 @@ cfa_tcam_mgr_shared_entry_move(int sess_idx, struct cfa_tcam_mgr_context *contex