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 7231A457A1 for ; Mon, 12 Aug 2024 14:56:28 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 697E4402C3; Mon, 12 Aug 2024 14:56:28 +0200 (CEST) Received: from NAM12-BN8-obe.outbound.protection.outlook.com (mail-bn8nam12on2084.outbound.protection.outlook.com [40.107.237.84]) by mails.dpdk.org (Postfix) with ESMTP id 0A27F4029C for ; Mon, 12 Aug 2024 14:56:27 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=SBknMRKk0iF31GNFpShgC++nwCZQPIEUioDyncyGnChhcXDNgGk3f6gTC16PBofyyePhV6y+ipTcZmT40xl5gcoF8rb4G7wmm1FK7JNth9m7o9+QmbEHmTUlnIzcutQvy4pZtyvo/kceYViT8aAs53XI+oH4rMzNdc0YNIJMVdyr03ihAn0iW6qyuEQdvf51PYZ+4k88bFnKC9bRUhyOt0QlXSjQ/eUfiiH9+ufT5XoXUD7/7STurguIGWfLOkz24jO2KlucvUUzZGyuY7s+YKdICSQ0jbe+JR4WWIMbsfWh4+37oTue7pQQmgtLEpxc4bw/eUzU/Mi2dtUG2D0bMA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; 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=F0jewpb6tmsqH9mLNsfo6JYgcnzCDY/aeuinBKr4wlc=; b=EjIA5G77guEb4t3nmxbdzBE+uF0rnwo0ToahQmywyz6/UQSVulDT4bbiQvdTsdCJplMJE4STJ48eM0Q/zuYpvkhbkc6XI5rJAV3e0H7N/3hHeKvS4IlmHAkdSFCMB3Evi2K4WpHtqg5VHVvsP/SPUcCi5EVqAqc+EPVKiYgsEcmFM381VUvqD/62AMCMpE28lLDfNsO6zM8P8B1G5R4XYB9O7uc+AXzJwU7SYh6sFxRt/J2V0Dyp++Ys9crOx8UVhuQIoGRjXeO+60n5bh5RS7p40wBCpZ5fzTyPXSCbz90Wmbi07ikpkxILAsZH7UON75nUdoR/q2T/cnXfgtK8wg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.117.160) smtp.rcpttodomain=intel.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 (0) 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=F0jewpb6tmsqH9mLNsfo6JYgcnzCDY/aeuinBKr4wlc=; b=tFr6HF/qrMiOsvGnjTE4SFu4jv8rUoOBwDnxKSWG1mge2v8ZW/1IdA4EE6z/2W0Xb/dFdCwWFRx8JJluIpgk0/va6GJjcx66qVZarNfaoVUt2Ido2styFsooDMJYapdf2RCID7PD1wX0FgNbx/RhMPqDLNLJmF47zeOBcb9tb8caikbkJoInHgi4jNcILFoM2PxxnUv/F15WtHoC5+xBSBd80fSzxxV21qn9WTFm1kSrB9k33gURc19ha44neTlJUg2EQS/lgcwAiZFRjqLgKe2Jf6F9TAoKjRqsesQOux2pvPmXcRsAihyNRS0oqagmxAgHCRoKmt2zSK2FRiBDcA== Received: from DM6PR08CA0045.namprd08.prod.outlook.com (2603:10b6:5:1e0::19) by SJ2PR12MB9114.namprd12.prod.outlook.com (2603:10b6:a03:567::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7849.20; Mon, 12 Aug 2024 12:56:24 +0000 Received: from DS1PEPF00017094.namprd03.prod.outlook.com (2603:10b6:5:1e0:cafe::d7) by DM6PR08CA0045.outlook.office365.com (2603:10b6:5:1e0::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7849.22 via Frontend Transport; Mon, 12 Aug 2024 12:56:23 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 216.228.117.160) 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.160 as permitted sender) receiver=protection.outlook.com; client-ip=216.228.117.160; helo=mail.nvidia.com; pr=C Received: from mail.nvidia.com (216.228.117.160) by DS1PEPF00017094.mail.protection.outlook.com (10.167.17.137) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7828.19 via Frontend Transport; Mon, 12 Aug 2024 12:56:23 +0000 Received: from rnnvmail201.nvidia.com (10.129.68.8) by mail.nvidia.com (10.129.200.66) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1544.4; Mon, 12 Aug 2024 05:56:13 -0700 Received: from nvidia.com (10.126.231.35) 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.1544.4; Mon, 12 Aug 2024 05:56:11 -0700 From: Xueming Li To: Chinh Cao CC: , Ian Stokes , Bruce Richardson , dpdk stable Subject: patch 'net/ice/base: fix return type of bitmap hamming weight' has been queued to stable release 23.11.2 Date: Mon, 12 Aug 2024 20:48:54 +0800 Message-ID: <20240812125035.389667-58-xuemingl@nvidia.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240812125035.389667-1-xuemingl@nvidia.com> References: <20240712110153.309690-23-xuemingl@nvidia.com> <20240812125035.389667-1-xuemingl@nvidia.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.126.231.35] X-ClientProxiedBy: rnnvmail201.nvidia.com (10.129.68.8) To rnnvmail201.nvidia.com (10.129.68.8) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DS1PEPF00017094:EE_|SJ2PR12MB9114:EE_ X-MS-Office365-Filtering-Correlation-Id: dc2f4e1a-e8b0-4893-39be-08dcbace2baa X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|36860700013|376014|82310400026|1800799024; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?VyfUT0v1O0Lp8OKhxmi57hVsj3AVIqBaNshuUO5ls4NySEdGZf8B5ZRsHz43?= =?us-ascii?Q?A6NfoI2DmPYnKwR9Q2D683zd62tb4lgHOJRrO2lSEmyKIZ6kSXNgEgEYoG5n?= =?us-ascii?Q?pd13rduZmrD1IAn7CfkbRwpdKMy801teMqApeVRdmHQksGHHht/QkOEuQn3k?= =?us-ascii?Q?hpF+gNdZ5FO4kVeaB9pYw/dv494ETlf3Hv4ReRMRFMlD60Gr4o8GOEvMZjE3?= =?us-ascii?Q?wNShxtGF5zLbx/wRp1KheGwty+DthfIV0L/ph746DMHBF8jBa7zE9qhPEVUj?= =?us-ascii?Q?a/hoi2OThRoj29rQaaQjkJpT3nqaCV7++wuyZku5eix3pH7+t+bW/QRa9rqE?= =?us-ascii?Q?yilRqGPb1otJ4XwGSfkOOte3sRAgYgYfZtWCaujknreBFlO1micSkNjaWlum?= =?us-ascii?Q?kCDfXnyIQRSpGWR8DyQLW01LGQOuPED0MFN6ftdm8C7qcWh9YdjddkMm8caN?= =?us-ascii?Q?3mn2hTnjp6zwuPufbGfi/kkOOAQxVTDcpCFCcNC4NAYHyq7o8uMPBIihYi8R?= =?us-ascii?Q?VcKLTM6U3GaqpyIfDaIoFS3MmoI6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JJrWr+J6L1ojXo8yu38zGZxh40?= X-Forefront-Antispam-Report: CIP:216.228.117.160; CTRY:US; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:mail.nvidia.com; PTR:dc6edge1.nvidia.com; CAT:NONE; SFS:(13230040)(36860700013)(376014)(82310400026)(1800799024); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 12 Aug 2024 12:56:23.7435 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: dc2f4e1a-e8b0-4893-39be-08dcbace2baa 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.160]; Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: DS1PEPF00017094.namprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: SJ2PR12MB9114 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 23.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 08/14/24. 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=23.11-staging This queued commit can be viewed at: https://git.dpdk.org/dpdk-stable/commit/?h=23.11-staging&id=fddfbdbf498321fff0dcf34a0a097ff548eac8ca Thanks. Xueming Li --- >From fddfbdbf498321fff0dcf34a0a097ff548eac8ca Mon Sep 17 00:00:00 2001 From: Chinh Cao Date: Wed, 26 Jun 2024 12:41:11 +0100 Subject: [PATCH] net/ice/base: fix return type of bitmap hamming weight Cc: Xueming Li [ upstream commit 509c55f699d1e13f38abaaf85df7bd9b585f5b87 ] "count" is the returned value, and in this function, value of "count" and "bit" are the same, so there is no reason why these values should be declared as different types, and for returned value data type to be different. Fixes: 6d288fa5f72b ("net/ice/base: introduce and use bitmap hamming weight API") Signed-off-by: Chinh Cao Signed-off-by: Ian Stokes Acked-by: Bruce Richardson --- drivers/net/ice/base/ice_bitops.h | 4 ++-- drivers/net/ice/base/ice_switch.c | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/drivers/net/ice/base/ice_bitops.h b/drivers/net/ice/base/ice_bitops.h index 3b71c1b7f5..5c17bcb674 100644 --- a/drivers/net/ice/base/ice_bitops.h +++ b/drivers/net/ice/base/ice_bitops.h @@ -418,10 +418,10 @@ ice_bitmap_set(ice_bitmap_t *dst, u16 pos, u16 num_bits) * Note that this function assumes it is operating on a bitmap declared using * ice_declare_bitmap. */ -static inline int +static inline u16 ice_bitmap_hweight(ice_bitmap_t *bm, u16 size) { - int count = 0; + u16 count = 0; u16 bit = 0; while (size > (bit = ice_find_next_bit(bm, size, bit))) { diff --git a/drivers/net/ice/base/ice_switch.c b/drivers/net/ice/base/ice_switch.c index f7fcc3a8d4..07ebc624f5 100644 --- a/drivers/net/ice/base/ice_switch.c +++ b/drivers/net/ice/base/ice_switch.c @@ -7390,7 +7390,7 @@ ice_find_free_recp_res_idx(struct ice_hw *hw, const ice_bitmap_t *profiles, ice_xor_bitmap(free_idx, used_idx, possible_idx, ICE_MAX_FV_WORDS); /* return number of free indexes */ - return (u16)ice_bitmap_hweight(free_idx, ICE_MAX_FV_WORDS); + return ice_bitmap_hweight(free_idx, ICE_MAX_FV_WORDS); } static void ice_set_recipe_index(unsigned long idx, u8 *bitmap) @@ -8101,6 +8101,7 @@ ice_add_adv_recipe(struct ice_hw *hw, struct ice_adv_lkup_elem *lkups, enum ice_status status = ICE_SUCCESS; struct ice_sw_recipe *rm; u8 i; + u16 cnt; if (!ice_is_prof_rule(rinfo->tun_type) && !lkups_cnt) return ICE_ERR_PARAM; -- 2.34.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2024-08-12 20:44:04.456166345 +0800 +++ 0057-net-ice-base-fix-return-type-of-bitmap-hamming-weigh.patch 2024-08-12 20:44:02.105069296 +0800 @@ -1 +1 @@ -From 509c55f699d1e13f38abaaf85df7bd9b585f5b87 Mon Sep 17 00:00:00 2001 +From fddfbdbf498321fff0dcf34a0a097ff548eac8ca Mon Sep 17 00:00:00 2001 @@ -4,0 +5,3 @@ +Cc: Xueming Li + +[ upstream commit 509c55f699d1e13f38abaaf85df7bd9b585f5b87 ] @@ -12 +14,0 @@ -Cc: stable@dpdk.org @@ -40 +42 @@ -index 711a6cfbbe..fa5bd94c58 100644 +index f7fcc3a8d4..07ebc624f5 100644 @@ -43 +45 @@ -@@ -7467,7 +7467,7 @@ ice_find_free_recp_res_idx(struct ice_hw *hw, const ice_bitmap_t *profiles, +@@ -7390,7 +7390,7 @@ ice_find_free_recp_res_idx(struct ice_hw *hw, const ice_bitmap_t *profiles, @@ -52 +54,2 @@ -@@ -8178,6 +8178,7 @@ ice_add_adv_recipe(struct ice_hw *hw, struct ice_adv_lkup_elem *lkups, +@@ -8101,6 +8101,7 @@ ice_add_adv_recipe(struct ice_hw *hw, struct ice_adv_lkup_elem *lkups, + enum ice_status status = ICE_SUCCESS; @@ -55 +57,0 @@ - int status = ICE_SUCCESS;