From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by spool.mail.gandi.net (Postfix) with ESMTPS id 2E9C4AC1595 for ; Thu, 22 Feb 2024 14:18:41 +0000 (UTC) DKIM-Signature: a=rsa-sha256; bh=nIcUZe2Z1cr7eacLTXoQ0j9XaT/CnKldSnxkEqn8l/Y=; c=relaxed/simple; d=groups.io; h=ARC-Seal:ARC-Message-Signature:ARC-Authentication-Results:From:To:CC:Subject:Thread-Topic:Thread-Index:Date:Message-ID:References:In-Reply-To:Accept-Language:MIME-Version:Precedence:List-Subscribe:List-Help:Sender:List-Id:Mailing-List:Delivered-To:Reply-To:List-Unsubscribe-Post:List-Unsubscribe:Content-Language:Content-Type:Content-Transfer-Encoding; s=20140610; t=1708611519; v=1; b=R0MufEkfGJlpAIC8ZaZK/KOyqxZlncrxPgJEMnkDKNeweyxbvwqYWNWSN42dwzlld6NQBxvz rgd6+HsULSUkHZdiy8Oo2Q7gblkiqbOnCcf9nImezaJR3oL0RYhSLYaRHLRyWfgaBeg7OTqUsgo PIuS1NN3QYuDGT2JZyy38F4U= X-Received: by 127.0.0.2 with SMTP id dzrcYY7687511xBNunZR2dkY; Thu, 22 Feb 2024 06:18:39 -0800 X-Received: from NAM02-BN1-obe.outbound.protection.outlook.com (NAM02-BN1-obe.outbound.protection.outlook.com [40.107.212.104]) by mx.groups.io with SMTP id smtpd.web11.13676.1708611519078682515 for ; Thu, 22 Feb 2024 06:18:39 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ad4e+OAfoAWyjVgoZLCnOya9/DSuGCLZDdeq+v2BSg1q3aTbvQTz+2NFmY00uoIO6gncYt6dcNAHcAwn8Pw/fTS1Q0qKFjctzJTMi5ORtbU7qL/2ecqkrVGvyol5lZ1+zf+XA5OTpOvRG3C9H1c3P2IWzcnufJtS5L6LNGUBubqSdZvTypAFBjkbj6PYi9Auihu8ynwKg27m6ekK1WQPsyLC69M3bCXDdguAfdJf8uLFIWndWay/pqOBQnLPQRYF6hCt/rUDRmZ08JG+OlxBZPlDxYzYUG2opcEI/Uu/tqG18KAXnjPQtGA3C0GVe1WAaLQ8TRqJwN+CXLseOJeuAw== 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=OOdz5zSHheMW5pJc/VRyIekiUwPnWftNeUxIyHQTAjM=; b=CzmMdkWCd68TfV3koAc4UHO4ZX9IrOD5OjfOE134WpGr6QVzKEVZ5vjJ7bbpLCzIgWm3NhHZAdudEOEMf7SOmn4CH1SQc0etmMlQ7NyHM1ReVTNSkv5fK3d4Ajiy+mkojA+WgqjubLEZQh/nPG5ppsIk1U4EQfD0MuFBPZPG7TYHxl8ISvIAZ8/Cw9frkOejiSc/Mo4bzfwEbMrOpUaC5VngZQBtK9YgwGDGGyPFhlU7Quw1pHe4kMFKx9wpZKyO6vHQZO3t5+Pbj7o8FbBYnGrT2gLnsMu/ZtlwL8bHPAUHDIX8Vbpu3gA500jrMzRKS1qqeasrXUgP3fRgHvsoug== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=ami.com; dmarc=pass action=none header.from=ami.com; dkim=pass header.d=ami.com; arc=none X-Received: from BLAPR10MB5185.namprd10.prod.outlook.com (2603:10b6:208:328::16) by SA1PR10MB6518.namprd10.prod.outlook.com (2603:10b6:806:2b4::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7316.22; Thu, 22 Feb 2024 14:18:35 +0000 X-Received: from BLAPR10MB5185.namprd10.prod.outlook.com ([fe80::7840:c724:8a2a:4cf5]) by BLAPR10MB5185.namprd10.prod.outlook.com ([fe80::7840:c724:8a2a:4cf5%5]) with mapi id 15.20.7316.023; Thu, 22 Feb 2024 14:18:35 +0000 From: "Igor Kulchytskyy via groups.io" To: Nickle Wang , "devel@edk2.groups.io" CC: Abner Chang , Nick Ramirez Subject: Re: [edk2-devel] [PATCH v2 6/6] RedfishPkg/RedfishCrtLib: fix unresolved external symbol issue Thread-Topic: [EXTERNAL] [PATCH v2 6/6] RedfishPkg/RedfishCrtLib: fix unresolved external symbol issue Thread-Index: AQHaZW8zZIf0Yr6rXkmFcNpdS4Ra9rEWaSbw Date: Thu, 22 Feb 2024 14:18:35 +0000 Message-ID: References: <20240222091154.852-1-nicklew@nvidia.com> In-Reply-To: <20240222091154.852-1-nicklew@nvidia.com> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ms-publictraffictype: Email x-ms-traffictypediagnostic: BLAPR10MB5185:EE_|SA1PR10MB6518:EE_ x-ms-office365-filtering-correlation-id: 3deed69a-36f5-4c73-cf14-08dc33b127f2 x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam-message-info: nKLGpR+Y79NnW1bj/Q1jQcnAUv+brJ7E9tgFeuDe+xQq+0PqZoSmZNC6pp0nNE8HhwL9Ackc1zZK9zFyEWVIX1WRK/C8mOiLEotXH/MnXLb9V105LSekaJCfXq8OWVsfhBQxsT69mcHl0sapkVQXawpbUl4J93wcxI62qkVKzP68uqyZVTHmP8TOtBzZtztU35hNZdB0/GWKQyA3ErMq5lC09pdnJ0GK1oPWdTkeGpnTzgm5tmKT92s6uBWut7ygiGyLAfWHY5pm/MgQgYZLtSG7tJPeWdCkJ8RqMmd2AKaAlFLNyBgudrhYvKtdrELx//7i2p4dIutBaTucP/W5G0HppcWMLQChYFwc6qCTK8xqbslJy23t4XRUdENQTW/pmW/Mgrn70Mw1prCfjeY3pY05kNpGvVIvZj19Eyn2F5WBnO6eHglQg32bYlU4I5ithD7uZJjdjBz3r0WeA6vGWWMIlwto2g8fplO5VCMN/qXUnE+9tGu9/6ecqT9sD75c0hEpW84m2YDHXEhssCAYpENwNi3/+3tfQR+OopL2q2kt8CgkkcB9wqfMrSUadayqnCpN62p/dEtjY51G0DSl1xwsWlDz6/Oc9rRz1o9xOA7jCjzpfo+HGd9QeJHPilAp x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?gl0OSjUfnT2dEe3rsRxkJ2fTaSuiFzqprBro/hXmgfSD8Ed/mDdcwDEoPcZN?= =?us-ascii?Q?1Mq0e8rya9FoWeQLOyPSpxtxMZpTeUzGxm4YXcZCBu+7KYsQ+Cr5nlfK+AXA?= =?us-ascii?Q?+pmmkaiyVI7+azRxBQYkCKjT0fl+b5I6M8Meinu+TpqaHvwvLk0jb3XJfQjJ?= =?us-ascii?Q?/AAjFnTvGfAGPOgnGS6jnUq4RnJL0pd5HWOQi6O+AYHlyEarDEQK0YvDRMA4?= =?us-ascii?Q?nFNNtPIvGdQbvsK9eot3ex+sE38KqVWYmziAa5HAW35Qeay+QHkQ/SSEpcDL?= =?us-ascii?Q?X65quYHcnLVN2ONRJBj1AbIcnphZ3n85NAF2Pcw5Ipmy3fWod92/O6dEKyfN?= =?us-ascii?Q?iElYqGHWU5WrGIPBZR159TMwlCtklKYtFKgUkX/NPRzQIt1pxaR3ObNpW2wa?= =?us-ascii?Q?hZDco3EqzDZT6benbRSV1tBXujYaaxYk3TGNL6TuF9vpep6OoMb6OeTZHaq5?= =?us-ascii?Q?SYVYlb83rU9Tq/99aZj82uiuyCYqH5/1Ic6TCSCVeVFHLWzNmLst7nCpac1a?= =?us-ascii?Q?lzyjmEbzFj64Hm9xjgY720N4G78DSa20HbSBoqTAa6U/j76tDGWXNdk/ZJMG?= =?us-ascii?Q?o1IDi4Ga4z3CFVb73qSID2cbke3fgS/GQrRDIWl8LY18cChxQgVP4gDjSb78?= =?us-ascii?Q?+2witA2CKjTexb8H/pSHdNxxwUNlZZvyNgNL/rfc0+ZOm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?= MIME-Version: 1.0 X-OriginatorOrg: ami.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: BLAPR10MB5185.namprd10.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 3deed69a-36f5-4c73-cf14-08dc33b127f2 X-MS-Exchange-CrossTenant-originalarrivaltime: 22 Feb 2024 14:18:35.1622 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 27e97857-e15f-486c-b58e-86c2b3040f93 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: lrkBsBcM9Qho71wY2ND/UQIWRC5gg6wWQPIFPx8nRgXj6pwGYihZ5rBBKephoy7H X-MS-Exchange-Transport-CrossTenantHeadersStamped: SA1PR10MB6518 Precedence: Bulk List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,igork@ami.com List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: X-Gm-Message-State: 4VOA7TYIPeoXMWsdhHhKqWzjx7686176AA= Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable X-GND-Status: LEGIT Authentication-Results: spool.mail.gandi.net; dkim=pass header.d=groups.io header.s=20140610 header.b=R0MufEkf; arc=reject ("signature check failed: fail, {[1] = sig:microsoft.com:reject}"); dmarc=pass (policy=none) header.from=groups.io; spf=pass (spool.mail.gandi.net: domain of bounce@groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce@groups.io Reviewed-by: Igor Kulchytskyy -----Original Message----- From: Nickle Wang Sent: Thursday, February 22, 2024 4:12 AM To: devel@edk2.groups.io Cc: Abner Chang ; Igor Kulchytskyy ; Ni= ck Ramirez Subject: [EXTERNAL] [PATCH v2 6/6] RedfishPkg/RedfishCrtLib: fix unresolved= external symbol issue **CAUTION: The e-mail below is from an external source. Please exercise cau= tion before opening attachments, clicking links, or following guidance.** -Fix below compiler error reported in edk2 CI. ERROR - Linker #2001 from JsonLib.lib(load.obj) : unresolved external symbol __ftol2 -The file MathFtol.c is copied from IntrinsicLib in CryptoPkg. -Add MathFtol.c to EccCheck IgnoreFiles. Signed-off-by: Nickle Wang Cc: Abner Chang Cc: Igor Kulchytskyy Cc: Nick Ramirez --- .../RedfishCrtLib/RedfishCrtLib.inf | 7 +++- .../RedfishCrtLib/Ia32/MathFtol.c | 37 +++++++++++++++++++ RedfishPkg/RedfishPkg.ci.yaml | 2 + 3 files changed, 45 insertions(+), 1 deletion(-) create mode 100644 RedfishPkg/PrivateLibrary/RedfishCrtLib/Ia32/MathFtol.c diff --git a/RedfishPkg/PrivateLibrary/RedfishCrtLib/RedfishCrtLib.inf b/Re= dfishPkg/PrivateLibrary/RedfishCrtLib/RedfishCrtLib.inf index 6ff5dba75c..3a5e309d1a 100644 --- a/RedfishPkg/PrivateLibrary/RedfishCrtLib/RedfishCrtLib.inf +++ b/RedfishPkg/PrivateLibrary/RedfishCrtLib/RedfishCrtLib.inf @@ -3,6 +3,7 @@ # # Copyright (c) 2019, Intel Corporation. All rights reserved.
# (C) Copyright 2020 Hewlett Packard Enterprise Development LP
+# Copyright (c) 2024, NVIDIA CORPORATION & AFFILIATES. All rights reserved= . # # SPDX-License-Identifier: BSD-2-Clause-Patent # @@ -23,6 +24,9 @@ [Sources] RedfishCrtLib.c +[Sources.IA32] + Ia32/MathFtol.c | MSFT + [LibraryClasses] BaseLib SortLib @@ -35,4 +39,5 @@ MdeModulePkg/MdeModulePkg.dec RedfishPkg/RedfishPkg.dec - +[BuildOptions] + MSFT:*_*_IA32_CC_FLAGS =3D /GL- diff --git a/RedfishPkg/PrivateLibrary/RedfishCrtLib/Ia32/MathFtol.c b/Redf= ishPkg/PrivateLibrary/RedfishCrtLib/Ia32/MathFtol.c new file mode 100644 index 0000000000..e49f00eaf5 --- /dev/null +++ b/RedfishPkg/PrivateLibrary/RedfishCrtLib/Ia32/MathFtol.c @@ -0,0 +1,37 @@ +/** @file This file is copied from CryptoPkg/Library/IntrinsicLib/Ia32/Mat= hFtol.c + 64-bit Math Worker Function. + The 32-bit versions of C compiler generate calls to library routines + to handle 64-bit math. These functions use non-standard calling conventi= ons. + +Copyright (c) 2019, Intel Corporation. All rights reserved.
+SPDX-License-Identifier: BSD-2-Clause-Patent + +**/ + +/* + * Floating point to integer conversion. + */ +__declspec(naked) void +_ftol2 ( + void + ) +{ + _asm { + fistp qword ptr [esp-8] + mov edx, [esp-4] + mov eax, [esp-8] + ret + } +} + +__declspec(naked) void +_ftol2_sse ( + void + ) +{ + _asm { + fistp dword ptr [esp-4] + mov eax,[esp-4] + ret + } +} diff --git a/RedfishPkg/RedfishPkg.ci.yaml b/RedfishPkg/RedfishPkg.ci.yaml index 69b6bf39f5..b95e8bfdc7 100644 --- a/RedfishPkg/RedfishPkg.ci.yaml +++ b/RedfishPkg/RedfishPkg.ci.yaml @@ -2,6 +2,7 @@ # CI configuration for NetworkPkg # # (C) Copyright 2021 Hewlett Packard Enterprise Development LP
+# Copyright (c) 2024, NVIDIA CORPORATION & AFFILIATES. All rights reserved= . # SPDX-License-Identifier: BSD-2-Clause-Patent ## { @@ -38,6 +39,7 @@ "PrivateInclude/Crt/string.h", "PrivateInclude/Crt/time.h", "PrivateLibrary/RedfishCrtLib/RedfishCrtLib.c", + "PrivateLibrary/RedfishCrtLib/Ia32/MathFtol.c", "Include/Library/RedfishCrtLib.h", ## ## For jansson library open source -- 2.34.1 -The information contained in this message may be confidential and propriet= ary to American Megatrends (AMI). This communication is intended to be read= only by the individual or entity to whom it is addressed or by their desig= nee. If the reader of this message is not the intended recipient, you are o= n notice that any distribution of this message, in any form, is strictly pr= ohibited. Please promptly notify the sender by reply e-mail or by telephone= at 770-246-8600, and then delete or destroy all copies of the transmission= . -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#115823): https://edk2.groups.io/g/devel/message/115823 Mute This Topic: https://groups.io/mt/104505407/7686176 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-