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 63D157803CD for ; Wed, 21 Feb 2024 02:10:11 +0000 (UTC) DKIM-Signature: a=rsa-sha256; bh=OPTdsxTm2MrY8E88+Yj+KR6OiaaU2kmybURjI/IAMDs=; 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:msip_labels: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=1708481410; v=1; b=jR9E9GMN94/PWw1NUEy/0dZ1/P1PfeAFENzaUlRZqKj/77RdtXO5CQE0YdYkHDnRu1ucvvW0 pMl13ehK4ug7fUOo09OgJMu0KdQa9E1tIpel/1/yAj+bGVgCNdsLKFDeIaNfDm9dZnOvwqWe6mi jXD9B1pXIJ/jpyHx7Y4kK+e0= X-Received: by 127.0.0.2 with SMTP id bZtGYY7687511xcE4Tg9ql0g; Tue, 20 Feb 2024 18:10:10 -0800 X-Received: from NAM10-DM6-obe.outbound.protection.outlook.com (NAM10-DM6-obe.outbound.protection.outlook.com [40.107.93.67]) by mx.groups.io with SMTP id smtpd.web11.4040.1708481409443172483 for ; Tue, 20 Feb 2024 18:10:09 -0800 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=aJ5IM7mHPbmDokKFYxo1LWpewT+bo/Dq/NKw7bp0swQuHsr+Bt/44cLxQnyQTx3UayL5+NaE4RhNiMeg5Q5WZnA/l82ALb/k8TB7+X2Q48pYXutybEQyl4p4BxjqU+iEXk7HaZgpmaGwidu+LPOCAB3nZ8uTIbmAu93bZR8PeIVhZvxxfwGa+x52Q8GKenlFvFPcTknwZn6gYyHkd+13IjXeTVVD4JlWYmvxekHYezy5kAa5Nk1gnCzxryLfyYWHjEGsQI7kAOVGk1a725TFbbRcBOpWREqBJkPOYxHrmi5RYV4Ma3q64HnbzLpRCcexELKeTti+nYBR8js58RMYow== 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=y3OqybyIp4KIqjrTOD1z5hL+lRSsvBwPihVNralweHw=; b=ChiiZ6c6h3E/O8tcnjWH/z/xQHfcWYlptoSc6Dm6Yy9gW3kPleQsiQG/a0ynTMJcZ57H0fl3PC/AjTjS/+e69TqIag1IKefrAeZNn6DaRKY7a477YH1Q1c4J1rgki91ndOVvuaz5+Oe/ReHVGUYnljiPnP86I+5UhmBndPfNMwylHnhvaAcNd+VzVWiiGz9PgpzCg5W8t3EEYPj2DHiC62icKU2QEjoHVRVRp1A3KGf4NL/4icxYmD6pEVMHW/ubwHBFZTALzCfd7aF9Gy9lpiv1veHbemg/GXneR1lhZUvTN16awp7XBv8gDt9RhG5/ObJY9Xw99J3U1lTCBNnGzw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none X-Received: from LV8PR12MB9452.namprd12.prod.outlook.com (2603:10b6:408:200::8) by DM4PR12MB5214.namprd12.prod.outlook.com (2603:10b6:5:395::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7316.21; Wed, 21 Feb 2024 02:10:07 +0000 X-Received: from LV8PR12MB9452.namprd12.prod.outlook.com ([fe80::bf3e:6aec:43a1:5ae1]) by LV8PR12MB9452.namprd12.prod.outlook.com ([fe80::bf3e:6aec:43a1:5ae1%4]) with mapi id 15.20.7316.018; Wed, 21 Feb 2024 02:10:06 +0000 From: "Chang, Abner via groups.io" To: Nickle Wang , "devel@edk2.groups.io" CC: Igor Kulchytskyy , Nick Ramirez Subject: Re: [edk2-devel] [PATCH 6/6] RedfishPkg/RedfishCrtLib: fix unresolved external symbol issue Thread-Topic: [PATCH 6/6] RedfishPkg/RedfishCrtLib: fix unresolved external symbol issue Thread-Index: AQHaY8frA5J+3l8aDUyCtPEZHqTEGrEUDdrw Date: Wed, 21 Feb 2024 02:10:06 +0000 Message-ID: References: <20240220064153.28651-1-nicklew@nvidia.com> In-Reply-To: <20240220064153.28651-1-nicklew@nvidia.com> Accept-Language: en-US, zh-CN X-MS-Has-Attach: X-MS-TNEF-Correlator: msip_labels: MSIP_Label_4342314e-0df4-4b58-84bf-38bed6170a0f_ActionId=d1376242-3c78-4049-a8b4-421c4d78827d;MSIP_Label_4342314e-0df4-4b58-84bf-38bed6170a0f_ContentBits=0;MSIP_Label_4342314e-0df4-4b58-84bf-38bed6170a0f_Enabled=true;MSIP_Label_4342314e-0df4-4b58-84bf-38bed6170a0f_Method=Standard;MSIP_Label_4342314e-0df4-4b58-84bf-38bed6170a0f_Name=General;MSIP_Label_4342314e-0df4-4b58-84bf-38bed6170a0f_SetDate=2024-02-21T02:07:23Z;MSIP_Label_4342314e-0df4-4b58-84bf-38bed6170a0f_SiteId=3dd8961f-e488-4e60-8e11-a82d994e183d; x-ms-publictraffictype: Email x-ms-traffictypediagnostic: LV8PR12MB9452:EE_|DM4PR12MB5214:EE_ x-ms-office365-filtering-correlation-id: 840f7830-adf3-449c-4f28-08dc3282395b x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam-message-info: 6PH1ZwcSw9BXQmFOvnDysk1XXNuPSPwkgcej8V+JEQnPebVh+CzH0/I6G2NzynYv20h6f5FuXy5X//fjWadBhVspnSMTkz3JoageIcSg1PRvIHrXAXqe+o6Siu023Ui1UwrP46zRJc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WCRxGPbdx8rUvJggqZ1m?= =?us-ascii?Q?x0JsZD05z9SSfst0XSSuknqRyP3RuC4L7OkveB6vhDt1JvNO39TRX3VKNo9G?= =?us-ascii?Q?1oA1N4XVcpVAO0DTGbK7YnzVMJJ93jkcHIYByGvbCeoUSHDQ0K/WXdk6w3KU?= =?us-ascii?Q?DdstM/+XPpXyljESgozi1oEuUiEKFJ+L/IF2lor3+BVDGfKdL9P2pRcgZhGD?= =?us-ascii?Q?n04VrkQK5Y2vYPRgbr74jFNhNl3QLyIHPME8hf1d+g+K+B3GoMapKPL4IOUT?= =?us-ascii?Q?/B0g1sdmT9VtGEieTkg8sTKCYqfq0jLPaJEcPo04?= MIME-Version: 1.0 X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: LV8PR12MB9452.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 840f7830-adf3-449c-4f28-08dc3282395b X-MS-Exchange-CrossTenant-originalarrivaltime: 21 Feb 2024 02:10:06.8973 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: rLmOapO2fQd/yBW8WgrqIb2cP1fPvaSnMpB4ypaaOvmEifm9aGtAucaN76tYndt8b7dqaG0y/y+k3qK07yEnbA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM4PR12MB5214 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,abner.chang@amd.com List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: X-Gm-Message-State: w5pjppoAeoTmYngztzFvohE6x7686176AA= 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=jR9E9GMN; 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 [AMD Official Use Only - General] > -----Original Message----- > From: Nickle Wang > Sent: Tuesday, February 20, 2024 2:42 PM > To: devel@edk2.groups.io > Cc: Chang, Abner ; Igor Kulchytskyy > ; Nick Ramirez > Subject: [PATCH 6/6] RedfishPkg/RedfishCrtLib: fix unresolved external > symbol issue > > Caution: This message originated from an External Source. Use proper caut= ion > when opening attachments, clicking links, or responding. > > > -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/RedfishPkg/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/RedfishPkg/PrivateLibrary/RedfishCrtLib/Ia32/MathFtol.c > new file mode 100644 > index 0000000000..adfe249b1d > --- /dev/null > +++ b/RedfishPkg/PrivateLibrary/RedfishCrtLib/Ia32/MathFtol.c > @@ -0,0 +1,37 @@ > +/** @file Hi Nickle, Could you please add the information here after @file about where this file= or the source code come from, such as the location of original file? Thanks Abner > + 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 > conventions. > + > +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.yam= l > 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 -=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 (#115696): https://edk2.groups.io/g/devel/message/115696 Mute This Topic: https://groups.io/mt/104463409/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-