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.web12.9340.1586931523471377104 for ; Tue, 14 Apr 2020 23:18:44 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@intel.onmicrosoft.com header.s=selector2-intel-onmicrosoft-com header.b=C3UFTMYi; spf=pass (domain: intel.com, ip: 134.134.136.126, mailfrom: chasel.chiu@intel.com) IronPort-SDR: MdSTaZyJWJFMuT0RvpsaDu6j1nu3uHPlss/vWa2nBvTJ16lyNbUa2vCazMkX+XKIVogqgeWanj ETu2WCkdgeXg== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga001.jf.intel.com ([10.7.209.18]) by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 14 Apr 2020 23:18:42 -0700 IronPort-SDR: U8Kcs34hk1+8TbEQ4DQj534zIU9f/oNyc7E9fyhcIdXQfpXGeOiTuL4LlhRFy2qma+yEWf6yXX ICY1IexI1YDQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.72,385,1580803200"; d="scan'208";a="332406174" Received: from fmsmsx103.amr.corp.intel.com ([10.18.124.201]) by orsmga001.jf.intel.com with ESMTP; 14 Apr 2020 23:18:42 -0700 Received: from fmsmsx119.amr.corp.intel.com (10.18.124.207) by FMSMSX103.amr.corp.intel.com (10.18.124.201) with Microsoft SMTP Server (TLS) id 14.3.439.0; Tue, 14 Apr 2020 23:18:42 -0700 Received: from FMSEDG002.ED.cps.intel.com (10.1.192.134) by FMSMSX119.amr.corp.intel.com (10.18.124.207) with Microsoft SMTP Server (TLS) id 14.3.439.0; Tue, 14 Apr 2020 23:18:41 -0700 Received: from NAM10-DM6-obe.outbound.protection.outlook.com (104.47.58.100) by edgegateway.intel.com (192.55.55.69) with Microsoft SMTP Server (TLS) id 14.3.439.0; Tue, 14 Apr 2020 23:18:38 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=NUbz2Bkh/LxJbG7jw5+OQwIg9tR2w0qmwRJrjnXaBjY6pCXq+IfoZiZue/qPf0oxuFDZ6lmLX0OxfYUCTtRHUuupbUKDSYPfkzC854P7u4fF7bWQ0a6avLH2zTcRjgUrBdAB7lytGSB29BVzNv6JorT+D9j+IjyZfimdnJhgxOshFyImvlFHEh8gzB357FNb6bN+J1pksxpNe8q5jVzEaGG7T4Nwdm777SFpCxnwbFgPvyMrEJuHIXeIC+h25qbca75tY2kDHtwJdYwTp/ImMMNLfVMW1TR2S4tgC137XELTL3zHqhAtSZ9n0SjRXoWs5zIKGYiaCT3LkTQ3bgktiA== 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=3ZOFFtEaiwt1tWue/kWlyTCcQLoDjDGwi7VxgAMWCVQ=; b=T6WGjce0uu0b1+JV9Qtzf8qJYrCONp5IwZaZ4s5mDpxtL83HGiPzpYLjvyUntX7790OXpOJxYTygCb9G1FQf2HX8pSyXxmAsnizs8GMe9xcGL3oT+ZiDisS7YrtErsAeNWDkKtZzACfUuNvY8mTPj3Hm7Fh6lvTQnrarZKocSaUZ+tHqpfqNuKOYl/A4ofSr2i1Z+68Zuap5z4zic49VJ7b0F6JlK18fcS5OQ6kDtXtoNywlTJqRjlbJtJ02q2J9Y4byemoF3my+/jqKTdHpGAeMMivSUlkI8JokJdjK5B3d9MyG7JupycZFUyBZgdHTWv5mSOzU7bhvA4WpBdqeXg== 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=3ZOFFtEaiwt1tWue/kWlyTCcQLoDjDGwi7VxgAMWCVQ=; b=C3UFTMYikJuZFlKCo0AeDOkvJjYFcDiYJvd6SZHEpQKwfJuqT0rVvqn0YLmJht/z7maqTvvFkpAM5VrrQhd6NmDTF4nBJrE5+wO7OaMzfz1gn29JeYjJ7AWcFAcRJP4d8v4/R4fPMB64I4NSO4c51sngNYgPHKiL8cPoZGeekKM= Received: from SN6PR11MB2814.namprd11.prod.outlook.com (2603:10b6:805:55::15) by SN6PR11MB2653.namprd11.prod.outlook.com (2603:10b6:805:63::20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2900.26; Wed, 15 Apr 2020 06:18:36 +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.2900.028; Wed, 15 Apr 2020 06:18:36 +0000 From: "Chiu, Chasel" To: "Kumar, Chandana C" , "devel@edk2.groups.io" CC: "Chaganty, Rangasai V" , "Desimone, Nathaniel L" Subject: Re: [Patch V2] MinPlatformPkg/PlatformInitPei: Create Library Instance of ReportCpuHobLib. Thread-Topic: [Patch V2] MinPlatformPkg/PlatformInitPei: Create Library Instance of ReportCpuHobLib. Thread-Index: AQHWEmvuYfM+N+0ab0S8767lD3SAIKh5tgYw Date: Wed, 15 Apr 2020 06:18:36 +0000 Message-ID: References: <20200414144904.45356-1-chandana.c.kumar@intel.com> In-Reply-To: <20200414144904.45356-1-chandana.c.kumar@intel.com> 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: spf=none (sender IP is ) smtp.mailfrom=chasel.chiu@intel.com; x-originating-ip: [192.198.147.211] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 04e6054c-51d5-4762-9268-08d7e104d50f x-ms-traffictypediagnostic: SN6PR11MB2653: 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:8882; x-forefront-prvs: 0374433C81 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:(10019020)(376002)(346002)(396003)(39860400002)(136003)(366004)(5660300002)(186003)(66476007)(53546011)(110136005)(66556008)(76116006)(66446008)(52536014)(7696005)(478600001)(64756008)(54906003)(966005)(26005)(316002)(30864003)(33656002)(4326008)(6506007)(8676002)(81156014)(55016002)(66946007)(107886003)(2906002)(71200400001)(9686003)(8936002)(86362001);DIR:OUT;SFP:1102; x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: FBCznZYYZxNdW62dL43iuuE7FFnIi8BKTc1LxBfwE/SGRAv18tVbmSqvjF/Np3CLzCWzYPUdjdVq0aMoMMHDVv8HIW7lySKgIcEHNOZKMhNnAu4cpEyQCE8a1lAO3iI2/7B6voJ3Y332GYi2sAYAUHN7S3Y4vqIee9ztct/f0YnlDeGqfjhI9AYNc9bdzpGPRuCP7LTchUvhr3M7Iy8trjGf8qjU014XS6RZMUMh095asffVQQPjd9oC/3LrH27r6e9WxFDd5z9Hi387/IchvGOs8tpizimydpTFSH/kfAOIEHKMDeqHDXiK/pYQd0tZ/kuKXaZiXKHlISnkEcsyf4zcONBCVv9ANnskDfPuokA5a/uIh0rXHbsB8SWpQLSZhKMQ4EoQuy08eICkUCjTCfX+wx7DHV9LIMcL/SPUOC4ZmyiOIrUHpA4EPgW/Lm7AZkNt39wZ88LALBwEplwLJPC06vMUakWRE0kyx1XkxdgnOja9rU3c8k9VyFTbHbLWdOqfvmPPzfkK0Ti7pMeAIw== x-ms-exchange-antispam-messagedata: Yi+uZa2ZCbPdEcINRykAYY1M+Rvm+HXwpaPiodFsx8PCUQErRy8MOQ8Wd/nLHEFj+/RPh9npopof2SIbB2w5Zm6sWGENtrIf02WJvjJ/cYABJ9BrcXVrLLoDEmrpWQJdk6wJMymOTzsTiowiufS9Vg== MIME-Version: 1.0 X-MS-Exchange-CrossTenant-Network-Message-Id: 04e6054c-51d5-4762-9268-08d7e104d50f X-MS-Exchange-CrossTenant-originalarrivaltime: 15 Apr 2020 06:18:36.5141 (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: Vh7mAjIHi7yOvtDOaRqjjWlE3tDOlER2FVHFo+OaFqPI7IZvv8X49EHETATWGHOTWGr9eiCaXO/kqBIQwSCAzg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN6PR11MB2653 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 Hi Chandana, Your commit message format a little weird, please help to correct it. Please also update MinPlatformPkg.dec/[LibraryClasses] section for new libr= ary class this patch introduced. Thanks, Chasel > -----Original Message----- > From: Kumar, Chandana C > Sent: Tuesday, April 14, 2020 10:49 PM > To: devel@edk2.groups.io > Cc: Chaganty, Rangasai V ; Chiu, Chasel > ; Desimone, Nathaniel L > > Subject: [Patch V2] MinPlatformPkg/PlatformInitPei: Create Library Instan= ce > of ReportCpuHobLib. >=20 > Create an Library instance of ReportCpuHobLib from PlatformInitPei driver= , >=20 > so that from platform side reporting Physical address bits can be overrid= en. >=20 > REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D2674 >=20 > Signed-off-by: Chandana Kumar >=20 > Cc: Sai Chaganty >=20 > Cc: Chasel Chiu >=20 > Cc: Nate DeSimone > --- > 0001-MinPlatformPkg-PlatformInitPei-Create-an-Library-Ins.patch > | 167 > ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ > ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ > +++++++++++++++++++++++++++++++++++++++ > Platform/Intel/MinPlatformPkg/Include/Library/ReportCpuHobLib.h > | 23 +++++++++++++++++++++++ > Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc > | 3 ++- >=20 > Platform/Intel/MinPlatformPkg/PlatformInit/Library/ReportCpuHobLib/Repo > rtCpuHobLib.c | 32 ++++++++++++++++++++++++++++++++ >=20 > Platform/Intel/MinPlatformPkg/PlatformInit/Library/ReportCpuHobLib/Repo > rtCpuHobLib.inf | 27 +++++++++++++++++++++++++++ >=20 > Platform/Intel/MinPlatformPkg/PlatformInit/PlatformInitPei/PlatformInitPr= e > Mem.c | 25 ++----------------------- > 6 files changed, 253 insertions(+), 24 deletions(-) >=20 > diff --git a/0001-MinPlatformPkg-PlatformInitPei-Create-an-Library-Ins.pa= tch > b/0001-MinPlatformPkg-PlatformInitPei-Create-an-Library-Ins.patch > new file mode 100644 > index 0000000000..6df277b8e7 > --- /dev/null > +++ b/0001-MinPlatformPkg-PlatformInitPei-Create-an-Library-Ins.patch > @@ -0,0 +1,167 @@ > +From 987a6ff35c4e415593e0441d86b6dab6cc5d4f5d Mon Sep 17 00:00:00 > 2001 > +From: Chandana Kumar > +Date: Tue, 14 Apr 2020 16:57:23 +0530 > +Subject: [Patch V1] MinPlatformPkg/PlatformInitPei: Create Library Insta= nce > of ReportCpuHobLib. > + > +REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D2674 > + > +Create an Library instance of ReportCpuHobLib from PlatformInitPei > +driver, so that from platform side reporting Physical address bits can b= e > overriden. > + > +Signed-off-by: Chandana Kumar > +Cc: Sai Chaganty > +Cc: Chasel Chiu > +Cc: Nate DeSimone > +--- > + Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc > | 3 ++- > + > Platform/Intel/MinPlatformPkg/PlatformInit/Library/ReportCpuHobLib/Repo > rtCpuHobLib.c | 32 ++++++++++++++++++++++++++++++++ > + > Platform/Intel/MinPlatformPkg/PlatformInit/Library/ReportCpuHobLib/Repo > rtCpuHobLib.inf | 27 +++++++++++++++++++++++++++ > + > Platform/Intel/MinPlatformPkg/PlatformInit/PlatformInitPei/PlatformInitPr= e > Mem.c | 25 ++----------------------- > + 4 files changed, 63 insertions(+), 24 deletions(-) > + > +diff --git a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc > +b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc > +index 13a0fda272..b62351dac6 100644 > +--- a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc > ++++ b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc > +@@ -1,7 +1,7 @@ > + ## @file > + # Platform description. > + # > +-# 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 # @@ -92,6 +92,7 @@ > + # > + > FspWrapperPlatformLib|MinPlatformPkg/FspWrapper/Library/PeiFspWrappe > rPlatformLib/PeiFspWrapperPlatformLib.inf > + > +ReportFvLib|MinPlatformPkg/PlatformInit/Library/PeiReportFvLib/PeiRepor > +tFvLib.inf > ++ > ++ > ReportCpuHobLib|MinPlatformPkg/PlatformInit/Library/ReportCpuHobLib/R > ++ eportCpuHobLib.inf > + > TestPointCheckLib|MinPlatformPkg/Test/Library/TestPointCheckLib/PeiTestPo > intCheckLib.inf > + > TestPointLib|MinPlatformPkg/Test/Library/TestPointLib/PeiTestPointLib.inf > + > +SetCacheMtrrLib|MinPlatformPkg/Library/SetCacheMtrrLib/SetCacheMtrrLi > bN > +ull.inf diff --git > +a/Platform/Intel/MinPlatformPkg/PlatformInit/Library/ReportCpuHobLib/Re > +portCpuHobLib.c > +b/Platform/Intel/MinPlatformPkg/PlatformInit/Library/ReportCpuHobLib/R > e > +portCpuHobLib.c > +new file mode 100644 > +index 0000000000..b20b8c61a9 > +--- /dev/null > ++++ b/Platform/Intel/MinPlatformPkg/PlatformInit/Library/ReportCpuHobLi > ++++ b/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); } > +\ No newline at end of file > +diff --git > +a/Platform/Intel/MinPlatformPkg/PlatformInit/Library/ReportCpuHobLib/Re > +portCpuHobLib.inf > +b/Platform/Intel/MinPlatformPkg/PlatformInit/Library/ReportCpuHobLib/R > e > +portCpuHobLib.inf > +new file mode 100644 > +index 0000000000..ae6ec901a1 > +--- /dev/null > ++++ b/Platform/Intel/MinPlatformPkg/PlatformInit/Library/ReportCpuHobLi > ++++ b/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] > ++ PeiReportFvLib.c > +diff --git > +a/Platform/Intel/MinPlatformPkg/PlatformInit/PlatformInitPei/PlatformIn > +itPreMem.c > +b/Platform/Intel/MinPlatformPkg/PlatformInit/PlatformInitPei/PlatformIn > +itPreMem.c > +index efdeb6a91c..48cbe0dfbe 100644 > +--- > +a/Platform/Intel/MinPlatformPkg/PlatformInit/PlatformInitPei/PlatformIn > +itPreMem.c > ++++ b/Platform/Intel/MinPlatformPkg/PlatformInit/PlatformInitPei/Platfo > ++++ rmInitPreMem.c > +@@ -1,7 +1,7 @@ > + /** @file > + Source code file for Platform Init Pre-Memory PEI module > + > +-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 > + > + **/ > +@@ -26,6 +26,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent > +#include #include > + #include > ++#include > + #include #include > + #include @@ > -355,28 > ++356,6 @@ Done: > + return EFI_SUCCESS; > + } > + > +-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); -} > +- > + /** > + Install Firmware Volume Hob's once there is main memory > + > +-- > +2.16.2.windows.1 > + > diff --git > a/Platform/Intel/MinPlatformPkg/Include/Library/ReportCpuHobLib.h > b/Platform/Intel/MinPlatformPkg/Include/Library/ReportCpuHobLib.h > new file mode 100644 > index 0000000000..1b023007ca > --- /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 > \ No newline at end of file > diff --git a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc > b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc > index 13a0fda272..b62351dac6 100644 > --- a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc > +++ b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc > @@ -1,7 +1,7 @@ > ## @file > # Platform description. > # > -# 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 # @@ -92,6 +92,7 @@ > # >=20 > FspWrapperPlatformLib|MinPlatformPkg/FspWrapper/Library/PeiFspWrappe > rPlatformLib/PeiFspWrapperPlatformLib.inf >=20 > ReportFvLib|MinPlatformPkg/PlatformInit/Library/PeiReportFvLib/PeiReport > FvLib.inf > + > + > ReportCpuHobLib|MinPlatformPkg/PlatformInit/Library/ReportCpuHobLib/R > e > + portCpuHobLib.inf >=20 > TestPointCheckLib|MinPlatformPkg/Test/Library/TestPointCheckLib/PeiTestPo > intCheckLib.inf >=20 > TestPointLib|MinPlatformPkg/Test/Library/TestPointLib/PeiTestPointLib.inf >=20 > SetCacheMtrrLib|MinPlatformPkg/Library/SetCacheMtrrLib/SetCacheMtrrLib > Null.inf > 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..b20b8c61a9 > --- /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); } > \ No newline at end of file > 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..ae6ec901a1 > --- /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] > + PeiReportFvLib.c > diff --git > a/Platform/Intel/MinPlatformPkg/PlatformInit/PlatformInitPei/PlatformInit= Pr > eMem.c > b/Platform/Intel/MinPlatformPkg/PlatformInit/PlatformInitPei/PlatformInit= Pr > eMem.c > index efdeb6a91c..48cbe0dfbe 100644 > --- > a/Platform/Intel/MinPlatformPkg/PlatformInit/PlatformInitPei/PlatformInit= Pr > eMem.c > +++ b/Platform/Intel/MinPlatformPkg/PlatformInit/PlatformInitPei/Platfor > +++ mInitPreMem.c > @@ -1,7 +1,7 @@ > /** @file > Source code file for Platform Init Pre-Memory PEI module >=20 > -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 >=20 > **/ > @@ -26,6 +26,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent #include > #include #includ= e > > +#include > #include #include > #include @@ > -355,28 +356,6 @@ Done: > return EFI_SUCCESS; > } >=20 > -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); -} > - > /** > Install Firmware Volume Hob's once there is main memory >=20 > -- > 2.16.2.windows.1