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 88610A0C56; Mon, 23 Aug 2021 10:16:06 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 0E05F40687; Mon, 23 Aug 2021 10:16:06 +0200 (CEST) Received: from NAM12-BN8-obe.outbound.protection.outlook.com (mail-bn8nam12on2053.outbound.protection.outlook.com [40.107.237.53]) by mails.dpdk.org (Postfix) with ESMTP id 1189940143 for ; Mon, 23 Aug 2021 10:16:04 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ddS9XhXgz0nkMdOD7cV4MJYoIhgHjsbWMuzeWwkO1iY+d0nXci12sEdC5bo5LcFhXbWDDxd5hCElQUKNVd3e8t/ToFQS955QSskNiK4DTnZiyY9gHZStU1rV/WjXt5+ewxy6gYqaHd2S9Pj8bA8EnQBPaaUfm5/3Q+l+y/GvJiU6dyEXCa1S85DhvS44oDwjCE8wtsQIztXgcTJaObGfFK6ISMuw+TqX0gY93OKPSXCIOHs7jyIbA9bHrbJe4IQLJUhga9JdC470DjVfb4v46LejANcCA3lNaNavdi8VxUhRwBKJDb4jdLROeW00e/vP6H9bWoUS/DDZKjty0Z2kFA== 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-SenderADCheck; bh=ekEJXF+7RyQc31WM2r46D9GymmS9zeP1l78DrqKbFb0=; b=kPWDw91ta9YdYCu3vvUdXti6jQTALOqhgdDRzmUXGnkawO7oCK1uEzr8hk8ATojhcU2sqdfUYP0iMkP1ILGvPjOPfIeiX6iQEbRS+Wg7W/sGF6ap/2xpBQ7zePUOvQ3uNnjZ+xhEYSeBNNMVdsbDHINEf4k0Jjei46Ua6c//uzgPm5k2bSWUgRgh8/blxaDbZi9ibdmI5GyXyEVJa1qwnF1/xWLwbZGFTWkJ8OtzpJrV+Wqvm/wKUyHvd7o3YR/cPAJ6L/YQqmFW97VtINFqeK+keBXJpl+7P1QPL3UNkDvMv1lLlSKLLsE+x8gBWWG+Tf5gVOhY+//AOPIAYFelNA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.112.34) smtp.rcpttodomain=intel.com smtp.mailfrom=nvidia.com; dmarc=pass (p=quarantine sp=none 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=ekEJXF+7RyQc31WM2r46D9GymmS9zeP1l78DrqKbFb0=; b=JBKrF56JDibOdyl1eUryvmOzQoKEvENv6fxvR3FrIe5NHhP3BkXnLg8W7gPhc4dmnb7NDHzDrh8kQCQiG6fr95BEFGDiW6pjrMeCtmPODXIu+z1WGof6OeH0/jnNT99758ReZUhlK1pLzqzYKrhqFew5ur4Ur3bIDyPJSQB9fXoFrcp62nCeD46Bzf4cxmUIfTjneW8Z8HPSROqjxr5ltvBeQhUE6RWM30Id4HCTZ+samcS+66g42ZJKP4NpY4SDkZEaXNGSn16MAzOyzAr7ip4vSRBhBWYgvQt3FMunK2DXFlKEiJ29G6cOEpdTXJ+hnGGP7tc/MN6ZDqWGIr04Yw== Received: from BN9PR03CA0150.namprd03.prod.outlook.com (2603:10b6:408:fe::35) by MWHPR12MB1632.namprd12.prod.outlook.com (2603:10b6:301:10::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4436.19; Mon, 23 Aug 2021 08:16:02 +0000 Received: from BN8NAM11FT051.eop-nam11.prod.protection.outlook.com (2603:10b6:408:fe:cafe::14) by BN9PR03CA0150.outlook.office365.com (2603:10b6:408:fe::35) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4436.19 via Frontend Transport; Mon, 23 Aug 2021 08:16:02 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 216.228.112.34) smtp.mailfrom=nvidia.com; intel.com; dkim=none (message not signed) header.d=none;intel.com; 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 BN8NAM11FT051.mail.protection.outlook.com (10.13.177.66) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.4436.19 via Frontend Transport; Mon, 23 Aug 2021 08:16:01 +0000 Received: from nvidia.com (172.20.187.6) by HQMAIL107.nvidia.com (172.20.187.13) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Mon, 23 Aug 2021 08:15:59 +0000 From: Xueming Li To: CC: , , Cristian Dumitrescu , Jasvinder Singh Date: Mon, 23 Aug 2021 11:15:38 +0300 Message-ID: <20210823081539.1410259-1-xuemingl@nvidia.com> X-Mailer: git-send-email 2.27.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [172.20.187.6] X-ClientProxiedBy: HQMAIL107.nvidia.com (172.20.187.13) To HQMAIL107.nvidia.com (172.20.187.13) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 6a3d0e95-1785-464d-fef8-08d9660e3edb X-MS-TrafficTypeDiagnostic: MWHPR12MB1632: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:1169; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: u/CjmYq60iZ4KF7hU46glccoryDxDjAsR8TJ/Jzk69uOQ/a5Ytj2joXUAJ78yEioMBkRbYG5PI/R0us8PV0b1T2/v2RBhB6xpFeuYvnPUZzPmxsTx6vyGIzflEv2w66Bd5AQ7HKczNQUeyBrRJMpN6r7n4krHq6DD9gOtb0kqkfBxjSfiU1Upxv7WH0FdaGXx8xKd6D83z1rbiVkbnpefrUAzV2eRfDaKi+sGdqmuFRBu1SrWL1Ir/dwo6Mgd5n9itHwvwPWImCyoWHCpbKwu5wtvA81Ltng2kPJ6aWe11ggse9I2IKctyN+O6jPW8nQrRX2J2x1zw13kQr2SmSGflGH8FwbYpfG7EJ7SkVTClElQ1IgR1RFs/xKPy++JGREj5PbYjlMpuNdDuc781orvga1bWLveuJ0oqLERXHM9s7kARLT9py+iMoG83fXrhkEehrkzXGPoklKsgB20mdPBD6DzyRCScqPZiuza3FN/X0uXDIdQgjdsYUjLaNdEhrw70Lzv8jxxB2abgpjcokAT9aJlXUQ4UmUKCm2LiUPMLMeh2XKpiQeJPhxY8Uh+G11r6hBygfogcR1RrNEkQIkPJb9w1nN3qPztrbbAQB7NCRbkC7HkKXMG0h1BeYfeJ5WaA85V+Q5SKeFpiPCEgCgvbvGOm81vuRy6wEKUx0B/v/vKUwpiO9WerynA8H7OVrS3HX19s860PjtVUG8p7VmmwfKpaN4/+zodgn9ad9mnrE= 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)(46966006)(36840700001)(356005)(70586007)(70206006)(26005)(55016002)(83380400001)(6666004)(86362001)(2906002)(4326008)(54906003)(47076005)(82310400003)(36756003)(1076003)(6286002)(36906005)(8676002)(16526019)(426003)(7636003)(186003)(336012)(36860700001)(316002)(109986005)(8936002)(4744005)(508600001)(5660300002)(7696005)(2616005)(266003); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Aug 2021 08:16:01.7877 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 6a3d0e95-1785-464d-fef8-08d9660e3edb 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: BN8NAM11FT051.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: MWHPR12MB1632 Subject: [dpdk-dev] [PATCH] sched: support 64 bits greatest common divisor 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 Sender: "dev" This patch changes inline function that compute the greatest common divisor to 64 bits. Signed-off-by: Xueming Li --- lib/sched/rte_sched_common.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/sched/rte_sched_common.h b/lib/sched/rte_sched_common.h index 96706df7bd..65c03329f6 100644 --- a/lib/sched/rte_sched_common.h +++ b/lib/sched/rte_sched_common.h @@ -51,10 +51,10 @@ rte_min_pos_4_u16(uint16_t *x) * gcd(a, b) = gcd(b, a mod b) * */ -static inline uint32_t -rte_get_gcd(uint32_t a, uint32_t b) +static inline uint64_t +rte_get_gcd(uint64_t a, uint64_t b) { - uint32_t c; + uint64_t c; if (a == 0) return b; -- 2.25.1