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 1CFF8A0540 for ; Thu, 7 Jul 2022 09:59:37 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 189204282E; Thu, 7 Jul 2022 09:59:37 +0200 (CEST) Received: from smtp-relay-internal-1.canonical.com (smtp-relay-internal-1.canonical.com [185.125.188.123]) by mails.dpdk.org (Postfix) with ESMTP id 8A4E74282B for ; Thu, 7 Jul 2022 09:59:35 +0200 (CEST) Received: from mail-ej1-f70.google.com (mail-ej1-f70.google.com [209.85.218.70]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-internal-1.canonical.com (Postfix) with ESMTPS id 5B0743F04C for ; Thu, 7 Jul 2022 07:59:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical.com; s=20210705; t=1657180775; bh=scIW1MHXsec/lbc4DTfPzhs1tTMm3prQBsfPv1eSBsQ=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=GeaF4xuGK8FR4x5EmsUyXTPu1HSMfkovGXcS3SxVByg+lolI5UNjezpRZerZ//E0G KFqdml08N8i4Vwdi+dzL0I1iTzK5/3IjMKger4NIls7inqvD97dLJIuzd1hpbpsskx K7SHmYKFQfRPt1li4vNFC9vz0Gi3tAIZHMBDXMqj/sCEaTNG1AJP0vBPkwN/mW/h0S Yqv1znQXJ5RsmIKmjsLx8Kpe5drxWzjfE1kYzR2nmZJJUi3GbVkbW5o2VUZsoENCu7 klKK+9jVr8K43th8ZlXNMXvy1TDgLAgp3g3WAzb3osNiQfxWFAJ8R4EWQ4TK6HzmZg 8nCXElsJWOAnA== Received: by mail-ej1-f70.google.com with SMTP id qb28-20020a1709077e9c00b0072af6ccc1aeso1291953ejc.6 for ; Thu, 07 Jul 2022 00:59:35 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=scIW1MHXsec/lbc4DTfPzhs1tTMm3prQBsfPv1eSBsQ=; b=EepwL1wYpZCjq36yliT5VAclcV3oKzzA8ZWSTw8xKDkAuDaQr+heFabSazOwdV0Kpt ILiykUuy+9gsYLhtHrFrvmx4MFxmTmGYJYI5qzWhoLkvA5fH9ruGlQ6Rv+F//Tj04la8 rFvHrHjv+DfS5w2bdUKQvuaHQxSw6kg978tGoyXdF849kMVFG/Ulxe/IqEvm63S+dX2V bH6tk3F5VMmYaqHttywKCAwKWBc1SOLJ1JZFl1Hcj3hzz3GXzYJ9SJUTpSBBXMAAQAim xvJ3GKaBOsCHi4lXBilXlDnT0PGWoqTAj/Tzj2A9z26wWBboy/wIOj2abfNt/RcPngDR kwQg== X-Gm-Message-State: AJIora8AVyRhPImGc1BDnsE4QJgCiJ/StYqko5hAQtG2gGjsqjO3INDh r4RazUxRpy0EYyWhD640ham23dlp0Kl6XgMCDKGbewVyMA6dm5GjHezkgejlFOKc5OPoXYCmn4q FwT0KO2YwCfjHQNAWKfPEZ9XV X-Received: by 2002:a17:906:5a6c:b0:72a:854b:bf62 with SMTP id my44-20020a1709065a6c00b0072a854bbf62mr32761106ejc.600.1657180775194; Thu, 07 Jul 2022 00:59:35 -0700 (PDT) X-Google-Smtp-Source: AGRyM1uE2+8lfvCpCIcfDOlskmW6/NQDLnhiuI5tokhWUgp36k/0hUpUqeItvpTVI8Y//f+nYAwC9Q== X-Received: by 2002:a17:906:5a6c:b0:72a:854b:bf62 with SMTP id my44-20020a1709065a6c00b0072a854bbf62mr32761081ejc.600.1657180774946; Thu, 07 Jul 2022 00:59:34 -0700 (PDT) Received: from Keschdeichel.fritz.box ([2a02:6d40:3a4f:7b00:c19b:938e:7c97:afe2]) by smtp.gmail.com with ESMTPSA id h17-20020a1709060f5100b00705cdfec71esm18405664ejj.7.2022.07.07.00.59.34 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 07 Jul 2022 00:59:34 -0700 (PDT) From: christian.ehrhardt@canonical.com To: Naga Harish K S V Cc: Jay Jayatheerthan , dpdk stable Subject: patch 'eventdev/eth_tx: fix queue delete' has been queued to stable release 19.11.13 Date: Thu, 7 Jul 2022 09:55:18 +0200 Message-Id: <20220707075522.194223-83-christian.ehrhardt@canonical.com> X-Mailer: git-send-email 2.37.0 In-Reply-To: <20220707075522.194223-1-christian.ehrhardt@canonical.com> References: <20220707075522.194223-1-christian.ehrhardt@canonical.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 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 19.11.13 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 07/09/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/cpaelzer/dpdk-stable-queue This queued commit can be viewed at: https://github.com/cpaelzer/dpdk-stable-queue/commit/288097da2bac2fbec9069bc533f81534e2bc57ef Thanks. Christian Ehrhardt --- >From 288097da2bac2fbec9069bc533f81534e2bc57ef Mon Sep 17 00:00:00 2001 From: Naga Harish K S V Date: Thu, 23 Jun 2022 15:35:11 +0530 Subject: [PATCH] eventdev/eth_tx: fix queue delete [ upstream commit 881d4b4d8587419197815db57b94fc58ee487445 ] Add spinlock protection in queue delete function. This protects the data path while the queue delete operation is in progress. Fixes: a3bbf2e09756 ("eventdev: add eth Tx adapter implementation") Signed-off-by: Naga Harish K S V Acked-by: Jay Jayatheerthan --- lib/librte_eventdev/rte_event_eth_tx_adapter.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/librte_eventdev/rte_event_eth_tx_adapter.c b/lib/librte_eventdev/rte_event_eth_tx_adapter.c index cab4bd0811..e64c7ff2b6 100644 --- a/lib/librte_eventdev/rte_event_eth_tx_adapter.c +++ b/lib/librte_eventdev/rte_event_eth_tx_adapter.c @@ -844,9 +844,10 @@ txa_service_queue_del(uint8_t id, txa = txa_service_id_to_data(id); + rte_spinlock_lock(&txa->tx_lock); tqi = txa_service_queue(txa, port_id, tx_queue_id); if (tqi == NULL || !tqi->added) - return 0; + goto ret_unlock; tb = tqi->tx_buf; tqi->added = 0; @@ -856,6 +857,9 @@ txa_service_queue_del(uint8_t id, txa->txa_ethdev[port_id].nb_queues--; txa_service_queue_array_free(txa, port_id); + +ret_unlock: + rte_spinlock_unlock(&txa->tx_lock); return 0; } -- 2.37.0 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2022-07-07 09:54:14.564442746 +0200 +++ 0083-eventdev-eth_tx-fix-queue-delete.patch 2022-07-07 09:54:11.025824987 +0200 @@ -1 +1 @@ -From 881d4b4d8587419197815db57b94fc58ee487445 Mon Sep 17 00:00:00 2001 +From 288097da2bac2fbec9069bc533f81534e2bc57ef Mon Sep 17 00:00:00 2001 @@ -5,0 +6,2 @@ +[ upstream commit 881d4b4d8587419197815db57b94fc58ee487445 ] + @@ -11 +12,0 @@ -Cc: stable@dpdk.org @@ -16 +17 @@ - lib/eventdev/rte_event_eth_tx_adapter.c | 6 +++++- + lib/librte_eventdev/rte_event_eth_tx_adapter.c | 6 +++++- @@ -19,5 +20,5 @@ -diff --git a/lib/eventdev/rte_event_eth_tx_adapter.c b/lib/eventdev/rte_event_eth_tx_adapter.c -index c700fb7b1f..b4b37f1cae 100644 ---- a/lib/eventdev/rte_event_eth_tx_adapter.c -+++ b/lib/eventdev/rte_event_eth_tx_adapter.c -@@ -891,9 +891,10 @@ txa_service_queue_del(uint8_t id, +diff --git a/lib/librte_eventdev/rte_event_eth_tx_adapter.c b/lib/librte_eventdev/rte_event_eth_tx_adapter.c +index cab4bd0811..e64c7ff2b6 100644 +--- a/lib/librte_eventdev/rte_event_eth_tx_adapter.c ++++ b/lib/librte_eventdev/rte_event_eth_tx_adapter.c +@@ -844,9 +844,10 @@ txa_service_queue_del(uint8_t id, @@ -35 +36 @@ -@@ -903,6 +904,9 @@ txa_service_queue_del(uint8_t id, +@@ -856,6 +857,9 @@ txa_service_queue_del(uint8_t id,