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 ECB1042DD9; Wed, 5 Jul 2023 16:32:45 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 80553406B5; Wed, 5 Jul 2023 16:32:45 +0200 (CEST) Received: from NAM04-MW2-obe.outbound.protection.outlook.com (mail-mw2nam04on2055.outbound.protection.outlook.com [40.107.101.55]) by mails.dpdk.org (Postfix) with ESMTP id 84CBC4021F; Wed, 5 Jul 2023 16:32:44 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=oYuYUv0IqyQ/pduaXWyEkgeyX9lsG2FcYhPoyMQjIyVtIJd5oI4nw0WfRal4olQzj4ZO86DiMQp3qQdJkHcllLNDxziu/4LxzgHvwXujXo9U1nI5UGBS9cNpXvBkNY2yErx3D6m0SMvgJs8Db2m4xGbN74YHrNCKRbPYFbDPJuJJk+PzxA8VtfwYXCAQCcLS/M7u7bFHXa/HgBO/k5PSH+o1jeUoW1RM1QgPA5wEFOnM9arA/an6KaE1byiTpukf4FBPUB8PNKzvgjTPKB7wk2D8+FpOpG3QGL6YtMT0mVVKRoSMYlf5/FRzWhjiBzM/fpu3Hhjx+UJmWoA6UY0GBg== 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=Pfb6MdBLRy9oz31nZ5KPE4pbB9Dtp+qpbfZbx/5F4Vg=; b=d9pFaHdg8aKPaC2MzHMh5QFtandw5zH5qXSGdY92+TbbfC6RoXSJ0Y708PfF8sU8aGjtocaN1zo/SCBAITMKVKB0BFrXyhe+Qp2EjUOcU9LnSId/ZAWwjI86MLDTPHXnF9b/HrAtmE3LHDOwn14M6MXd9Z4xR5LCPO8haJ9uqjpPMlJJ8Wo6EbNbDP+k4V2QDh0M5XlYvlrqrq/7cjIZfcJTL9XC/IeoBX8v+vIc8V2gjmnrrnP75DxDrUY5G4ApE7vFYjiid3iE4073iDSie9zsjmiE6tdbNm2dULAby1dLwLksw6UU66P8M/693MVepcL1FmdwHq65Hik4ev4nsw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=intel.com smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Pfb6MdBLRy9oz31nZ5KPE4pbB9Dtp+qpbfZbx/5F4Vg=; b=HhxYxu627+orSWljTw0qz/nEhjfNWNrpMLSB+R68pHw1c4YofM7KOyQmewkJ8bOHOn63O0zCmyeD/IohO7XZqZa7IooLuk24jb1hvf0WyhdWHwA4wG/AKqmIar3Be0h6JPy6gVs+uOdhfmcd5KmGzkqXrAtoiWeL1Fvg7CYwZF8= Received: from MW4P223CA0006.NAMP223.PROD.OUTLOOK.COM (2603:10b6:303:80::11) by SJ2PR12MB8738.namprd12.prod.outlook.com (2603:10b6:a03:548::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6565.17; Wed, 5 Jul 2023 14:32:35 +0000 Received: from CO1NAM11FT053.eop-nam11.prod.protection.outlook.com (2603:10b6:303:80:cafe::c0) by MW4P223CA0006.outlook.office365.com (2603:10b6:303:80::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6565.21 via Frontend Transport; Wed, 5 Jul 2023 14:32:35 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C Received: from SATLEXMB04.amd.com (165.204.84.17) by CO1NAM11FT053.mail.protection.outlook.com (10.13.175.63) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.6521.45 via Frontend Transport; Wed, 5 Jul 2023 14:32:34 +0000 Received: from telcodpdk.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.23; Wed, 5 Jul 2023 09:32:33 -0500 From: Ferruh Yigit To: Aman Singh , Yuying Zhang , Anatoly Burakov , Jie Hai CC: , Thomas Monjalon , David Marchand , , , Subject: [PATCH] app/testpmd: revert primary process polling all queues fix Date: Wed, 5 Jul 2023 15:32:06 +0100 Message-ID: <20230705143206.268958-1-ferruh.yigit@amd.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.180.168.240] X-ClientProxiedBy: SATLEXMB03.amd.com (10.181.40.144) To SATLEXMB04.amd.com (10.181.40.145) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CO1NAM11FT053:EE_|SJ2PR12MB8738:EE_ X-MS-Office365-Filtering-Correlation-Id: 804b5a4c-11be-4a5e-68f3-08db7d64acb1 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: /dxxbZ8b+Sx9W+vM8PmlGo1DFd4eVJ+QzSPIvtRBQyPNrDwwYizS509p/oL2veCNB9QAZZ58SQe+7dx5nkNmGEyJ1yEMQfUKu7TSVlQj8pZSaOcRhC05t6UyN/eMj3X4v3ytJHcMAUarnDUYPRELWplXWZJlrgtDDQvcmWjOFu0uvF/3y0vU+NqLcj8dDohsQ0ju0D0+18QGNaYDJaDJVekSP+BgtR2z96qGBgTi251hw7V8p8mEmqIWxlvTvXUYTqQVDznBE24hsI+AU+4otykGZjrpA2uE0BoySPc7dE9jDbdHxIO4bOj1BtLjDAkUNyLylSdfllCuLZqvGWJ7m1HUQVcLrmYrLrQBy8ugp6Ba87VHx6IeSRxL8PqYWmnoAaMhJDEVFdM6TshVW/o+bsdhlMjsFcsyQhwyO5uS1qoHS5gsf8UcZhHpd7pZJfeWhBI9ZkQTOuTYqTzcblUE0C7X0boLvbnRQ/JvtWhEnDGk+6E5dzS7ABGj2dGzEXQyAIDDBhQvmRP8Z2CjlHxD7sF/OjU+gdJMkqEsFnIKuSWzjCCtxTAU+gk+md1cZhBg3lMgGtplAzkr5hN2NTXnFxs0IdvRMqUwxjNUVAO2giBxM3tSHNETXg+1InTmM5rXq7kmT36qyslTvJi+QWutOObPZBiXpGzQRMLLVeeHQ1zMJmuWOGEyTczFp5jClN68gswg6W0Cw0v3FjrbsqZfvAYvAcD1FiewCVddTI9tkZxmhGM5kYhKFXgMOVjrrliFezyme1YsjGQwe/r+sHAzEg== X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB04.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230028)(4636009)(396003)(376002)(346002)(136003)(39860400002)(451199021)(36840700001)(46966006)(40470700004)(478600001)(6666004)(7696005)(110136005)(54906003)(186003)(1076003)(26005)(16526019)(70586007)(2906002)(82310400005)(41300700001)(4326008)(316002)(7416002)(44832011)(5660300002)(70206006)(8936002)(8676002)(81166007)(356005)(82740400003)(40460700003)(86362001)(36756003)(47076005)(36860700001)(2616005)(83380400001)(426003)(336012)(40480700001)(36900700001); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 Jul 2023 14:32:34.9160 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 804b5a4c-11be-4a5e-68f3-08db7d64acb1 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CO1NAM11FT053.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: SJ2PR12MB8738 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org 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") Cc: stable@dpdk.org Signed-off-by: Ferruh Yigit --- Cc: haijie1@huawei.com Cc: songx.jiale@intel.com Cc: qiming.yang@intel.com --- app/test-pmd/testpmd.c | 20 ++++---------------- doc/guides/rel_notes/release_23_07.rst | 9 +++++++++ 2 files changed, 13 insertions(+), 16 deletions(-) diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c index 1fc70650e0a4..c6ad9b18bf03 100644 --- a/app/test-pmd/testpmd.c +++ b/app/test-pmd/testpmd.c @@ -2424,13 +2424,6 @@ update_rx_queue_state(uint16_t port_id, uint16_t queue_id) ports[port_id].rxq[queue_id].state = 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 * to ensure that the PMDs do not implement @@ -2456,13 +2449,6 @@ update_tx_queue_state(uint16_t port_id, uint16_t queue_id) ports[port_id].txq[queue_id].state = 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 * to ensure that the PMDs do not implement @@ -2530,7 +2516,8 @@ start_packet_forwarding(int with_tx_first) return; 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]); } @@ -3293,7 +3280,8 @@ start_port(portid_t pid) pl[cfg_pi++] = pi; } - update_queue_state(); + if (rte_eal_process_type() == RTE_PROC_SECONDARY) + update_queue_state(); if (at_least_one_port_successfully_started && !no_link_check) check_all_ports_link_status(RTE_PORT_ALL); diff --git a/doc/guides/rel_notes/release_23_07.rst b/doc/guides/rel_notes/release_23_07.rst index 7b1c31469fa5..46b3d915c6e4 100644 --- a/doc/guides/rel_notes/release_23_07.rst +++ b/doc/guides/rel_notes/release_23_07.rst @@ -280,6 +280,15 @@ Known Issues Also, make sure to start the actual text at the margin. ======================================================= +* **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 ---------------- -- 2.34.1