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 E3362A034F for ; Wed, 10 Nov 2021 07:41:37 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id DCAA34014D; Wed, 10 Nov 2021 07:41:37 +0100 (CET) Received: from NAM11-DM6-obe.outbound.protection.outlook.com (mail-dm6nam11on2060.outbound.protection.outlook.com [40.107.223.60]) by mails.dpdk.org (Postfix) with ESMTP id 3D2F540683 for ; Wed, 10 Nov 2021 07:41:36 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=WtKos3jTYXBnQNVla8u+Gtvi7kUIPEBqwvXUHLkyvi9Z99ydpQpEt3mZeoOq/7pWxbH+U4hqgffCnCDb+fR/PV1WspYe3ff1vVhwXiTjoYIWZZJlYIB2FixuMWbwuj/VNL1Fm3Rn7SfnLyRzV8s4nZrjmcTAhB5uWZLs00Je1tJV9KW9qorN/Dr/avlyOLrDFmLD/8UKK8UyJalbcPySNGMkAdSff/TumlVwAYzaWK1xa950S+IqaVObKkIacvHWSIxm7XzJ0IqjlTa9h8YKyUzbjTn/CLthKzoUYNculYgeNA7mlwgCFv6lH/1uLBm6lj6gco1d2sQOQoQzMrbIKA== 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=MDxe/6YdPMO0J/xcuRP05EImpZvRhx+q1cYsvOjH46U=; b=nKNcyba4H8XZzrzbTHLfr6ULXvqrfTfyJzUMehfU24a/nKdaIL/PD1a3GFK2XwEzq0vsC6kYOlKA0nF0kd7977vO/p20gI8uTv75ORtWHVm3pHkH9xPxQ9WWu2bt4LOsoAtjZXhkROUIFXsp/iid0P4fkZdt97dES3/R4h3pV58NBikMbIdQXm7d8Kg2YP2idInBwWHLBPh81Wa8WyHR01XEH9RntIQXXskgGz/13vbWqDo2gviDRPNoreGWbfQD8XyPoD2SATbQc+S5R7pVAblg6w8neGlYgqjq8IFH6oC6iKkV8a4L93OqwjBnFaJ2yU8bM5jz4ny7i6TgAfajIA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.112.34) smtp.rcpttodomain=dpdk.org smtp.mailfrom=nvidia.com; dmarc=pass (p=quarantine sp=quarantine 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=MDxe/6YdPMO0J/xcuRP05EImpZvRhx+q1cYsvOjH46U=; b=szVsmKwMpL5woMd7S4PEqOUYZsSkTeW/LzVKbA5IKOy0ZyXWuUut9oPyiOOSzgnDpiQ3zmus7E9wu1hGDOEeBejG5Z1xMXD+qhA3uYvOZsKqqFD5n2xab0MHN2A0vq4/z/iBBxJLlV9BOoJhUIHtAtMeEFzww3OuARrCk+9rcfkjRjFGqPvYIuKrZgErkjpHaO0kehH5NGdng0tCsyPfMEHUwem5OiqrlOyCs7ribLh9zep25LesKsJG0ThHduCXF6HLbpUpDb7pWx15OAoULckeEtcHrgs1/KiIvGrtlAeWJculFAosL+hMxbBL3cuVGf3lbTEV+rfigMRPmN0hdw== Received: from DS7PR05CA0001.namprd05.prod.outlook.com (2603:10b6:5:3b9::6) by DM6PR12MB4530.namprd12.prod.outlook.com (2603:10b6:5:2aa::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4690.16; Wed, 10 Nov 2021 06:41:35 +0000 Received: from DM6NAM11FT023.eop-nam11.prod.protection.outlook.com (2603:10b6:5:3b9:cafe::77) by DS7PR05CA0001.outlook.office365.com (2603:10b6:5:3b9::6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4690.8 via Frontend Transport; Wed, 10 Nov 2021 06:41:35 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 216.228.112.34) 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.112.34 as permitted sender) receiver=protection.outlook.com; client-ip=216.228.112.34; helo=mail.nvidia.com; Received: from mail.nvidia.com (216.228.112.34) by DM6NAM11FT023.mail.protection.outlook.com (10.13.173.96) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.4669.10 via Frontend Transport; Wed, 10 Nov 2021 06:41:34 +0000 Received: from nvidia.com (172.20.187.5) by HQMAIL107.nvidia.com (172.20.187.13) with Microsoft SMTP Server (TLS) id 15.0.1497.18; Wed, 10 Nov 2021 06:41:31 +0000 From: Xueming Li To: Kevin Traynor CC: Luca Boccassi , dpdk stable Date: Wed, 10 Nov 2021 14:29:27 +0800 Message-ID: <20211110063216.2744012-84-xuemingl@nvidia.com> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20211110063216.2744012-1-xuemingl@nvidia.com> References: <20211110063216.2744012-1-xuemingl@nvidia.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [172.20.187.5] X-ClientProxiedBy: HQMAIL101.nvidia.com (172.20.187.10) To HQMAIL107.nvidia.com (172.20.187.13) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: bf642959-5165-45b7-34ca-08d9a415237b X-MS-TrafficTypeDiagnostic: DM6PR12MB4530: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:10000; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: ARd+Uy/P2XupjNTc5QwqUyNDMCEqzVUWi/+cUSHT0ANgB74BIKL2tHSwoA0E96T89gOoX3p9RorJxsuxhSu/G2giZxQ5fpuXu4IFE6BvvoDvBme4dmers0s1M5EzkACiGS6vf4cdHv1BwjWsOdPqnKn+WYfH2K07feyO5iJHNPtQm5GcqTlEAj7/HNmNtenNu3JdC3alHcoORuo1f2aFEgdYqtq1vnMhlui/gdri44SHYYTaGfCq5q4jcPLTYBhS5xPRBCtzC/kfJ8K09Sa6yUjDZtwaJVsMRC5FZ7t3OFShMa+ODuPZmi5WKewVR6fybtI0R/w9eZjqDa++13fbqEa0ZqeTNfq1iXzLLsCr9ykMs5u+LavRi0gAYicggzM3hkSUyR3cDJRwC2crDzoM4XJBbXBiLQvVLOnJXqRa95GtK83QH2ixtaWN6LWf56BoBJPrVqStRgUh5JdfxgTWQo47nYQhkjmrlTE+QlDRkuVUPrihUeTii2zk1y+YMRfHfke2yUE0fnbDh9QiknLqYZlluiAt4rbQiNazndBja0az0VbZkYqGSN8S/xuJXJZsFWeGMz2UdRvyJvv0/Dg1v31JbtXT9r9/h1BafaD5IqpSDyH8Ia5U30OHem5OyenFDf919Pafsr0yhqDeKcDTXveSdj7nZUvt4+dKNwXshOb0VBacclHq7GYr8EOO5bUvEJyEcAza0WnUy6qy4uqgcKYoY1q/GF3/pt4YAhLcMwu62qYHyCs4XkNZEuz1r/XGQ/BBz/TajfbfrKuhSjRgj4vtq0UtYbJkeD/jVZJLxrZFxKMM++9aWIvns/y0X/Akj0NiI5+BqjF4UT+J4pHlng== X-Forefront-Antispam-Report: CIP:216.228.112.34; CTRY:US; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:mail.nvidia.com; PTR:schybrid03.nvidia.com; CAT:NONE; SFS:(4636009)(36840700001)(46966006)(8936002)(336012)(1076003)(186003)(83380400001)(16526019)(2616005)(508600001)(7696005)(6666004)(70586007)(82310400003)(70206006)(26005)(53546011)(4326008)(5660300002)(2906002)(356005)(47076005)(36860700001)(36756003)(86362001)(6286002)(4001150100001)(7636003)(426003)(6916009)(966005)(8676002)(54906003)(55016002)(316002); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 10 Nov 2021 06:41:34.5021 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: bf642959-5165-45b7-34ca-08d9a415237b X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=43083d15-7273-40c1-b7db-39efd9ccc17a; Ip=[216.228.112.34]; Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: DM6NAM11FT023.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM6PR12MB4530 Subject: [dpdk-stable] patch 'bitrate: fix registration to match API description' has been queued to stable release 20.11.4 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 Sender: "stable" Hi, FYI, your patch has been queued to stable release 20.11.4 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 11/12/21. 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/steevenlee/dpdk This queued commit can be viewed at: https://github.com/steevenlee/dpdk/commit/102d6df14d5608223a6d354896780e9056fafc34 Thanks. Xueming Li --- >From 102d6df14d5608223a6d354896780e9056fafc34 Mon Sep 17 00:00:00 2001 From: Kevin Traynor Date: Fri, 9 Jul 2021 16:19:36 +0100 Subject: [PATCH] bitrate: fix registration to match API description Cc: Xueming Li [ upstream commit 06ae9f0f92cf3bb85549f66dc3dfa11011d7db0f ] rte_stats_bitrate_reg() API states it returns 'Zero on success'. However, the implementation directly returns the return of rte_metrics_reg_names() which may be zero or positive on success, with a positive value also indicating the index. The user of rte_stats_bitrate_reg() should not care about the index as it is stored in the opaque rte_stats_bitrates struct. Change the implementation of rte_stats_bitrate_reg() to match the API description by always returning zero on success. Fixes: 2ad7ba9a6567 ("bitrate: add bitrate statistics library") Signed-off-by: Kevin Traynor --- lib/librte_bitratestats/rte_bitrate.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/librte_bitratestats/rte_bitrate.c b/lib/librte_bitratestats/rte_bitrate.c index 8fd9f47288..e23e38bc94 100644 --- a/lib/librte_bitratestats/rte_bitrate.c +++ b/lib/librte_bitratestats/rte_bitrate.c @@ -55,8 +55,10 @@ rte_stats_bitrate_reg(struct rte_stats_bitrates *bitrate_data) return -EINVAL; return_value = rte_metrics_reg_names(&names[0], RTE_DIM(names)); - if (return_value >= 0) + if (return_value >= 0) { bitrate_data->id_stats_set = return_value; + return 0; + } return return_value; } -- 2.33.0 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2021-11-10 14:17:05.746374041 +0800 +++ 0083-bitrate-fix-registration-to-match-API-description.patch 2021-11-10 14:17:01.844079642 +0800 @@ -1 +1 @@ -From 06ae9f0f92cf3bb85549f66dc3dfa11011d7db0f Mon Sep 17 00:00:00 2001 +From 102d6df14d5608223a6d354896780e9056fafc34 Mon Sep 17 00:00:00 2001 @@ -4,0 +5,3 @@ +Cc: Xueming Li + +[ upstream commit 06ae9f0f92cf3bb85549f66dc3dfa11011d7db0f ] @@ -22 +25 @@ - lib/bitratestats/rte_bitrate.c | 4 +++- + lib/librte_bitratestats/rte_bitrate.c | 4 +++- @@ -25 +28 @@ -diff --git a/lib/bitratestats/rte_bitrate.c b/lib/bitratestats/rte_bitrate.c +diff --git a/lib/librte_bitratestats/rte_bitrate.c b/lib/librte_bitratestats/rte_bitrate.c @@ -27,2 +30,2 @@ ---- a/lib/bitratestats/rte_bitrate.c -+++ b/lib/bitratestats/rte_bitrate.c +--- a/lib/librte_bitratestats/rte_bitrate.c ++++ b/lib/librte_bitratestats/rte_bitrate.c