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 7532B42ECF for ; Thu, 20 Jul 2023 17:23:34 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 70CC240685; Thu, 20 Jul 2023 17:23:34 +0200 (CEST) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by mails.dpdk.org (Postfix) with ESMTP id 97E41400D6 for ; Thu, 20 Jul 2023 17:23:33 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1689866613; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=6ytFAxLaE6ooz/lOC5jniRVwX7zUU52H5IELPzDykq0=; b=AXWt+wcqmFFIOePKc8hISzic1Sw/I4GCplOWY5RXYOoOdR9zrRPII2vt7ueO7edQ5hcMDa LVcyn5B/N/s/JhrL9ZZcJUcO5ryS8VYTWZE4OYkK0w4QCHuvwantpgMy32LYT1GDq09Tg3 Ke6y3JW6RMM7HUD5W/l090ALuQ9IcX0= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-653-RyirD1xmOoyP-LqGQ_88Mw-1; Thu, 20 Jul 2023 11:23:07 -0400 X-MC-Unique: RyirD1xmOoyP-LqGQ_88Mw-1 Received: from smtp.corp.redhat.com (int-mx10.intmail.prod.int.rdu2.redhat.com [10.11.54.10]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id A8AB5104D514; Thu, 20 Jul 2023 15:23:01 +0000 (UTC) Received: from rh.redhat.com (unknown [10.39.192.15]) by smtp.corp.redhat.com (Postfix) with ESMTP id 83FB0492C13; Thu, 20 Jul 2023 15:23:00 +0000 (UTC) From: Kevin Traynor To: Ferruh Yigit Cc: Song Jiale , Ali Alnubani , dpdk stable Subject: patch 'app/testpmd: revert primary process polling all queues fix' has been queued to stable release 21.11.5 Date: Thu, 20 Jul 2023 16:19:12 +0100 Message-ID: <20230720151942.262154-121-ktraynor@redhat.com> In-Reply-To: <20230720151942.262154-1-ktraynor@redhat.com> References: <20230720151942.262154-1-ktraynor@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.10 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII"; x-default=true 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 21.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 07/25/23. 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/kevintraynor/dpdk-stable This queued commit can be viewed at: https://github.com/kevintraynor/dpdk-stable/commit/931f667a996370dec053902903eddd2a794b778a Thanks. Kevin --- >From 931f667a996370dec053902903eddd2a794b778a Mon Sep 17 00:00:00 2001 From: Ferruh Yigit Date: Wed, 5 Jul 2023 15:32:06 +0100 Subject: [PATCH] app/testpmd: revert primary process polling all queues fix [ upstream commit d7d802daf80f4a03c77a815da6d47a7b3657ef2c ] For some drivers [1], testpmd forwarding is broken with commit [2]. This is because with [2] testpmd gets queue state from ethdev and forwarding is done only on queues in started state, but some drivers don't update queue status properly, and this breaks forwarding for those drivers. Drivers should be fixed but more time is required to verify drivers again, instead reverting [2] for now to not break drivers. Target is to merge [2] back at the beginning of next release cycle and fix drivers accordingly. [1] Bugzilla ID: 1259 [2] Fixes: 141a520b35f7 ("app/testpmd: fix primary process not polling all queues") Signed-off-by: Ferruh Yigit Tested-by: Song Jiale Tested-by: Ali Alnubani --- app/test-pmd/testpmd.c | 20 ++++---------------- 1 file changed, 4 insertions(+), 16 deletions(-) diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c index dbf6fd1fca..9f4a0e0a78 100644 --- a/app/test-pmd/testpmd.c +++ b/app/test-pmd/testpmd.c @@ -2376,11 +2376,4 @@ update_rx_queue_state(uint16_t port_id, uint16_t queue_id) rx_qinfo.queue_state; } else if (rc == -ENOTSUP) { - /* - * Do not change the rxq state for primary process - * to ensure that the PMDs do not implement - * rte_eth_rx_queue_info_get can forward as before. - */ - if (rte_eal_process_type() == RTE_PROC_PRIMARY) - return; /* * Set the rxq state to RTE_ETH_QUEUE_STATE_STARTED @@ -2408,11 +2401,4 @@ update_tx_queue_state(uint16_t port_id, uint16_t queue_id) tx_qinfo.queue_state; } else if (rc == -ENOTSUP) { - /* - * Do not change the txq state for primary process - * to ensure that the PMDs do not implement - * rte_eth_tx_queue_info_get can forward as before. - */ - if (rte_eal_process_type() == RTE_PROC_PRIMARY) - return; /* * Set the txq state to RTE_ETH_QUEUE_STATE_STARTED @@ -2482,5 +2468,6 @@ start_packet_forwarding(int with_tx_first) if (stream_init != NULL) { - update_queue_state(); + if (rte_eal_process_type() == RTE_PROC_SECONDARY) + update_queue_state(); for (i = 0; i < cur_fwd_config.nb_fwd_streams; i++) stream_init(fwd_streams[i]); @@ -3140,5 +3127,6 @@ start_port(portid_t pid) } - update_queue_state(); + if (rte_eal_process_type() == RTE_PROC_SECONDARY) + update_queue_state(); if (at_least_one_port_successfully_started && !no_link_check) -- 2.41.0 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2023-07-20 16:18:09.542953107 +0100 +++ 0121-app-testpmd-revert-primary-process-polling-all-queue.patch 2023-07-20 16:17:55.124752399 +0100 @@ -1 +1 @@ -From d7d802daf80f4a03c77a815da6d47a7b3657ef2c Mon Sep 17 00:00:00 2001 +From 931f667a996370dec053902903eddd2a794b778a Mon Sep 17 00:00:00 2001 @@ -5,0 +6,2 @@ +[ upstream commit d7d802daf80f4a03c77a815da6d47a7b3657ef2c ] + @@ -23 +24,0 @@ -Cc: stable@dpdk.org @@ -29,3 +30,2 @@ - app/test-pmd/testpmd.c | 20 ++++---------------- - doc/guides/rel_notes/release_23_07.rst | 9 +++++++++ - 2 files changed, 13 insertions(+), 16 deletions(-) + app/test-pmd/testpmd.c | 20 ++++---------------- + 1 file changed, 4 insertions(+), 16 deletions(-) @@ -34 +34 @@ -index 1fc70650e0..c6ad9b18bf 100644 +index dbf6fd1fca..9f4a0e0a78 100644 @@ -37 +37 @@ -@@ -2425,11 +2425,4 @@ update_rx_queue_state(uint16_t port_id, uint16_t queue_id) +@@ -2376,11 +2376,4 @@ update_rx_queue_state(uint16_t port_id, uint16_t queue_id) @@ -49 +49 @@ -@@ -2457,11 +2450,4 @@ update_tx_queue_state(uint16_t port_id, uint16_t queue_id) +@@ -2408,11 +2401,4 @@ update_tx_queue_state(uint16_t port_id, uint16_t queue_id) @@ -61 +61 @@ -@@ -2531,5 +2517,6 @@ start_packet_forwarding(int with_tx_first) +@@ -2482,5 +2468,6 @@ start_packet_forwarding(int with_tx_first) @@ -69 +69 @@ -@@ -3294,5 +3281,6 @@ start_port(portid_t pid) +@@ -3140,5 +3127,6 @@ start_port(portid_t pid) @@ -77,18 +76,0 @@ -diff --git a/doc/guides/rel_notes/release_23_07.rst b/doc/guides/rel_notes/release_23_07.rst -index be8027f71a..234650ac39 100644 ---- a/doc/guides/rel_notes/release_23_07.rst -+++ b/doc/guides/rel_notes/release_23_07.rst -@@ -287,4 +287,13 @@ Known Issues - ======================================================= - -+* **Testpmd is not forwarding on queues individually stopped.** -+ -+ Testpmd forwards packets on started queues. -+ If a queue explicitly stopped, and later port stopped and started again, -+ the status of the previously stopped queue is not updated, -+ so forwarding is not working on those queues. -+ -+ As a workaround start queues back explicitly, instead of port stop/start. -+ - - Tested Platforms