From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from NAM12-DM6-obe.outbound.protection.outlook.com (NAM12-DM6-obe.outbound.protection.outlook.com [40.107.243.127]) by mx.groups.io with SMTP id smtpd.web10.97.1626495709856535626 for ; Fri, 16 Jul 2021 21:21:50 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@microsoft.com header.s=selector2 header.b=NP3ewKsW; spf=pass (domain: microsoft.com, ip: 40.107.243.127, mailfrom: arti.gupta@microsoft.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=IoDwW46ZSi7F83YQLeTJ1syJoVp4coedchifjVh4Eyb13rT6HkBUsMOuW+bgrYHVm274baJaMCye3lrFLfbSddze+quZ2zstm3ZBpfIcIVZ3hQU+466iDjsxAu49emo1YMzUyICxqzREaadSL9tXGXRd/758NB+i76or2mMbGRRBdlGap6tN2I4loqi9nlvqLHtMr6tieuc1juvMTHxIkzONhpTr57MwalE9NMNta+Y7Iz7y1+NT6hKYU+Bxyoc4NdqrzzOCNDcq1J69iv4FWwF0fAKVoNZg2NyBAuCI5C7uDCHtOPLS5PBsS2hgbKknGiuc5gr7TIW2OH+pB7QBcQ== 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=xbKpUKxFtVmHnEmPceZ8NTkLXrI+Zju0w6fdNDvHOHo=; b=nhUOYQUbDiakgHMVmsxZFrewlrFT8e94fZWkwYKNfDxtSyDbdqSe12eEj7sf1WmNdkpt8MVkW2jDUHnMnYq5+rsQ8z/tfEoT3pT6sArL9e62BJDZ1qnxMeoatxTf1qYTzhFobUCejM3fFvHLclEp8THlz4Jn6xDuIZdAFGYMp0jgoWBgHLuqZkMpLQZJLaEPiyfZ42xCBZqe66Vb4BZLVfSEY9I0GNJ5vr3IF+4CHSM8noz9IXJN4uiiHlvRFqYBWPbBgHk6JYxKqAUtRCFAiNPcRny8WUsGjegF7C5y2xFBAyNIJqCPPHRKnuzRQMo8v6lk+SqCs2gqWNGfukps5w== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=microsoft.com; dmarc=pass action=none header.from=microsoft.com; dkim=pass header.d=microsoft.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=xbKpUKxFtVmHnEmPceZ8NTkLXrI+Zju0w6fdNDvHOHo=; b=NP3ewKsWEcsKeL6hwKd6oUflp8/V9eGZ83QZZRwJxTFVIg2OKA245T3fGRtTMG3CFTvpoN1AkCCYA1hkYBeHmBX0lVZKkSC44MZa2IuPTjKMNpoqBmQWi5nXw1Mzx7tuhrRMMOqVBWOJ4CTL/+wWxXcrgeZHx+0VdX4afwGnIuQ= Received: from PH0PR21MB1864.namprd21.prod.outlook.com (2603:10b6:510:9::20) by PH0PR21MB1973.namprd21.prod.outlook.com (2603:10b6:510:14::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4352.9; Sat, 17 Jul 2021 04:21:42 +0000 Received: from PH0PR21MB1864.namprd21.prod.outlook.com ([fe80::e897:e8bd:650c:8bf3]) by PH0PR21MB1864.namprd21.prod.outlook.com ([fe80::e897:e8bd:650c:8bf3%7]) with mapi id 15.20.4352.011; Sat, 17 Jul 2021 04:21:41 +0000 From: Arti Gupta To: Andrew Fish , edk2-devel-groups-io Subject: Re: [EXTERNAL] Re: [edk2-devel] BaseCryptLib in ARM incorrectly marked as a DXE_DRIVER Thread-Topic: [EXTERNAL] Re: [edk2-devel] BaseCryptLib in ARM incorrectly marked as a DXE_DRIVER Thread-Index: Add471H/+453tOReTWWqC0vGIEeFYAAQIsSAAGTT41A= Date: Sat, 17 Jul 2021 04:21:41 +0000 Message-ID: References: <7B759ABE-6B14-458D-B9E4-C11A2F3ABCE6@apple.com> In-Reply-To: <7B759ABE-6B14-458D-B9E4-C11A2F3ABCE6@apple.com> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: msip_labels: MSIP_Label_f42aa342-8706-4288-bd11-ebb85995028c_ActionId=c15e7172-d867-4fad-88d7-6a97f82f5b55;MSIP_Label_f42aa342-8706-4288-bd11-ebb85995028c_ContentBits=0;MSIP_Label_f42aa342-8706-4288-bd11-ebb85995028c_Enabled=true;MSIP_Label_f42aa342-8706-4288-bd11-ebb85995028c_Method=Standard;MSIP_Label_f42aa342-8706-4288-bd11-ebb85995028c_Name=Internal;MSIP_Label_f42aa342-8706-4288-bd11-ebb85995028c_SetDate=2021-07-17T04:21:11Z;MSIP_Label_f42aa342-8706-4288-bd11-ebb85995028c_SiteId=72f988bf-86f1-41af-91ab-2d7cd011db47; authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=microsoft.com; x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 48999c64-2068-4585-0ea9-08d948da6115 x-ms-traffictypediagnostic: PH0PR21MB1973: 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: rJcAc327LpSr8yE97ZWAPI73aElJ5moq48NU2VvpL9Hc+CaIiCmyYNgBW9XZplki/wsh2Upw7UFqJn4rJCq0Rtj+OT7SQ40aPwmzOZT21zJeYILfEqY0Udjre9mHfkUraMPG/1e8S1p7MJjY6UMHxGxZxi1zU/bWm+yg7J86s/HbnfmQswLud0LzgPXmi8ih1Lu91lv3QlcrDuX3WKteGhRRbQ8+gOXJ0xv/vKzz9sCH+YqRe+wAqLlw3iH7FaHTTcWRvPw+lCsFo7Uejl4115HuA2ngQL7i5/wT55lW+YgW0Lx1M5mifZZVCS9jnU/jYgV2ujI2DcQP6JHY4c/7DwGS8BdHRs5sR2+H9Rrta3oidzIDe3VPbtBsj9OpXLu+l/qsiIg6k100K7Rbg8xl01yaun6tk+ZjgJqANT+GSpejq7GTrsdrr1mEZFoMYtW+5tXXoM/ff8Qko+40oVy4aLKC8RMDjRAIG/sg7VUHuBOx4Q+7on4EbUpOQcElZjd7oIOnxDQvEsFRD6B3gxGFZx/RLjXWpIX/HcMueUrYkJEONbHQd9WPWN2S3ETU4P31Jt+lQWJ+HXsg5JVYcPzzS1GjZ4mbvj9lUJs0AHvVXeoOWdMa4RMwL8WzwycjlOBY/Qayc4ievllRBJPgWwbJhJ4ZQuFGxSgvzZs0KeuOzDWSYpmwh9pgh3Acjbh3zKSe+/xdbRIdaSlX7zhcAk2egp6S2Xwe+NoGhrKK0lMNpTECf7iyeaEZeU8ya+KNSQfFV8kDmNCF67BP8OsRcSVIil/JgUjFbmsSpTnrv81Ve9fWjKGlEpjheoV317QZr2JiEp/IUMR5yLXizY9VG2SZEw== x-forefront-antispam-report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:PH0PR21MB1864.namprd21.prod.outlook.com;PTR:;CAT:NONE;SFS:(4636009)(366004)(82950400001)(6506007)(8990500004)(110136005)(82960400001)(33656002)(10290500003)(38100700002)(71200400001)(8676002)(122000001)(53546011)(316002)(66476007)(76236003)(8936002)(66446008)(9686003)(5660300002)(66556008)(55016002)(7696005)(2906002)(508600001)(64756008)(186003)(52536014)(66946007)(166002)(86362001)(966005)(44832011)(76116006)(26005)(83380400001)(38070700004);DIR:OUT;SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?0lTEq5qesF9Pc/mkzTjfAeOU+Mae4bhBYpKG9tfI93EoM6i4Ed30qrQbajeh?= =?us-ascii?Q?iDKqxFbisiqO7vnIii0z3C9PJo4xKMtKwjBFxhmPYzKXaVYto8VRtUzi7IcN?= =?us-ascii?Q?HUZ4VS1YHjk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beDFOEYNAm4im?= =?us-ascii?Q?+bsZB7KhFOpg75GXkKG98THMRn1sn6CXxpOl8zMHduFTN41oe3WN8AdyF0Da?= =?us-ascii?Q?jm+wBamrh6UbCHfhVeH0RTSv0y9cyYkaRNruODoyKZhoY24GGViIia/nFkFJ?= =?us-ascii?Q?5b3xuZqOdombz054D2ZtnpwM2RkO+snLWNlaVvi+0SqYdZ2UZyVVFMahU4he?= =?us-ascii?Q?LB7fiKiUEvwdvzHQlljOn3lTcc4/uoWVDlhghxKggZPboeAtwS+BqpuDyAag?= =?us-ascii?Q?V09JnzWcARuUDpXbGvG4hV81ParsVvXlZaHitm0udPttrSpsulke5dPROaDo?= =?us-ascii?Q?LNCPp8xhoJph+bKrwcxlVdth?= x-ms-exchange-transport-forked: True MIME-Version: 1.0 X-OriginatorOrg: microsoft.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: PH0PR21MB1864.namprd21.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 48999c64-2068-4585-0ea9-08d948da6115 X-MS-Exchange-CrossTenant-originalarrivaltime: 17 Jul 2021 04:21:41.7381 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 72f988bf-86f1-41af-91ab-2d7cd011db47 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: izlErDe5hgghRUkTmUf8Z7jyrzc+65W4g7AgYSaqhhcide8hxQhz/VMndPCyJXUB3rYn2+xf+tIT3CPPxrCSphiWjitCNmrj/u63bmJEngI= X-MS-Exchange-Transport-CrossTenantHeadersStamped: PH0PR21MB1973 Content-Language: en-US Content-Type: multipart/alternative; boundary="_000_PH0PR21MB186472CBA485829AFFB87DF596109PH0PR21MB1864namp_" --_000_PH0PR21MB186472CBA485829AFFB87DF596109PH0PR21MB1864namp_ Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Thank you Andrew, you are right. I missed the fact that there are 2 INFs in= there. From: Andrew Fish Sent: Wednesday, July 14, 2021 9:14 PM To: edk2-devel-groups-io ; Arti Gupta Subject: [EXTERNAL] Re: [edk2-devel] BaseCryptLib in ARM incorrectly marke= d as a DXE_DRIVER Arti, Can you be a little more specific? Which INF file? How is it used? Sorry I= don't know a lot about this library. The different INF files pull in different allocation strategies for the co= mmon library code. https://github.com/tianocore/edk2/blob/master/CryptoPkg/Library/BaseCryptL= ib/RuntimeCryptLib.inf SysCall/RuntimeMemAllocation.c https://github.com/tianocore/edk2/blob/master/CryptoPkg/Library/BaseCryptL= ib/BaseCryptLib.inf SysCall/BaseMemAllocation.c The most important line in the INF is: LIBRARY_CLASS =3D BaseCryptLib|DXE_RUNTIME_DRIVER or LIBRARY_CLASS =3D BaseCryptLib|DXE_DRIVER DXE_CORE UEFI_A= PPLICATION UEFI_DRIVER The list after the | is what module types this library can be linked into.= I don't remember what issue a wrong MODULE_TYPE for a library would cause.= I think the LIBRARY_CLASS list may override the MODULE_TYPE in terms of ho= w this library gets consumed. Thanks, Andrew Fish On Jul 14, 2021, at 1:34 PM, Arti Gupta via groups.io > wrote: Hello, I am seeing that the BaseCryptLib in ARM is declared as a DXE_DRIVER inste= ad of a DXE_RUNTIME_DRIVER, however it has a RuntimeMemAllocation.c which r= egisters for the virtualaddresschange event so that tells me that the lib i= s expected to live in runtime. Is this bug known? What are the next steps f= or getting this fixed? Thanks, Arti --_000_PH0PR21MB186472CBA485829AFFB87DF596109PH0PR21MB1864namp_ Content-Type: text/html; charset="us-ascii" Content-Transfer-Encoding: quoted-printable

Thank you Andrew, you are right. I missed the fact = that there are 2 INFs in there.

 

From: Andrew Fish <afish@apple.com> Sent: Wednesday, July 14, 2021 9:14 PM
To: edk2-devel-groups-io <devel@edk2.groups.io>; Arti Gupta &= lt;arti.gupta@microsoft.com>
Subject: [EXTERNAL] Re: [edk2-devel] BaseCryptLib in ARM incorrectl= y marked as a DXE_DRIVER

 

Arti,

 

Can you be a little more specific? Which INF file? = How is it used? Sorry I don’t know a lot about this library. 

 

The different INF files pull in different allocatio= n strategies for the common library code. 

 

SysCall/BaseMemAllocation.c

 

The most important line in the INF is:

 

LIBRARY_CLASS       &nb= sp;          =3D BaseCryptLib|= DXE_RUNTIME_DRIVER

 

or

 

LIBRARY_CLASS   = ;            &n= bsp;  =3D BaseCryptLib|DXE_DRIVER DXE_CORE UEFI_APPLICATION UEFI_DRIVE= R

 

The list after the | is what module types this libr= ary can be linked into. I don’t remember what issue a wrong MODULE_TY= PE for a library would cause. I think the LIBRARY_CLASS list may override t= he MODULE_TYPE in terms of how this library gets consumed. 

 

Thanks,

 

Andrew Fish



On Jul 14, 2021, at 1:34 PM, Arti Gupta via groups.io <= arti.gupta=3Dmicrosoft.com@groups.io> wrote:

 

Hello,

 

I am seeing that the BaseCryptLib in ARM is declare= d as a DXE_DRIVER instead of a DXE_RUNTIME_DRIVER, however it has a Runtime= MemAllocation.c which registers for the virtualaddresschange event so that = tells me that the lib is expected to live in runtime. Is this bug known? What are the next steps for getting t= his fixed?

 

Thanks,
Arti

 

--_000_PH0PR21MB186472CBA485829AFFB87DF596109PH0PR21MB1864namp_--