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 06C8E45CE3 for ; Mon, 11 Nov 2024 07:36:49 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id F32C840685; Mon, 11 Nov 2024 07:36:48 +0100 (CET) Received: from NAM02-SN1-obe.outbound.protection.outlook.com (mail-sn1nam02on2040.outbound.protection.outlook.com [40.107.96.40]) by mails.dpdk.org (Postfix) with ESMTP id 577FB40685 for ; Mon, 11 Nov 2024 07:36:47 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=GvUcanGeJ950XreFZ2dKgbEsYgMRn6ioBwQb0ju+MuR3DcFPNeMfiMxrwIwu5zGWjKYOVc176fLdJeB3yrssxyvSMLRSVK0QjMgHK06rXkBpkOytDMi7vLpFDmQGytziNzPKKpmGyHKGmnFiV1xjFsH1VUGyHd1eW86C0+KNMZGKUpuRJK0BUPK3O1SxuyPNu4/f+iDQpsxKvk4VkOjTFXNhpWIsbomlbEqZSBybEECP1R65PG7cUuykoh6T6mCNlwuxoKqouju1hy/Q+r9mKfNrqwGMB2aw/hkERw0cMMXeqVIkpa9CyqDWRStW9YWbzo+QWYZkHHjRP1Yi3zM91w== 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=20zp2m6KJa9dkdiOLzlrjASpoXya3rfdr7njOtNjZTw=; b=W1Ht/Cz2ekZxkxoFTEWPn+VhGqaiUKN7IsUd18GolSWAAoy9jJKcWu2tI6qCo2GmH2FWNdCZUDnHoxAyL/hiRPZTm30dOsCfNOu5q5iEGF0xtl/7Tys8RFtIqCLXPoeH5s7syiqkAEikLqJSI3pMtqTiAfGikvic1Vj5Hua8Db6vrP0TK4E0OMRDzxvxzygL5nqNDZaACeqU62St6JlmgUvaS2EMU10a1RJ5nj1Uf8DW+BwU5jtXoNyNmn36mHWol2qnY3IkFSmzWudBlOt2pxXi95wiu37bxqjO7wgJLbQeDiO2P+YBxulEaHhFBLdtOs2kmF9vZKx/hjmPLMWzjg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.117.161) smtp.rcpttodomain=gmail.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=20zp2m6KJa9dkdiOLzlrjASpoXya3rfdr7njOtNjZTw=; b=fNVqM71EoEYEpBaF8+2QXu8qlWmpnMVXneua34NDSDvEkBCPx+UcZKY1d/FFw5rRTWTzBA+0Z8rx/nP9loCkj1N2YnRKpjCIJXybXiBTIcSxcOmTkpQDGx3X+c5s7VFQ5Dxsy1mZkSb/pMfTuCE2ARtKKeaGh63Gsg9yGp36y/68iuYooHzRbKJdzJNiLTbG92xQ71nIJGhko8u/PmDLWElPEF7ld/GW8a9Bux3FhTAQxxJ5g4p2jVhWI3b1AVGeqD5W7pIWJoF6ZniOWb6NfK7CFl9FfGSnBJLPlrBVnXpfNi52KCTsWUpttnXoE/QFCjCbo8V1zC8p9K/qVnbBEw== Received: from BN9PR03CA0762.namprd03.prod.outlook.com (2603:10b6:408:13a::17) by MW3PR12MB4411.namprd12.prod.outlook.com (2603:10b6:303:5e::24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8137.28; Mon, 11 Nov 2024 06:36:44 +0000 Received: from BL02EPF00021F69.namprd02.prod.outlook.com (2603:10b6:408:13a:cafe::6f) by BN9PR03CA0762.outlook.office365.com (2603:10b6:408:13a::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8137.28 via Frontend Transport; Mon, 11 Nov 2024 06:36:44 +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 BL02EPF00021F69.mail.protection.outlook.com (10.167.249.5) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8158.14 via Frontend Transport; Mon, 11 Nov 2024 06:36:44 +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; Sun, 10 Nov 2024 22:36:28 -0800 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.4; Sun, 10 Nov 2024 22:36:26 -0800 From: Xueming Li To: Tathagat Priyadarshi CC: , Varun Lakkur Ambaji Rao , Joshua Washington , dpdk stable Subject: patch 'net/gve: fix Tx for chained mbuf' has been queued to stable release 23.11.3 Date: Mon, 11 Nov 2024 14:28:00 +0800 Message-ID: <20241111062847.216344-75-xuemingl@nvidia.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20241111062847.216344-1-xuemingl@nvidia.com> References: <20241111062847.216344-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-TrafficTypeDiagnostic: BL02EPF00021F69:EE_|MW3PR12MB4411:EE_ X-MS-Office365-Filtering-Correlation-Id: 395e3835-50d2-4589-4de1-08dd021b35a4 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|36860700013|376014|82310400026|1800799024; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?kLhSG4b1pY86o3WLoiN6NUgmfWQzazwujpHOKoEyMW501Ai97TFs2xfGs2Wc?= =?us-ascii?Q?4tUIbE6ZzOd8/gUtfsjRZh0QHEiullau5AKnxxoeLogYtuPkl95G6piJMYjf?= =?us-ascii?Q?/yaXJgPu0SqMxDHaC0/PkhXTB+JiZ1Nnf/PbF8L8tTSsKtXYc79xRfel9ozj?= =?us-ascii?Q?8pjiFSpmsZI3djYU9O/c8dW/x/tdF0VTXZKWbg07lQFSKDBoYfIAe0G2iXfY?= =?us-ascii?Q?GHqBrYpx+v7RuTURMpjjl66qe5yfD65SNk2LYki2IKWa6eOECSnvFu4HU7Y6?= =?us-ascii?Q?R+TYmGdO7tph01K6qDIqBqcA9Kgmv4PuW7SwTIqHGtQXaixU8eFAR4VCQQ0L?= =?us-ascii?Q?8r66aZOpSyKFi4f7q2ViTOZpDdvtYWl9P5juunl7rYnoZ1+Z2z31I8wmsmTO?= =?us-ascii?Q?cNAW4qpKlVJ2XMShfKlwskpQhrSr3zpaU+MRsk1jQuUQ0S/0HDxYDZJrpwey?= =?us-ascii?Q?eQJwYCzkbUhlbanbjIMNCnopc7nI/W2JuihcVAhjXh+afFbrGOn5aguxgubn?= =?us-ascii?Q?OTuRR7F5l6dkSNN8iYXxPoSBm3Do9KqJwgYZlDVH41ie4akYdmx+9nFKVD78?= =?us-ascii?Q?SxVpEWy4K7BRw+R7Cv/yKJ0jMzMYp+RocLbGoOxcxIcIRLWVUZvSFzy6g1l0?= =?us-ascii?Q?gjCyw+iupeygKTnlCDnjYUpraBNNEBVu9viWMmyXE6OzG2TEFPid40ec4aMa?= =?us-ascii?Q?YmCzID+0rVE9vwvucXxqml8VTgsssy4coy4ePy3oUmYWhO1A03gIIHkvSw9y?= =?us-ascii?Q?Uxqk4V4yQ3JFTpQgJYTYkAl8RIOWry01GErLqRrGIdTWtB8V7qc6cdWriUsb?= =?us-ascii?Q?jPYsiX7xwge0zYhiVnD5udo7wO5mn+6wZPrHBDjxGBi7Zh4fMhzXD7gwOb7Y?= =?us-ascii?Q?UyVfgUKIPLYtbygWpRw/oIy5ZL2U1P4i0iv80Tmjdpl3gaZ2+egKjUOstOQM?= =?us-ascii?Q?pwAaFAPEsjEihUUs0+PT1zA9LDv5ngTK1mE1Z7u0rFcuZ4TQWWRUlXXgmLWe?= =?us-ascii?Q?UCnuUq1pDTzTfFdlHxO1uDh+oIcq4li9aVfsCzCa1mM10lLArfuLBj571ATf?= =?us-ascii?Q?tqZhAdU2NbkWJicz2tJDojN+QemJn7YgmtmxApAFn1jIOp5w/NOXGRNziud7?= =?us-ascii?Q?HXEHXrEhct50b+XNDejEq4IPmx/MoLBwpRtB2LKB1aPS31UGK4JuOH/liTEp?= =?us-ascii?Q?LM5YOxrfxaxOp624XucypJmCJWxOY++XkZJFkOORKfbJfmGai5o7NuG0iqlH?= =?us-ascii?Q?o+9ogunMZv2CnaoMpvM912TG9OBOERG4OKiljkYxfucDjr785/j8UldqGUFT?= =?us-ascii?Q?+c4mgDoFznD+AYC4sTnTDyEuGQP5KReWnk5JSGdUluXaZMqO9LdAe16bGhvO?= =?us-ascii?Q?TXGe06JHldA1dU9GDj3agVLKriF/DSyO+7Xv464OSgnMENs3Bg=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)(36860700013)(376014)(82310400026)(1800799024); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 11 Nov 2024 06:36:44.1779 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 395e3835-50d2-4589-4de1-08dd021b35a4 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: BL02EPF00021F69.namprd02.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: MW3PR12MB4411 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 11/30/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=32d8e5279beaacefe5e7cf91f4d265ac87667ce6 Thanks. Xueming Li --- >From 32d8e5279beaacefe5e7cf91f4d265ac87667ce6 Mon Sep 17 00:00:00 2001 From: Tathagat Priyadarshi Date: Fri, 2 Aug 2024 05:08:08 +0000 Subject: [PATCH] net/gve: fix Tx for chained mbuf Cc: Xueming Li [ upstream commit 21b1d725e5a6cd38fe28d83c1f6cf00d80643b31 ] The EOP and CSUM bit was not set for all the packets in mbuf chain causing packet transmission stalls for packets split across mbuf in chain. Fixes: 4022f9999f56 ("net/gve: support basic Tx data path for DQO") Signed-off-by: Tathagat Priyadarshi Signed-off-by: Varun Lakkur Ambaji Rao Acked-by: Joshua Washington --- .mailmap | 1 + drivers/net/gve/gve_ethdev.h | 2 ++ drivers/net/gve/gve_tx_dqo.c | 9 ++++++--- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/.mailmap b/.mailmap index a72dce1a61..5f2593e00e 100644 --- a/.mailmap +++ b/.mailmap @@ -1489,6 +1489,7 @@ Vadim Suraev Vakul Garg Vamsi Attunuru Vanshika Shukla +Varun Lakkur Ambaji Rao Varun Sethi Vasily Philipov Veerasenareddy Burru diff --git a/drivers/net/gve/gve_ethdev.h b/drivers/net/gve/gve_ethdev.h index 58d8943e71..133860488c 100644 --- a/drivers/net/gve/gve_ethdev.h +++ b/drivers/net/gve/gve_ethdev.h @@ -33,6 +33,8 @@ RTE_MBUF_F_TX_L4_MASK | \ RTE_MBUF_F_TX_TCP_SEG) +#define GVE_TX_CKSUM_OFFLOAD_MASK_DQO (GVE_TX_CKSUM_OFFLOAD_MASK | RTE_MBUF_F_TX_IP_CKSUM) + /* A list of pages registered with the device during setup and used by a queue * as buffers */ diff --git a/drivers/net/gve/gve_tx_dqo.c b/drivers/net/gve/gve_tx_dqo.c index 97d9c6549b..b9d6d01749 100644 --- a/drivers/net/gve/gve_tx_dqo.c +++ b/drivers/net/gve/gve_tx_dqo.c @@ -89,6 +89,7 @@ gve_tx_burst_dqo(void *tx_queue, struct rte_mbuf **tx_pkts, uint16_t nb_pkts) uint16_t sw_id; uint64_t bytes; uint16_t first_sw_id; + uint8_t csum; sw_ring = txq->sw_ring; txr = txq->tx_ring; @@ -114,6 +115,9 @@ gve_tx_burst_dqo(void *tx_queue, struct rte_mbuf **tx_pkts, uint16_t nb_pkts) ol_flags = tx_pkt->ol_flags; nb_used = tx_pkt->nb_segs; first_sw_id = sw_id; + + csum = !!(ol_flags & GVE_TX_CKSUM_OFFLOAD_MASK_DQO); + do { if (sw_ring[sw_id] != NULL) PMD_DRV_LOG(DEBUG, "Overwriting an entry in sw_ring"); @@ -126,6 +130,8 @@ gve_tx_burst_dqo(void *tx_queue, struct rte_mbuf **tx_pkts, uint16_t nb_pkts) txd->pkt.dtype = GVE_TX_PKT_DESC_DTYPE_DQO; txd->pkt.compl_tag = rte_cpu_to_le_16(first_sw_id); txd->pkt.buf_size = RTE_MIN(tx_pkt->data_len, GVE_TX_MAX_BUF_SIZE_DQO); + txd->pkt.end_of_packet = 0; + txd->pkt.checksum_offload_enable = csum; /* size of desc_ring and sw_ring could be different */ tx_id = (tx_id + 1) & mask; @@ -138,9 +144,6 @@ gve_tx_burst_dqo(void *tx_queue, struct rte_mbuf **tx_pkts, uint16_t nb_pkts) /* fill the last descriptor with End of Packet (EOP) bit */ txd->pkt.end_of_packet = 1; - if (ol_flags & GVE_TX_CKSUM_OFFLOAD_MASK) - txd->pkt.checksum_offload_enable = 1; - txq->nb_free -= nb_used; txq->nb_used += nb_used; } -- 2.34.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2024-11-11 14:23:08.630247869 +0800 +++ 0074-net-gve-fix-Tx-for-chained-mbuf.patch 2024-11-11 14:23:05.182192838 +0800 @@ -1 +1 @@ -From 21b1d725e5a6cd38fe28d83c1f6cf00d80643b31 Mon Sep 17 00:00:00 2001 +From 32d8e5279beaacefe5e7cf91f4d265ac87667ce6 Mon Sep 17 00:00:00 2001 @@ -4,0 +5,3 @@ +Cc: Xueming Li + +[ upstream commit 21b1d725e5a6cd38fe28d83c1f6cf00d80643b31 ] @@ -11 +13,0 @@ -Cc: stable@dpdk.org @@ -17,0 +20 @@ + drivers/net/gve/gve_ethdev.h | 2 ++ @@ -19 +22 @@ - 2 files changed, 7 insertions(+), 3 deletions(-) + 3 files changed, 9 insertions(+), 3 deletions(-) @@ -22 +25 @@ -index 3abb37673b..995a6f0553 100644 +index a72dce1a61..5f2593e00e 100644 @@ -25 +28,2 @@ -@@ -1553,6 +1553,7 @@ Vakul Garg +@@ -1489,6 +1489,7 @@ Vadim Suraev + Vakul Garg @@ -27 +30,0 @@ - Vamsi Krishna Atluri @@ -32,0 +36,13 @@ +diff --git a/drivers/net/gve/gve_ethdev.h b/drivers/net/gve/gve_ethdev.h +index 58d8943e71..133860488c 100644 +--- a/drivers/net/gve/gve_ethdev.h ++++ b/drivers/net/gve/gve_ethdev.h +@@ -33,6 +33,8 @@ + RTE_MBUF_F_TX_L4_MASK | \ + RTE_MBUF_F_TX_TCP_SEG) + ++#define GVE_TX_CKSUM_OFFLOAD_MASK_DQO (GVE_TX_CKSUM_OFFLOAD_MASK | RTE_MBUF_F_TX_IP_CKSUM) ++ + /* A list of pages registered with the device during setup and used by a queue + * as buffers + */ @@ -34 +50 @@ -index 1b85557a15..b9d6d01749 100644 +index 97d9c6549b..b9d6d01749 100644 @@ -68 +84 @@ -- if (ol_flags & GVE_TX_CKSUM_OFFLOAD_MASK_DQO) +- if (ol_flags & GVE_TX_CKSUM_OFFLOAD_MASK)