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 8E9CE43B7D for ; Tue, 5 Mar 2024 10:57:24 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 88C284026B; Tue, 5 Mar 2024 10:57:24 +0100 (CET) Received: from NAM10-MW2-obe.outbound.protection.outlook.com (mail-mw2nam10on2081.outbound.protection.outlook.com [40.107.94.81]) by mails.dpdk.org (Postfix) with ESMTP id 4ACF84014F for ; Tue, 5 Mar 2024 10:57:22 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=hdQcBExselYZ6p+cX/6dyQF7ljaSa085bIDXdXkjPc00f+dCPiu+CocsHW1gd3F19tS9tzm98ysBXB1zHfgsUiilj9rNF0lXjtCUtGdjQEequPEopv5aVQW13KN147eHFIpCqhh0jFGC2mx5EZ0s6l6s8hcW4t7ZX7zM7EvXZtpvBzT3hGm2eBAj4uK45UPQwOHN7hwzwVvWLQrFd58ZcHJkK72UfPW3dLRPPHXHGEPxrSppGSbI3ILVy9e+6tF8Xaq+m3YDeZZPLSRnhJK5m+iWLq/6Cdkt2uRuOh9fKglA0W6Pt+X6uju4VXfZJokwpjlCTi47O0+R53WvDDyJLg== 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=xXdDHjRNvMvQZERNXKxdBGk29d+B46OROtSVOGIgv9U=; b=jUJPCq718kNPD3EpQr6TWrLwC42pvQYh/yQn4Rx5m1o/U7f/usI0e6Rwjn4yf5snHF6OXZ+cnjZ+Tp595eohvONUKBNdeV7IN7Ei/QTwCS9HTSRqE4IOBVDz64/OnA/VE0NkcJvpPmntEH5JBRMGXGjjj0YaDm66ntnMlyfwaoZHmBWjz7s8lVDvf5dQBhb8MrqWWSczzYiptVhzjc+HZTWcp2LNtmbyqtgSeW4gORTyLfvk5mwFG49yaktNkCPnUgY/0jCv209ViujwVzi5aKLtJGGBnOgt28Ut4oMsKQnBN1XgrJWfEpOSnQiCliGW9LrvKsEqR4oqPPLAXeOPWQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.117.161) smtp.rcpttodomain=amd.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=xXdDHjRNvMvQZERNXKxdBGk29d+B46OROtSVOGIgv9U=; b=sp3s6mcm7mpn3gfUoow3TTzNaIGVOkmPiUdFJVMzknsqrcxvkAz77HuHaCYIdSPMTK/6PcY0Bel+pMBhv+K3GZpYA2StBmqqSZ+Gqif+9V4038azYZ/xVpn45orufXYq+amRYnUtu9GniZzse82a4c4kDJYhyV9P+8bU6Yb63aZkjxCh9CstEtSk0ZCp3dnqzSNC8jT9i+f57LIxJRiP2tw5bD38ly4Jh5izMP3TX1GazzHljbM0meMzZCOb0o55kpW40xNBi0Oxa29IMNvfQrbxiRpTSkkyewVEx361EUVVobPSJw2EEkk0Gg5UprKnJxFwG2fwlUayRxMWhJYQ+w== Received: from SJ0PR13CA0127.namprd13.prod.outlook.com (2603:10b6:a03:2c6::12) by PH7PR12MB8107.namprd12.prod.outlook.com (2603:10b6:510:2bb::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7339.39; Tue, 5 Mar 2024 09:57:19 +0000 Received: from SJ5PEPF000001D6.namprd05.prod.outlook.com (2603:10b6:a03:2c6:cafe::2c) by SJ0PR13CA0127.outlook.office365.com (2603:10b6:a03:2c6::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7362.23 via Frontend Transport; Tue, 5 Mar 2024 09:57:19 +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 SJ5PEPF000001D6.mail.protection.outlook.com (10.167.242.58) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7362.11 via Frontend Transport; Tue, 5 Mar 2024 09:57:19 +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.986.41; Tue, 5 Mar 2024 01:57:08 -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.1258.12; Tue, 5 Mar 2024 01:57:07 -0800 From: Xueming Li To: Neel Patel CC: Andrew Boyer , dpdk stable Subject: patch 'net/ionic: fix missing volatile type for cqe pointers' has been queued to stable release 23.11.1 Date: Tue, 5 Mar 2024 17:47:22 +0800 Message-ID: <20240305094757.439387-102-xuemingl@nvidia.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240305094757.439387-1-xuemingl@nvidia.com> References: <20240305094757.439387-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: 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: SJ5PEPF000001D6:EE_|PH7PR12MB8107:EE_ X-MS-Office365-Filtering-Correlation-Id: 6dc918de-2d4a-465d-a167-08dc3cfaa58a X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: BTsZc27LeqAD8dI5Nhr/fkjUGfMRAb0fZwP9qsqBiUIDOg/WBp/NDXz4BFAiJhdogNs/a9I3UltnrIr1phhmmms9/JvAUJTTmnGwXJpK3rbBY4QetFf9P4hiEVCGEVmMT+GhK4meX5oTFwT/o23Qcgnx1H3U4MGE77g6cFHrcuiTeEZQyaI3Q515mR9sBZxexh77bJCZ4RQMwLFp0x1hVW+iVSGwlHdw96xQxbogZMFV+PI4Zulj0hcj3Wstiu0XupQGOrK9m35WAzFttuTKur96cC6fx7zovdCgPn+hllMQPJ50N3qR7Sbay0hAeMmQaZGu49Uja/EQs+lJRIHTLUZBjqTFFRt4yNrh+paYBg5zK/R9EaUsioLa5in568uo+yZ3fvP2xSW4G5HbUhNdYAhuI5qUA0uLIg873u59b4s77LsUpxKNI2NZoJSNGZ963vlhAPemlQYj1rgBLNVYDjjEptLkIp8mdR0HnjmhLJyO6H1SH9TUeREjwSYWnqsIrbXBB6uMQI/kZHnj0c9+rDZxXkdPVlO//aW0kRGMsKBVu851rgNC5xozELwY05iwl6Qe1u4XKokmBV2WNbUfmEzpYNRdyoxWXcnxkTz5LZrqX+IUvHevBxGYjvu/oxeAkkjirgsby01wSRoXw0pZEXOJvnmjslkc7qWPeaIf+IMfOqbc34FTxD6aE6Pb7SoXtgiyb2o/wbT/MbOuc6fDOnnqXpAwAO2/6BI7OHvA0sdLuIFOadtzglXaKCDC/aLy 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:(13230031)(82310400014)(376005)(36860700004); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 Mar 2024 09:57:19.6271 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 6dc918de-2d4a-465d-a167-08dc3cfaa58a 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: SJ5PEPF000001D6.namprd05.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: PH7PR12MB8107 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.1 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 03/31/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=2ea5bde55737cf3bbb8e6767267261e686e6f85d Thanks. Xueming Li --- >From 2ea5bde55737cf3bbb8e6767267261e686e6f85d Mon Sep 17 00:00:00 2001 From: Neel Patel Date: Tue, 6 Feb 2024 19:13:08 -0800 Subject: [PATCH] net/ionic: fix missing volatile type for cqe pointers Cc: Xueming Li [ upstream commit 463ad260d35ee5934ab206d392a1a3e08b5506d0 ] This memory may be changed by the hardware, so the volatile keyword is required for correctness. Fixes: e86a6fcc7cf3 ("net/ionic: add optimized non-scattered Rx/Tx") Signed-off-by: Andrew Boyer Signed-off-by: Neel Patel --- drivers/net/ionic/ionic_rxtx.c | 4 ++-- drivers/net/ionic/ionic_rxtx_sg.c | 8 +++++--- drivers/net/ionic/ionic_rxtx_simple.c | 8 +++++--- 3 files changed, 12 insertions(+), 8 deletions(-) diff --git a/drivers/net/ionic/ionic_rxtx.c b/drivers/net/ionic/ionic_rxtx.c index b9e73b4871..2f1ca986b3 100644 --- a/drivers/net/ionic/ionic_rxtx.c +++ b/drivers/net/ionic/ionic_rxtx.c @@ -752,7 +752,7 @@ ionic_dev_rx_descriptor_status(void *rx_queue, uint16_t offset) { struct ionic_rx_qcq *rxq = rx_queue; struct ionic_qcq *qcq = &rxq->qcq; - struct ionic_rxq_comp *cq_desc; + volatile struct ionic_rxq_comp *cq_desc; uint16_t mask, head, tail, pos; bool done_color; @@ -791,7 +791,7 @@ ionic_dev_tx_descriptor_status(void *tx_queue, uint16_t offset) { struct ionic_tx_qcq *txq = tx_queue; struct ionic_qcq *qcq = &txq->qcq; - struct ionic_txq_comp *cq_desc; + volatile struct ionic_txq_comp *cq_desc; uint16_t mask, head, tail, pos, cq_pos; bool done_color; diff --git a/drivers/net/ionic/ionic_rxtx_sg.c b/drivers/net/ionic/ionic_rxtx_sg.c index ab8e56e91c..241b6f8587 100644 --- a/drivers/net/ionic/ionic_rxtx_sg.c +++ b/drivers/net/ionic/ionic_rxtx_sg.c @@ -27,7 +27,8 @@ ionic_tx_flush_sg(struct ionic_tx_qcq *txq) struct ionic_cq *cq = &txq->qcq.cq; struct ionic_queue *q = &txq->qcq.q; struct rte_mbuf *txm; - struct ionic_txq_comp *cq_desc, *cq_desc_base = cq->base; + struct ionic_txq_comp *cq_desc_base = cq->base; + volatile struct ionic_txq_comp *cq_desc; void **info; uint32_t i; @@ -252,7 +253,7 @@ ionic_xmit_pkts_sg(void *tx_queue, struct rte_mbuf **tx_pkts, */ static __rte_always_inline void ionic_rx_clean_one_sg(struct ionic_rx_qcq *rxq, - struct ionic_rxq_comp *cq_desc, + volatile struct ionic_rxq_comp *cq_desc, struct ionic_rx_service *rx_svc) { struct ionic_queue *q = &rxq->qcq.q; @@ -438,7 +439,8 @@ ionic_rxq_service_sg(struct ionic_rx_qcq *rxq, uint32_t work_to_do, struct ionic_cq *cq = &rxq->qcq.cq; struct ionic_queue *q = &rxq->qcq.q; struct ionic_rxq_desc *q_desc_base = q->base; - struct ionic_rxq_comp *cq_desc, *cq_desc_base = cq->base; + struct ionic_rxq_comp *cq_desc_base = cq->base; + volatile struct ionic_rxq_comp *cq_desc; uint32_t work_done = 0; uint64_t then, now, hz, delta; diff --git a/drivers/net/ionic/ionic_rxtx_simple.c b/drivers/net/ionic/ionic_rxtx_simple.c index 5f81856256..0992177afc 100644 --- a/drivers/net/ionic/ionic_rxtx_simple.c +++ b/drivers/net/ionic/ionic_rxtx_simple.c @@ -27,7 +27,8 @@ ionic_tx_flush(struct ionic_tx_qcq *txq) struct ionic_cq *cq = &txq->qcq.cq; struct ionic_queue *q = &txq->qcq.q; struct rte_mbuf *txm; - struct ionic_txq_comp *cq_desc, *cq_desc_base = cq->base; + struct ionic_txq_comp *cq_desc_base = cq->base; + volatile struct ionic_txq_comp *cq_desc; void **info; cq_desc = &cq_desc_base[cq->tail_idx]; @@ -225,7 +226,7 @@ ionic_xmit_pkts(void *tx_queue, struct rte_mbuf **tx_pkts, */ static __rte_always_inline void ionic_rx_clean_one(struct ionic_rx_qcq *rxq, - struct ionic_rxq_comp *cq_desc, + volatile struct ionic_rxq_comp *cq_desc, struct ionic_rx_service *rx_svc) { struct ionic_queue *q = &rxq->qcq.q; @@ -359,7 +360,8 @@ ionic_rxq_service(struct ionic_rx_qcq *rxq, uint32_t work_to_do, struct ionic_cq *cq = &rxq->qcq.cq; struct ionic_queue *q = &rxq->qcq.q; struct ionic_rxq_desc *q_desc_base = q->base; - struct ionic_rxq_comp *cq_desc, *cq_desc_base = cq->base; + struct ionic_rxq_comp *cq_desc_base = cq->base; + volatile struct ionic_rxq_comp *cq_desc; uint32_t work_done = 0; uint64_t then, now, hz, delta; -- 2.34.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2024-03-05 17:39:34.026525001 +0800 +++ 0101-net-ionic-fix-missing-volatile-type-for-cqe-pointers.patch 2024-03-05 17:39:30.883566497 +0800 @@ -1 +1 @@ -From 463ad260d35ee5934ab206d392a1a3e08b5506d0 Mon Sep 17 00:00:00 2001 +From 2ea5bde55737cf3bbb8e6767267261e686e6f85d Mon Sep 17 00:00:00 2001 @@ -4,0 +5,3 @@ +Cc: Xueming Li + +[ upstream commit 463ad260d35ee5934ab206d392a1a3e08b5506d0 ] @@ -10 +12,0 @@ -Cc: stable@dpdk.org @@ -21 +23 @@ -index e7a0e16ae1..8a9c5ae191 100644 +index b9e73b4871..2f1ca986b3 100644 @@ -24 +26 @@ -@@ -756,7 +756,7 @@ ionic_dev_rx_descriptor_status(void *rx_queue, uint16_t offset) +@@ -752,7 +752,7 @@ ionic_dev_rx_descriptor_status(void *rx_queue, uint16_t offset) @@ -33 +35 @@ -@@ -795,7 +795,7 @@ ionic_dev_tx_descriptor_status(void *tx_queue, uint16_t offset) +@@ -791,7 +791,7 @@ ionic_dev_tx_descriptor_status(void *tx_queue, uint16_t offset) @@ -43 +45 @@ -index 6c028a698c..1392342463 100644 +index ab8e56e91c..241b6f8587 100644 @@ -46 +48,2 @@ -@@ -28,7 +28,8 @@ ionic_tx_flush_sg(struct ionic_tx_qcq *txq) +@@ -27,7 +27,8 @@ ionic_tx_flush_sg(struct ionic_tx_qcq *txq) + struct ionic_cq *cq = &txq->qcq.cq; @@ -48 +50,0 @@ - struct ionic_tx_stats *stats = &txq->stats; @@ -56 +58 @@ -@@ -254,7 +255,7 @@ ionic_xmit_pkts_sg(void *tx_queue, struct rte_mbuf **tx_pkts, +@@ -252,7 +253,7 @@ ionic_xmit_pkts_sg(void *tx_queue, struct rte_mbuf **tx_pkts, @@ -65 +67 @@ -@@ -440,7 +441,8 @@ ionic_rxq_service_sg(struct ionic_rx_qcq *rxq, uint32_t work_to_do, +@@ -438,7 +439,8 @@ ionic_rxq_service_sg(struct ionic_rx_qcq *rxq, uint32_t work_to_do, @@ -76 +78 @@ -index 5969287b66..00152c885a 100644 +index 5f81856256..0992177afc 100644 @@ -79 +81,2 @@ -@@ -28,7 +28,8 @@ ionic_tx_flush(struct ionic_tx_qcq *txq) +@@ -27,7 +27,8 @@ ionic_tx_flush(struct ionic_tx_qcq *txq) + struct ionic_cq *cq = &txq->qcq.cq; @@ -81 +83,0 @@ - struct ionic_tx_stats *stats = &txq->stats; @@ -89 +91 @@ -@@ -227,7 +228,7 @@ ionic_xmit_pkts(void *tx_queue, struct rte_mbuf **tx_pkts, +@@ -225,7 +226,7 @@ ionic_xmit_pkts(void *tx_queue, struct rte_mbuf **tx_pkts, @@ -98 +100 @@ -@@ -361,7 +362,8 @@ ionic_rxq_service(struct ionic_rx_qcq *rxq, uint32_t work_to_do, +@@ -359,7 +360,8 @@ ionic_rxq_service(struct ionic_rx_qcq *rxq, uint32_t work_to_do,