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 732C146A63 for ; Thu, 26 Jun 2025 14:07:23 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 6DB43400D6; Thu, 26 Jun 2025 14:07:23 +0200 (CEST) Received: from NAM11-CO1-obe.outbound.protection.outlook.com (mail-co1nam11on2071.outbound.protection.outlook.com [40.107.220.71]) by mails.dpdk.org (Postfix) with ESMTP id 25EA7400D6 for ; Thu, 26 Jun 2025 14:07:22 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=Z2oTEZYQP2c1b5lulG+GvLWe1N69o/RvaNOk5UZmaDd+evW7vqjYXKHocBHnvqzw1WlVn8PLeIh8FF+dG/2v2M9oD/lXzdh8nTJnhfDMNFED9/LNmNozF3Cj06tPZJbyMUn3Dliit2oHC1FK45CvIdbsT9qhSIB4NzdvRtVdmCpFWRJUIT2Sx8HQU+zqhXuPdqMP/d+Vc/aFtWckqwX7K4l2/369Es8BVfsabNIq2VRmFWdAFjWLfzya5aiqqV9kYL4p7D5pB4LDi7XlU82/2bOVgrnmiw+ZeLXZDTAudpKGkxGT/jcFcpW59A8jFYNyYcUo9wHiYs8VLAvQzquXVA== 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=Mo2PPM54KUMu/HWY8a8Jc+9jaAqDjU8uMn2prSukYoI=; b=g/QwApr7VfB0Qowcf4TyrLXt8hu3JBnrRPWvnJflKivAnCtxrXk2otyRIEIc/tjFUHkvf7YiO/UdwT9rygax/pP3TpI+zorG5+ZgtgmpeUZA74BAeLcGGDxLXa0M/EoKV6/57dbW2FLxZsqfgRulKkKik3qxt03PkjK7kBqNtHADqzmZ/gabaCtyQ/4iX2ODxGxcOS3o448HAC8RhRMQ1VRUAiqQJTnNozoEqsaW3Xya9vcT8tof+xdjFS7jgZ3FyvNe9W7qq2iHRAKjF1f/OJfUNZSfrfmQO0a3zs83SosJmQUQhbHRipNKxg5jlodi2NJRvvc9E4FVZIY3LVvBwQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.117.161) smtp.rcpttodomain=marvell.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=Mo2PPM54KUMu/HWY8a8Jc+9jaAqDjU8uMn2prSukYoI=; b=QPNqqlfYJmI17+igslDcO52a21sOwg9be17830jaCJEq96xdi20v+BSZBsq5zAUvxtYXzEqATPA7XQl+uwLD33pUA2LHraYOpxueaRy6rKzdE9FR/M2J5bOIIhar3OxR5YQW+Vh1YHEF/tECtuXvWeqwL7vywmpKuPFxtBtZJ4VP68qr5WO0EjgtdJhqX6Eccf+SHPSRhgEQXCqbCN+J2y096QELLkgrzsp26Y3q5o2IZG/TS3zOxuNrHF6nb8qJ2FNLuZV3DzJn6KeTqXiMYT2mIMgldHPuIx7xrxrT+goylpUlOEL+rrPTaLv+z6IuD32n3bu2d8vw2wM11nUEkw== Received: from SJ0PR03CA0025.namprd03.prod.outlook.com (2603:10b6:a03:33a::30) by CY8PR12MB8364.namprd12.prod.outlook.com (2603:10b6:930:7f::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8857.28; Thu, 26 Jun 2025 12:07:17 +0000 Received: from SJ5PEPF000001D2.namprd05.prod.outlook.com (2603:10b6:a03:33a:cafe::14) by SJ0PR03CA0025.outlook.office365.com (2603:10b6:a03:33a::30) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.20.8880.17 via Frontend Transport; Thu, 26 Jun 2025 12:07:17 +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 SJ5PEPF000001D2.mail.protection.outlook.com (10.167.242.54) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8880.14 via Frontend Transport; Thu, 26 Jun 2025 12:07:16 +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; Thu, 26 Jun 2025 05:07:03 -0700 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.1544.14; Thu, 26 Jun 2025 05:07:02 -0700 From: Xueming Li To: Nithin Dabilpuram CC: Xueming Li , dpdk stable Subject: patch 'common/cnxk: fix CQ tail drop' has been queued to stable release 23.11.5 Date: Thu, 26 Jun 2025 20:01:19 +0800 Message-ID: <20250626120145.27369-60-xuemingl@nvidia.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20250626120145.27369-1-xuemingl@nvidia.com> References: <20250626120145.27369-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: 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: SJ5PEPF000001D2:EE_|CY8PR12MB8364:EE_ X-MS-Office365-Filtering-Correlation-Id: c5bb2b44-f824-4591-6d08-08ddb4a9fe9b X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|82310400026|1800799024|36860700013|376014|13003099007|7053199007; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?Vq3Bjg77N4083vtaefaJMYwhOyOFe3QxlUtmSTj5BFHgIGOD6UNYHbgTupZv?= =?us-ascii?Q?+Ny6oZPymE/HQN+73/U5MHKS4Ls+zWtR4yio7KVTYs0hiUWyYL7Wu2LxGfm9?= =?us-ascii?Q?A7THt+/U0wuSrW7C4bj8A6yAVVkOJSft94NR/se2KBzsCqQpRHOMfOnlsB2u?= =?us-ascii?Q?IYT41Gu6ab1FGmtKB1cZP4L+CdcaN6Anq0AnicTCFTe5T1A4KgC44tB0tm/5?= =?us-ascii?Q?iBDnpo7yWHOShe8fz3GgLD8lueV75MxmZPDCPJQ/xA4AgSAMetm5aTymBKdd?= =?us-ascii?Q?KBKFcdmvCOs6+RKU8o6Jhc4v7ej4nBsmoJ3R03dr+qowW7fwhwrS+7MjY3EN?= =?us-ascii?Q?MyEIDyweT9JWuWvdFK4GYXjNUfotLz5WdaEDnP/30BxDGbm3VmbBC+9lFJwz?= =?us-ascii?Q?KYQJs9TObyTJK4QrmXlmHKS88Woj+J283xyTU2hOcBhGYfJGzh6n7/+9L2YQ?= =?us-ascii?Q?JX468zWLP2Iu8UaLvaJFHaaeUcCdAGEK2zSiuPxcLPqGtM/dW3siQws0hSC2?= =?us-ascii?Q?SvSJ4Pm+P2HKFKtxr5TPH1zU6z4E0AR70vJn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?G4CopL7rOA+8wceAI+GBCds0RAvq2f68jGoYnSOJRgj7kLZ9e5WzApc79B13?= =?us-ascii?Q?gI5sSOcek16VM6BUgdJCIVkxEjMR16v/siWE72bcT4BPR/j8QZQKFacwUQ?= =?us-ascii?Q?=3D=3D?= 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)(82310400026)(1800799024)(36860700013)(376014)(13003099007)(7053199007); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 26 Jun 2025 12:07:16.9960 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: c5bb2b44-f824-4591-6d08-08ddb4a9fe9b 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: SJ5PEPF000001D2.namprd05.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY8PR12MB8364 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.5 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/28/25. 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=589cb58bb089e8287dcaf43b9e1421aaa7716504 Thanks. Xueming Li --- >From 589cb58bb089e8287dcaf43b9e1421aaa7716504 Mon Sep 17 00:00:00 2001 From: Nithin Dabilpuram Date: Wed, 28 May 2025 17:21:16 +0530 Subject: [PATCH] common/cnxk: fix CQ tail drop Cc: Xueming Li [ upstream commit dc8f10bb36bbd9dd961e4baba693181add66c962 ] CQ tail drop feature is currently supposed to be enabled when inline IPsec is disabled. But since XQE drop is not enabled, CQ tail drop is implicitly disabled. Fix the same. Fixes: c8c967e11717 ("common/cnxk: support enabling AURA tail drop for RQ") Signed-off-by: Nithin Dabilpuram --- drivers/common/cnxk/roc_nix.h | 2 ++ drivers/common/cnxk/roc_nix_queue.c | 11 +++++++++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/drivers/common/cnxk/roc_nix.h b/drivers/common/cnxk/roc_nix.h index 250d710c07..3d507cace7 100644 --- a/drivers/common/cnxk/roc_nix.h +++ b/drivers/common/cnxk/roc_nix.h @@ -354,6 +354,8 @@ struct roc_nix_rq { bool lpb_drop_ena; /* SPB aura drop enable */ bool spb_drop_ena; + /* XQE drop enable */ + bool xqe_drop_ena; /* End of Input parameters */ struct roc_nix *roc_nix; uint64_t meta_aura_handle; diff --git a/drivers/common/cnxk/roc_nix_queue.c b/drivers/common/cnxk/roc_nix_queue.c index f96d5c3a96..4ffc3a70da 100644 --- a/drivers/common/cnxk/roc_nix_queue.c +++ b/drivers/common/cnxk/roc_nix_queue.c @@ -368,7 +368,7 @@ nix_rq_cn9k_cfg(struct dev *dev, struct roc_nix_rq *rq, uint16_t qints, aq->rq.rq_int_ena = 0; /* Many to one reduction */ aq->rq.qint_idx = rq->qid % qints; - aq->rq.xqe_drop_ena = 1; + aq->rq.xqe_drop_ena = rq->xqe_drop_ena; /* If RED enabled, then fill enable for all cases */ if (rq->red_pass && (rq->red_pass >= rq->red_drop)) { @@ -452,6 +452,7 @@ nix_rq_cfg(struct dev *dev, struct roc_nix_rq *rq, uint16_t qints, bool cfg, aq->rq.wqe_skip = rq->wqe_skip; aq->rq.wqe_caching = 1; + aq->rq.xqe_drop_ena = 0; aq->rq.good_utag = rq->tag_mask >> 24; aq->rq.bad_utag = rq->tag_mask >> 24; aq->rq.ltag = rq->tag_mask & BITMASK_ULL(24, 0); @@ -471,6 +472,8 @@ nix_rq_cfg(struct dev *dev, struct roc_nix_rq *rq, uint16_t qints, bool cfg, aq->rq.bad_utag = rq->tag_mask >> 24; aq->rq.ltag = rq->tag_mask & BITMASK_ULL(24, 0); aq->rq.cq = rq->cqid; + if (rq->xqe_drop_ena) + aq->rq.xqe_drop_ena = 1; } if (rq->ipsech_ena) { @@ -519,7 +522,6 @@ nix_rq_cfg(struct dev *dev, struct roc_nix_rq *rq, uint16_t qints, bool cfg, aq->rq.rq_int_ena = 0; /* Many to one reduction */ aq->rq.qint_idx = rq->qid % qints; - aq->rq.xqe_drop_ena = 0; aq->rq.lpb_drop_ena = rq->lpb_drop_ena; aq->rq.spb_drop_ena = rq->spb_drop_ena; @@ -564,6 +566,7 @@ nix_rq_cfg(struct dev *dev, struct roc_nix_rq *rq, uint16_t qints, bool cfg, aq->rq_mask.bad_utag = ~aq->rq_mask.bad_utag; aq->rq_mask.ltag = ~aq->rq_mask.ltag; aq->rq_mask.cq = ~aq->rq_mask.cq; + aq->rq_mask.xqe_drop_ena = ~aq->rq_mask.xqe_drop_ena; } if (rq->ipsech_ena) @@ -675,6 +678,10 @@ roc_nix_rq_init(struct roc_nix *roc_nix, struct roc_nix_rq *rq, bool ena) rq->roc_nix = roc_nix; rq->tc = ROC_NIX_PFC_CLASS_INVALID; + /* Enable XQE/CQ drop on cn10k to count pkt drops only when inline is disabled */ + if (roc_model_is_cn10k() && !roc_nix_inl_inb_is_enabled(roc_nix)) + rq->xqe_drop_ena = true; + if (is_cn9k) rc = nix_rq_cn9k_cfg(dev, rq, nix->qints, false, ena); else -- 2.34.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2025-06-26 19:59:20.048455733 +0800 +++ 0059-common-cnxk-fix-CQ-tail-drop.patch 2025-06-26 19:59:17.442418042 +0800 @@ -1 +1 @@ -From dc8f10bb36bbd9dd961e4baba693181add66c962 Mon Sep 17 00:00:00 2001 +From 589cb58bb089e8287dcaf43b9e1421aaa7716504 Mon Sep 17 00:00:00 2001 @@ -4,0 +5,3 @@ +Cc: Xueming Li + +[ upstream commit dc8f10bb36bbd9dd961e4baba693181add66c962 ] @@ -11 +13,0 @@ -Cc: stable@dpdk.org @@ -20 +22 @@ -index 80392e7e1b..1e543d8f11 100644 +index 250d710c07..3d507cace7 100644 @@ -23 +25 @@ -@@ -355,6 +355,8 @@ struct roc_nix_rq { +@@ -354,6 +354,8 @@ struct roc_nix_rq { @@ -33 +35 @@ -index e852211ba4..39bd051c94 100644 +index f96d5c3a96..4ffc3a70da 100644 @@ -36 +38 @@ -@@ -530,7 +530,7 @@ nix_rq_cn9k_cfg(struct dev *dev, struct roc_nix_rq *rq, uint16_t qints, +@@ -368,7 +368,7 @@ nix_rq_cn9k_cfg(struct dev *dev, struct roc_nix_rq *rq, uint16_t qints, @@ -45 +47 @@ -@@ -613,6 +613,7 @@ nix_rq_cn10k_cfg(struct dev *dev, struct roc_nix_rq *rq, uint16_t qints, bool cf +@@ -452,6 +452,7 @@ nix_rq_cfg(struct dev *dev, struct roc_nix_rq *rq, uint16_t qints, bool cfg, @@ -53 +55 @@ -@@ -632,6 +633,8 @@ nix_rq_cn10k_cfg(struct dev *dev, struct roc_nix_rq *rq, uint16_t qints, bool cf +@@ -471,6 +472,8 @@ nix_rq_cfg(struct dev *dev, struct roc_nix_rq *rq, uint16_t qints, bool cfg, @@ -62 +64 @@ -@@ -680,7 +683,6 @@ nix_rq_cn10k_cfg(struct dev *dev, struct roc_nix_rq *rq, uint16_t qints, bool cf +@@ -519,7 +522,6 @@ nix_rq_cfg(struct dev *dev, struct roc_nix_rq *rq, uint16_t qints, bool cfg, @@ -70 +72 @@ -@@ -725,6 +727,7 @@ nix_rq_cn10k_cfg(struct dev *dev, struct roc_nix_rq *rq, uint16_t qints, bool cf +@@ -564,6 +566,7 @@ nix_rq_cfg(struct dev *dev, struct roc_nix_rq *rq, uint16_t qints, bool cfg, @@ -78 +80 @@ -@@ -950,6 +953,10 @@ roc_nix_rq_init(struct roc_nix *roc_nix, struct roc_nix_rq *rq, bool ena) +@@ -675,6 +678,10 @@ roc_nix_rq_init(struct roc_nix *roc_nix, struct roc_nix_rq *rq, bool ena) @@ -88 +90 @@ - else if (roc_model_is_cn10k()) + else