From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga18.intel.com (mga18.intel.com [134.134.136.126]) by mx.groups.io with SMTP id smtpd.web11.3263.1588235659391222130 for ; Thu, 30 Apr 2020 01:34:19 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@intel.onmicrosoft.com header.s=selector2-intel-onmicrosoft-com header.b=Dya9zRyg; spf=pass (domain: intel.com, ip: 134.134.136.126, mailfrom: chasel.chiu@intel.com) IronPort-SDR: WzQOaASiDidbakeoB2VCe/xke/pPE1bzL5CXsHNf5ncCOENnX0uw9axDan1J84KK2pq9d8V+nQ ktAYkiWEYRZA== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga006.jf.intel.com ([10.7.209.51]) by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 30 Apr 2020 01:34:18 -0700 IronPort-SDR: b8mjuCFpk4HyJsvJJIk0tq+sbXX+X40etCsi6iswrND7LMzE4OsIzPiMFNrdBaeyLxGoo8WxH5 HNXpnO+gGUTA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.73,334,1583222400"; d="scan'208";a="261703228" Received: from orsmsx106.amr.corp.intel.com ([10.22.225.133]) by orsmga006.jf.intel.com with ESMTP; 30 Apr 2020 01:34:18 -0700 Received: from orsmsx111.amr.corp.intel.com (10.22.240.12) by ORSMSX106.amr.corp.intel.com (10.22.225.133) with Microsoft SMTP Server (TLS) id 14.3.439.0; Thu, 30 Apr 2020 01:34:18 -0700 Received: from ORSEDG002.ED.cps.intel.com (10.7.248.5) by ORSMSX111.amr.corp.intel.com (10.22.240.12) with Microsoft SMTP Server (TLS) id 14.3.439.0; Thu, 30 Apr 2020 01:34:17 -0700 Received: from NAM12-MW2-obe.outbound.protection.outlook.com (104.47.66.41) by edgegateway.intel.com (134.134.137.101) with Microsoft SMTP Server (TLS) id 14.3.439.0; Thu, 30 Apr 2020 01:34:12 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=jtse0YW1CzgU0doWGVSYxafTrtXqSnUFdiC1YUUspVJLyQrj45OdD/6RUNb7qAljHxqiheMS1DUeAtFrHzmAXGPeNXIeo0EBFajGt9Jfx9de1hAJNKsADNsP+ITMX6upTAONxTJJi6WGm5Zz8Vl+PYq3Mmswst9ynDjiXrgadTm0mKj4OrUYMSSy8tbGw7r8Ad9nv231PGN4w8lB5r0iFVmGlwxDHCacWZaUYAglLtohquvIkk2rOOo0UySTy1MVAUl+e3cQS7J38M6KeGgqyTjqixWhJn/Ymc5Ev7MrYFR0V4lg5cW9he+sZb3RKaz57c/rBRqpvU5+FOmyjX1/fg== 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=YPye/UJ2cUT0kWNpKRgOUkA+uiU97ZW7ZU/ZNbzGQpQ=; b=JzB9LVMof8LOKFAt+r+cXBqKP1iCyBcyYJOvtPuqZRBOQ9YIlTF/GlnYKd39Ob8wA94G6b5tJj4VvqAgFDoYbc2t37RlGa1MkPQYQ4yMEFhtRKGT8mVxAcVAaAldlcKzQRxfNp65pwI3RLuiD0Nd8yy/3DAL5v8uP7LwWOm+FTB0A94wlIUuolrPuVXFza0w+XPEmyangATsohZT3BRMDbdQci/sddktaJOzYrcRGNxHU+vpXTTGB+y8xpjKqlfYVMS97tFgxo9qqwN7GhGO4yFiEwpL3H0KOOFyRNmlLIlQwqn8fiCqZay7UNSzB80VMggtgBdKAjBmJVG426q7qg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel.onmicrosoft.com; s=selector2-intel-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=YPye/UJ2cUT0kWNpKRgOUkA+uiU97ZW7ZU/ZNbzGQpQ=; b=Dya9zRygTeSgQNKW1t1FP6m7p9oj545z2oS5kkWbGVvO3pkRC81tsGmcPOHI53ACMTUbxQeyR6K5RavKeGn3mQmeFGYKMWosPf5AIeofKE4g9mMXnUYvf4D8TxpYbld20GlLhorZRcYUympzpcoj6ZhlyVygnOhn2VZou5FMq7M= Received: from SN6PR11MB2814.namprd11.prod.outlook.com (2603:10b6:805:55::15) by SN6PR11MB3087.namprd11.prod.outlook.com (2603:10b6:805:d3::25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2958.19; Thu, 30 Apr 2020 08:33:56 +0000 Received: from SN6PR11MB2814.namprd11.prod.outlook.com ([fe80::152f:df2:6370:1584]) by SN6PR11MB2814.namprd11.prod.outlook.com ([fe80::152f:df2:6370:1584%4]) with mapi id 15.20.2937.023; Thu, 30 Apr 2020 08:33:56 +0000 From: "Chiu, Chasel" To: "Chaganty, Rangasai V" , "Kumar, Chandana C" , "devel@edk2.groups.io" CC: "Desimone, Nathaniel L" Subject: Re: [edk2-platforms: PATCH V1] MinPlatformPkg/PlatformInitPei: Create Library Instance of ReportCpuHobLib. Thread-Topic: [edk2-platforms: PATCH V1] MinPlatformPkg/PlatformInitPei: Create Library Instance of ReportCpuHobLib. Thread-Index: AQHWHrOjfvTJqUGewkuPWQafcsRt3qiRLPkAgAApnrA= Date: Thu, 30 Apr 2020 08:33:55 +0000 Message-ID: References: <20200430055206.75880-1-chandana.c.kumar@intel.com> In-Reply-To: Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-reaction: no-action dlp-version: 11.2.0.6 authentication-results: intel.com; dkim=none (message not signed) header.d=none;intel.com; dmarc=none action=none header.from=intel.com; x-originating-ip: [192.198.147.193] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 1de1b49f-1a5e-455f-545b-08d7ece138d1 x-ms-traffictypediagnostic: SN6PR11MB3087: x-ld-processed: 46c98d88-e344-4ed4-8496-4ed7712e255d,ExtAddr x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:7691; x-forefront-prvs: 0389EDA07F x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: lCY3DnQ1L4ca1l+RaHXny0BY5loptUJQA0tLnRQa06Ou/LzfPerd57HlT69ecGoZMOP1wjh67tUCpdYXYSy05A+RW4PJtWV6CRNHKXAHEzjCHlQ6quHZTiyQShXeLIFvJAar7OUkRL/Uf8JuVjUIPfFwe873IySvbvP7q8IeFj62vfGn99O78C3wV/zHtmRf3++q2fzhiqxozua8OIGWc7zd6Et7CHCrS5xfnKUucbftKY8RrnlIvU6P6fUQpgXHWULFxW/n/hxigrZ7GAw2hn6MFeXbChRDnlFWsHqXTPuHFmjPMYA5VETzFrNKrRjVZwYZtJAW8WCeGkZhXD/KQROHpkrwpFSHm5FehYV3fa+qv6nCsNbIwcpoZLcffVX+GUkBlkB/Ymhas8I2YIZ7H3uMoRRDVoAutle6opgk9AZiyVU/lfZn6/rXsPuEIavA4y6z1tXYC/xHDmUrhXdrVd2pcgnrW/V7d41MdbUrk7QWB51UBXqBAOJAeM2l9x8eOsyncgzTeNm6tt0Vp2rC5A== x-forefront-antispam-report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SN6PR11MB2814.namprd11.prod.outlook.com;PTR:;CAT:NONE;SFTY:;SFS:(376002)(39860400002)(396003)(136003)(366004)(346002)(52536014)(8676002)(33656002)(186003)(5660300002)(26005)(6506007)(53546011)(86362001)(7696005)(76116006)(66556008)(64756008)(66946007)(66476007)(66446008)(55016002)(2906002)(71200400001)(316002)(478600001)(8936002)(966005)(9686003)(4326008)(110136005)(107886003);DIR:OUT;SFP:1102; x-ms-exchange-antispam-messagedata: 0YVXYZj1QvgPGtMW2xQJEYJt2pp3iwQm+v3TycaSRHx4eIUceOXFhdA+joiB1WOU10pkQu9Gb2sp1QLZ3/IoYEIdFkvUiuJJJMMBcUyGdEXeZNcaLahLbzNzADRQ+Lg/LmuMkOiQx2yQrmCOSyEd9v6fesdzRlbLz95FixvnOyAldKMwCer/zCeYpjfUgn1uEJewF+YLFvSomxex4iK1h4py5zfUjn4hX4Hey4+YiyKopgSA6WY32D5j4vtfnYkbGJgSYE0Z+Y3/s1c0lELWWKoEyWFbxy46uzirZyVl0jckysxzHtYYt3aUMwPTkrHFk4JymGURWsQZd+N2WxW/zhECpO6HVXOIoYy2cI3H16rXxqAhqn28z4zAjsoD2A6UHiNmG9PVjysXuuhEVrz/xM1C7BlVawZo1OPTqcDAM9Lc7t8leXjKOuVgA5+DM5fmOJQ2qkuP0zhdhivU5akE8+V5LPxctMsW0fVRIiOdGo+z+CIwTHqYdnv0Gvr1agvlg5iqf1tjpCFpyx0sq1EjSSqD7pG/MMTqWUAsO6/jzXTXh+CRFj9C79tdLYbEl/rZ8Ju9LPwCPq7B7VEt4H6+Jjolu6Qk0iF9BjWaaKFoc/okZGliRXujmnNp5qk3Nx1Y6tJNIPO0hzbv+rtVQOHRIfHhsMmoxVgfn4QnZNSlrCZvPIIeBO5i6Yg1AV6VKATbPOiXhu8R2nEJSaQwqF+gSo5ay91ZJ7DsIov2lGZB0Nk7ndZG3zXNqDsTVFAiO/lgENmLU/6KpBQQDNpYYVTfgrox+bP2+IPQlOJ+oAYmGQ32JVBM+IYluFm/kOB/XPWj MIME-Version: 1.0 X-MS-Exchange-CrossTenant-Network-Message-Id: 1de1b49f-1a5e-455f-545b-08d7ece138d1 X-MS-Exchange-CrossTenant-originalarrivaltime: 30 Apr 2020 08:33:55.9255 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: NxyELF95zF9IXK9vQgRDKCUfDjcNAgIew269bP9OjN1pQLlWVp/I6/zMb9fXQ3RSbZMTyhxwITY/XC1PrAk2Lg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN6PR11MB3087 Return-Path: chasel.chiu@intel.com X-OriginatorOrg: intel.com Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Pushed: 4b24363cbfbe9498272dba86644caed365329610 Thanks, Chasel > -----Original Message----- > From: Chaganty, Rangasai V > Sent: Thursday, April 30, 2020 2:04 PM > To: Kumar, Chandana C ; > devel@edk2.groups.io > Cc: Chiu, Chasel ; Desimone, Nathaniel L > > Subject: RE: [edk2-platforms: PATCH V1] MinPlatformPkg/PlatformInitPei: > Create Library Instance of ReportCpuHobLib. >=20 > Reviewed-by: Sai Chaganty >=20 > -----Original Message----- > From: Kumar, Chandana C > Sent: Wednesday, April 29, 2020 10:52 PM > To: devel@edk2.groups.io > Cc: Chaganty, Rangasai V ; Chiu, Chasel > ; Desimone, Nathaniel L > > Subject: [edk2-platforms: PATCH V1] MinPlatformPkg/PlatformInitPei: Creat= e > Library Instance of ReportCpuHobLib. >=20 > Create an Library instance of ReportCpuHobLib from PlatformInitPei driver= . > PA bits reported can be overriden using Library instance in Platform. >=20 > REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D2674 >=20 > Signed-off-by: Chandana Kumar > Cc: Sai Chaganty > Cc: Chasel Chiu > Cc: Nate DeSimone > --- > Platform/Intel/MinPlatformPkg/Include/Library/ReportCpuHobLib.h > | 23 +++++++++++++++++++++++ > Platform/Intel/MinPlatformPkg/MinPlatformPkg.dec > | 6 ++++-- >=20 > Platform/Intel/MinPlatformPkg/PlatformInit/Library/ReportCpuHobLib/Repo > rtCpuHobLib.c | 32 ++++++++++++++++++++++++++++++++ >=20 > Platform/Intel/MinPlatformPkg/PlatformInit/Library/ReportCpuHobLib/Repo > rtCpuHobLib.inf | 27 +++++++++++++++++++++++++++ > 4 files changed, 86 insertions(+), 2 deletions(-) >=20 > diff --git > a/Platform/Intel/MinPlatformPkg/Include/Library/ReportCpuHobLib.h > b/Platform/Intel/MinPlatformPkg/Include/Library/ReportCpuHobLib.h > new file mode 100644 > index 0000000000..337e17f154 > --- /dev/null > +++ b/Platform/Intel/MinPlatformPkg/Include/Library/ReportCpuHobLib.h > @@ -0,0 +1,23 @@ > +/** @file > + > + Report CPU HOB library > + > + This library report the CPU HOB with Physical Address bits. > + > +Copyright (c) 2020, Intel Corporation. All rights reserved.
> +SPDX-License-Identifier: BSD-2-Clause-Patent > + > +**/ > + > +#ifndef _REPORT_CPU_HOB_LIB_H_ > +#define _REPORT_CPU_HOB_LIB_H_ > + > +#include > +#include > + > +VOID > +ReportCpuHob ( > + VOID > + ); > + > +#endif > diff --git a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dec > b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dec > index 5bec4eee3a..7ef189dac8 100644 > --- a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dec > +++ b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dec > @@ -6,7 +6,7 @@ > # INF files to generate AutoGen.c and AutoGen.h files # for the build > infrastructure. > # > -# Copyright (c) 2017 - 2019, Intel Corporation. All rights reserved.
> +# Copyright (c) 2017 - 2020, Intel Corporation. All rights > +reserved.
> # > # SPDX-License-Identifier: BSD-2-Clause-Patent # @@ -73,7 +73,9 @@ > TestPointLib|Include/Library/TestPointLib.h > TestPointCheckLib|Include/Library/TestPointCheckLib.h >=20 > -SetCacheMtrrLib|Include/Library/SetCacheMtrrLib.h > + SetCacheMtrrLib|Include/Library/SetCacheMtrrLib.h > + > + ReportCpuHobLib|Include/Library/ReportCpuHobLib.h >=20 > [PcdsFixedAtBuild, PcdsPatchableInModule] >=20 > diff --git > a/Platform/Intel/MinPlatformPkg/PlatformInit/Library/ReportCpuHobLib/Re > portCpuHobLib.c > b/Platform/Intel/MinPlatformPkg/PlatformInit/Library/ReportCpuHobLib/Re > portCpuHobLib.c > new file mode 100644 > index 0000000000..aa2565343c > --- /dev/null > +++ b/Platform/Intel/MinPlatformPkg/PlatformInit/Library/ReportCpuHobLib > +++ /ReportCpuHobLib.c > @@ -0,0 +1,32 @@ > +/** @file > + Source code file for Report CPU HOB library. > + > +Copyright (c) 2020, Intel Corporation. All rights reserved.
> +SPDX-License-Identifier: BSD-2-Clause-Patent > + > +**/ > + > +#include > +#include > + > +VOID > +ReportCpuHob ( > + VOID > + ) > +{ > + UINT8 PhysicalAddressBits; > + UINT32 RegEax; > + > + AsmCpuid (0x80000000, &RegEax, NULL, NULL, NULL); if (RegEax >=3D > + 0x80000008) { > + AsmCpuid (0x80000008, &RegEax, NULL, NULL, NULL); > + PhysicalAddressBits =3D (UINT8) RegEax; } else { > + PhysicalAddressBits =3D 36; > + } > + > + /// > + /// Create a CPU hand-off information /// BuildCpuHob > + (PhysicalAddressBits, 16); } > diff --git > a/Platform/Intel/MinPlatformPkg/PlatformInit/Library/ReportCpuHobLib/Re > portCpuHobLib.inf > b/Platform/Intel/MinPlatformPkg/PlatformInit/Library/ReportCpuHobLib/Re > portCpuHobLib.inf > new file mode 100644 > index 0000000000..a1830d4320 > --- /dev/null > +++ b/Platform/Intel/MinPlatformPkg/PlatformInit/Library/ReportCpuHobLib > +++ /ReportCpuHobLib.inf > @@ -0,0 +1,27 @@ > +### @file > +# Component information file for the Report CPU HOB library. > +# > +# Copyright (c) 2020, Intel Corporation. All rights reserved.
# # > +SPDX-License-Identifier: BSD-2-Clause-Patent # ### > + > +[Defines] > + INF_VERSION =3D 0x00010005 > + BASE_NAME =3D ReportCpuHobLib > + FILE_GUID =3D > F19AA754-CE24-448D-B755-1F939B00C25D > + VERSION_STRING =3D 1.0 > + MODULE_TYPE =3D BASE > + LIBRARY_CLASS =3D ReportCpuHobLib > + > +[LibraryClasses] > + BaseLib > + HobLib > + > +[Packages] > + MdePkg/MdePkg.dec > + MinPlatformPkg/MinPlatformPkg.dec > + > +[Sources] > + ReportCpuHobLib.c > -- > 2.16.2.windows.1