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 0E1ED41D8D for ; Mon, 27 Feb 2023 08:08:04 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 09A09410D3; Mon, 27 Feb 2023 08:08:04 +0100 (CET) Received: from NAM11-CO1-obe.outbound.protection.outlook.com (mail-co1nam11on2049.outbound.protection.outlook.com [40.107.220.49]) by mails.dpdk.org (Postfix) with ESMTP id 6B7F3410D3 for ; Mon, 27 Feb 2023 08:08:02 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=YM1Sdd2qhrAJaTkwNHcNU8th9KLuqlzWyjxtI61jIL3M+xa8mMLe653XXvIV/mE4L5PKTtBm1F85OXiiiJ8xMKM54SFBOgCMmU/fuCCPqoFNBk6m5E3x4H9c4OAI2LTllZKwRvndrsLqNfzOnn1+AyyYSIib10s88Zz2RtLxvWWcRmZnYXH4W/oKIkfAqdEHeJVSo4Sa3+HYyOCRPSNDU5KnLdewOLIu+C3nExeP0a9GngYV0eEt1NwMypHNwR02TKjJdsocFKBGiIvG62DeLo0vhDjsw78KA7yttk5W4769uRXENLcaKyX0DQhwdL2inyluYR/iChqPfZZ1UZiQkQ== 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=Z4xz60m8qZ7fyr9Bx2qdLJnZmJprrOQFU4uMx+mJERw=; b=cxooiU8i90xNSwH0R9BC8SfU19ez2EKhnz+n4HlpoYpa02WZ44X66rBozu+pWaomDrzQ+QX/I9fuX+uXXWyZAyRfGqe6C2cFmq3YN2FEN90+EiN3sMCgJtC4OTD5GKvLclxImAaOns93ZHhc7oo5dOILCvAZ2SvXl6EN1lXn7rwuNfUVSn3NXxqCgbjQDh8Jg6SB8X64Xp5XMbsELinoJpY9CryHKLnP49Pt7ag6nY6cKQ7PO0NrFBp+hIQBlatnIdY3lZpT2Xe0JYujeKyHfESQmoea0GAoDs0QC8suVuG+CG+Td21+KllnqpcY+YT3ywa1B0RjKOqfO4w/qHU1/g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.117.161) smtp.rcpttodomain=broadcom.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 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=Z4xz60m8qZ7fyr9Bx2qdLJnZmJprrOQFU4uMx+mJERw=; b=hEyM0DXZWIzPemFuRbDN5Njh0fYoMPe+6FfwUdb8GBkm/RNH+qmOJs/Dw2L7G1YOPw+3EUCmn689IBSEVh/Uj71eIe0WR1lV/j9TrlG/Nk9//3WflUT8wEtHPgqMLQcKG0JXF0s238QsStFmrRFVSHn1Rk/oddV3FbUCmvjBzQcMbDZyBVjyIMJnwXfnrNZH16KtqvA9PPXHq64RU1t525FPa/g5kkAx6SHNhKsyuaRmSOejHv/7y/I3lR6uiM3Je/lwgNhGZPYWIywe8H5yisVtTbLT3BnZ0lSCzNTp6WDyWYqwww/ckOBb7kZuAUIMpXLztKusVA+bVCzjNuwrFA== Received: from MW4PR03CA0008.namprd03.prod.outlook.com (2603:10b6:303:8f::13) by BN9PR12MB5097.namprd12.prod.outlook.com (2603:10b6:408:136::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6134.29; Mon, 27 Feb 2023 07:08:00 +0000 Received: from CO1NAM11FT112.eop-nam11.prod.protection.outlook.com (2603:10b6:303:8f:cafe::57) by MW4PR03CA0008.outlook.office365.com (2603:10b6:303:8f::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6134.29 via Frontend Transport; Mon, 27 Feb 2023 07:08:00 +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 CO1NAM11FT112.mail.protection.outlook.com (10.13.174.213) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6156.16 via Frontend Transport; Mon, 27 Feb 2023 07:07:59 +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.36; Sun, 26 Feb 2023 23:07:32 -0800 Received: from nvidia.com (10.126.231.37) 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.986.37; Sun, 26 Feb 2023 23:07:30 -0800 From: Xueming Li To: Kalesh AP CC: Ajit Khaparde , dpdk stable Subject: patch 'net/bnxt: fix Tx queue stats after queue stop and start' has been queued to stable release 22.11.2 Date: Mon, 27 Feb 2023 14:59:28 +0800 Message-ID: <20230227070107.15664-60-xuemingl@nvidia.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20230227070107.15664-1-xuemingl@nvidia.com> References: <20230227062349.13764-1-xuemingl@nvidia.com> <20230227070107.15664-1-xuemingl@nvidia.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.126.231.37] 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: CO1NAM11FT112:EE_|BN9PR12MB5097:EE_ X-MS-Office365-Filtering-Correlation-Id: 82cf1e0e-b43c-46de-477e-08db18915c16 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: CCyqzqc3AztyNmSXwM65CX7L2lU/lgHHrZXJpREllI6+2DZa7y1dL69HteYIR6DyNc/x+8gAs8KA82VaXnSJ8MSjOoJPmGwFvK+RcPbBU2m/KDegVnDUEtFe0ZPwTQLqWcT+VVOSlvcvFouij7zdf2c5mK2vE/IfVcfqIanOeeZkE4k0DbzAz5XQJYcGGA1HhcO1532wW7NmrbRuthnit4uJqoUFGRJj+FzT2oW0etPfw5XpcGyNaLOwKDwSrBQBd38tZeGbhzCcDthdrJ2kKxhjmCuh6+dfpYm49mTWeIcOnoOHvyb3bNsLMBPu4OKxH9EWmf4owaVcqVmErWLEXfuc6gdmhI2oYs4REBH4aWMLnkqlpsoeeLAeDMd5mXG+WNmRroVuAVKkmmyFQlMw8BBokAN2ASrHAUUDdb5IW/e0B8VOnkXLgacFsSsfI1vPbuz5MWZ91i3eRI67c8BIM8h9UCOl9xo2Rl0dsqAcUlHo6VBgp5yS7vhVtnVxc63Ienx0xB4pOOOeJs4AL1hDQA3t8I4J9pMLIn19ldIuDf//7mY2BXv4td6hsrrTMX/1METVw8bBAnowBDaMjGmwXY+pgO5KcCd7BeFtqx1FIYC6ttOtQ0uNE0MhVCAlTr4v215gafkAKCgXQ1D2KsHbHtgDbDvHCYvhp81SSA/nVI8T2Kqa9o7Yi7g9LIgGrJooIvN1VfhjuXczYv3I47v6xV4/R8DDVjWL+RERdL1U4lIyVxZo/iQO8izQZXJFNTvqxeAl9YE8NHRH2xoMmyHKWrcHnnNsZ+b+1foy0OZ2TtfHgdhag3IqE20gaBhPRyee 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:(13230025)(4636009)(346002)(39860400002)(396003)(376002)(136003)(451199018)(46966006)(36840700001)(40470700004)(5660300002)(40460700003)(36756003)(86362001)(55016003)(40480700001)(8936002)(426003)(478600001)(2616005)(336012)(82310400005)(47076005)(7696005)(966005)(16526019)(26005)(186003)(6286002)(53546011)(1076003)(70206006)(70586007)(41300700001)(356005)(4326008)(8676002)(6916009)(54906003)(36860700001)(34020700004)(7636003)(82740400003)(316002)(2906002); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 27 Feb 2023 07:07:59.5783 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 82cf1e0e-b43c-46de-477e-08db18915c16 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: CO1NAM11FT112.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN9PR12MB5097 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 22.11.2 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/01/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://git.dpdk.org/dpdk-stable/log/?h=22.11-staging This queued commit can be viewed at: https://git.dpdk.org/dpdk-stable/commit/?h=22.11-staging&id=bc1682ee55ff05be0fdb5915d1e6876a4886bd2e Thanks. Xueming Li --- >From bc1682ee55ff05be0fdb5915d1e6876a4886bd2e Mon Sep 17 00:00:00 2001 From: Kalesh AP Date: Wed, 1 Feb 2023 09:50:12 +0530 Subject: [PATCH] net/bnxt: fix Tx queue stats after queue stop and start Cc: Xueming Li [ upstream commit 9bd8998fe09736a048e367e1ef7543dd8b5dfd2c ] The Tx queue stats are being reported incorrectly due to a workaround for ring counters sometimes being reported as zero. When a queue is stopped and started, the ring counter is reset to zero. The workaround interprets the zero as incorrect, and sets the reported ring count as the previously read value (from before the queue being restared). This shows up as negative counters in testpmd's "show fwd stats" command. The fix clears the prev counter for the queue when the queue is started. Fixes: 219842b9990c ("net/bnxt: workaround spurious zero stats in Thor") Signed-off-by: Kalesh AP Reviewed-by: Ajit Khaparde --- drivers/net/bnxt/bnxt_txr.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/drivers/net/bnxt/bnxt_txr.c b/drivers/net/bnxt/bnxt_txr.c index 67e016775c..21c2217092 100644 --- a/drivers/net/bnxt/bnxt_txr.c +++ b/drivers/net/bnxt/bnxt_txr.c @@ -560,6 +560,12 @@ int bnxt_tx_queue_start(struct rte_eth_dev *dev, uint16_t tx_queue_id) if (rc) return rc; + /* reset the previous stats for the tx_queue since the counters + * will be cleared when the queue is started. + */ + memset(&bp->prev_tx_ring_stats[tx_queue_id], 0, + sizeof(struct bnxt_ring_stats)); + bnxt_free_hwrm_tx_ring(bp, tx_queue_id); rc = bnxt_alloc_hwrm_tx_ring(bp, tx_queue_id); if (rc) -- 2.25.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2023-02-27 14:08:42.873453500 +0800 +++ 0061-net-bnxt-fix-Tx-queue-stats-after-queue-stop-and-sta.patch 2023-02-27 14:08:40.789237000 +0800 @@ -1 +1 @@ -From 9bd8998fe09736a048e367e1ef7543dd8b5dfd2c Mon Sep 17 00:00:00 2001 +From bc1682ee55ff05be0fdb5915d1e6876a4886bd2e Mon Sep 17 00:00:00 2001 @@ -4,0 +5,3 @@ +Cc: Xueming Li + +[ upstream commit 9bd8998fe09736a048e367e1ef7543dd8b5dfd2c ] @@ -15 +17,0 @@ -Cc: stable@dpdk.org