From: "Chiu, Chasel" <chasel.chiu@intel.com>
To: "Kuo, IanX" <ianx.kuo@intel.com>,
"devel@edk2.groups.io" <devel@edk2.groups.io>
Cc: "Lu, James" <james.lu@intel.com>,
"Kumar, Chandana C" <chandana.c.kumar@intel.com>,
"Prabhala, Varalakshmi A" <varalakshmi.a.prabhala@intel.com>,
"Chaganty, Rangasai V" <rangasai.v.chaganty@intel.com>
Subject: Re: [edk2-platforms] [PATCH v6 6/6] Platform/Intel/MinPlatformPkg: Add ReportCpuHobLib.
Date: Tue, 21 Jul 2020 01:05:08 +0000 [thread overview]
Message-ID: <DM6PR11MB28093390C284F771EA9F50A3E6780@DM6PR11MB2809.namprd11.prod.outlook.com> (raw)
In-Reply-To: <cca2ffd8387cd66489908362ceab346d44196d4a.1595291556.git.ianx.kuo@intel.com>
Reviewed-by: Chasel Chiu <chasel.chiu@intel.com>
> -----Original Message-----
> From: Kuo, IanX <ianx.kuo@intel.com>
> Sent: Tuesday, July 21, 2020 8:37 AM
> To: devel@edk2.groups.io
> Cc: Lu, James <james.lu@intel.com>; Kumar, Chandana C
> <chandana.c.kumar@intel.com>; Prabhala, Varalakshmi A
> <varalakshmi.a.prabhala@intel.com>; Kuo, IanX <ianx.kuo@intel.com>;
> Chaganty, Rangasai V <rangasai.v.chaganty@intel.com>; Chiu, Chasel
> <chasel.chiu@intel.com>
> Subject: [edk2-platforms] [PATCH v6 6/6] Platform/Intel/MinPlatformPkg: Add
> ReportCpuHobLib.
>
> Create a Library instance of ReportCpuHobLib from PlatformInitPei driver.
> PA bits reported can be overridden by Library instance in Platform.
>
> REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2674
>
> Change-Id: I1c14aece3b229c194960e91dc9505dd8120bbe30
> Signed-off-by: IanX Kuo <ianx.kuo@intel.com>
> Cc: Sai Chaganty <rangasai.v.chaganty@intel.com>
> Cc: Chasel Chiu <chasel.chiu@intel.com>
> ---
> .../Intel/MinPlatformPkg/MinPlatformPkg.dsc | 3 ++-
> .../PlatformInitPei/PlatformInitPreMem.c | 25 ++-----------------
> .../PlatformInitPei/PlatformInitPreMem.inf | 3 ++-
> 3 files changed, 6 insertions(+), 25 deletions(-)
>
> diff --git a/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc
> b/Platform/Intel/MinPlatformPkg/MinPlatformPkg.dsc
> index 13a0fda2..b62351da 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.<BR>
>
> +# Copyright (c) 2017 - 2020, Intel Corporation. All rights reserved.<BR>
>
> #
>
> # SPDX-License-Identifier: BSD-2-Clause-Patent
>
> #
>
> @@ -92,6 +92,7 @@
> #
>
>
> FspWrapperPlatformLib|MinPlatformPkg/FspWrapper/Library/PeiFspWrappe
> rPlatformLib/PeiFspWrapperPlatformLib.inf
>
>
> ReportFvLib|MinPlatformPkg/PlatformInit/Library/PeiReportFvLib/PeiReport
> FvLib.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/SetCacheMtrrLib
> Null.inf
>
> diff --git
> a/Platform/Intel/MinPlatformPkg/PlatformInit/PlatformInitPei/PlatformInitPr
> eMem.c
> b/Platform/Intel/MinPlatformPkg/PlatformInit/PlatformInitPei/PlatformInitPr
> eMem.c
> index efdeb6a9..48cbe0df 100644
> ---
> a/Platform/Intel/MinPlatformPkg/PlatformInit/PlatformInitPei/PlatformInitPr
> eMem.c
> +++
> b/Platform/Intel/MinPlatformPkg/PlatformInit/PlatformInitPei/PlatformInitPr
> eMem.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.<BR>
>
> +Copyright (c) 2017 - 2020, Intel Corporation. All rights reserved.<BR>
>
> SPDX-License-Identifier: BSD-2-Clause-Patent
>
>
>
> **/
>
> @@ -26,6 +26,7 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
> #include <Library/BoardInitLib.h>
>
> #include <Library/TestPointCheckLib.h>
>
> #include <Library/SetCacheMtrrLib.h>
>
> +#include <Library/ReportCpuHobLib.h>
>
> #include <Guid/MemoryTypeInformation.h>
>
> #include <Ppi/PlatformMemorySize.h>
>
> #include <Ppi/BaseMemoryTest.h>
>
> @@ -355,28 +356,6 @@ Done:
> return EFI_SUCCESS;
>
> }
>
>
>
> -VOID
>
> -ReportCpuHob (
>
> - VOID
>
> - )
>
> -{
>
> - UINT8 PhysicalAddressBits;
>
> - UINT32 RegEax;
>
> -
>
> - AsmCpuid (0x80000000, &RegEax, NULL, NULL, NULL);
>
> - if (RegEax >= 0x80000008) {
>
> - AsmCpuid (0x80000008, &RegEax, NULL, NULL, NULL);
>
> - PhysicalAddressBits = (UINT8) RegEax;
>
> - } else {
>
> - PhysicalAddressBits = 36;
>
> - }
>
> -
>
> - ///
>
> - /// Create a CPU hand-off information
>
> - ///
>
> - BuildCpuHob (PhysicalAddressBits, 16);
>
> -}
>
> -
>
> /**
>
> Install Firmware Volume Hob's once there is main memory
>
>
>
> diff --git
> a/Platform/Intel/MinPlatformPkg/PlatformInit/PlatformInitPei/PlatformInitPr
> eMem.inf
> b/Platform/Intel/MinPlatformPkg/PlatformInit/PlatformInitPei/PlatformInitPr
> eMem.inf
> index 7ee18eb6..8e828ff2 100644
> ---
> a/Platform/Intel/MinPlatformPkg/PlatformInit/PlatformInitPei/PlatformInitPr
> eMem.inf
> +++
> b/Platform/Intel/MinPlatformPkg/PlatformInit/PlatformInitPei/PlatformInitPr
> eMem.inf
> @@ -1,7 +1,7 @@
> ### @file
>
> # Component information file for the Platform Init Pre-Memory PEI module.
>
> #
>
> -# Copyright (c) 2017 - 2019, Intel Corporation. All rights reserved.<BR>
>
> +# Copyright (c) 2017 - 2020, Intel Corporation. All rights reserved.<BR>
>
> #
>
> # SPDX-License-Identifier: BSD-2-Clause-Patent
>
> #
>
> @@ -28,6 +28,7 @@
> TestPointCheckLib
>
> TimerLib
>
> SetCacheMtrrLib
>
> + ReportCpuHobLib
>
>
>
> [Packages]
>
> MinPlatformPkg/MinPlatformPkg.dec
>
> --
> 2.26.2.windows.1
prev parent reply other threads:[~2020-07-21 1:05 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-21 0:35 [edk2-platforms] [PATCH v6 0/6] Create a Library instance of ReportCpuHobLib IanX Kuo
2020-07-21 0:35 ` [edk2-platforms] [PATCH v6 1/6] Platform/Intel/MinPlatformPkg: Fix build error IanX Kuo
2020-07-21 0:58 ` Chiu, Chasel
2020-07-21 2:12 ` [edk2-devel] " Liming Gao
2020-07-21 2:51 ` 回覆: " IanX Kuo
2020-07-21 0:35 ` [edk2-platforms] [PATCH v6 2/6] Platform/Intel/CometlakeOpenBoardPkg: Add ReportCpuHobLib IanX Kuo
2020-07-21 1:04 ` [edk2-devel] " Chiu, Chasel
2020-07-21 0:35 ` [edk2-platforms] [PATCH v6 3/6] Platform/Intel/KabylakeOpenBoardPkg: " IanX Kuo
2020-07-21 1:04 ` Chiu, Chasel
2020-07-21 0:36 ` [edk2-platforms] [PATCH v6 4/6] Platform/Intel/SimicsOpenBoardPkg: " IanX Kuo
2020-07-21 1:04 ` [edk2-devel] " Chiu, Chasel
2020-07-21 0:36 ` [edk2-platforms] [PATCH v6 5/6] Platform/Intel/WhiskeylakeOpenBoardPkg: " IanX Kuo
2020-07-21 1:04 ` Chiu, Chasel
2020-07-21 0:36 ` [edk2-platforms] [PATCH v6 6/6] Platform/Intel/MinPlatformPkg: " IanX Kuo
2020-07-21 1:05 ` Chiu, Chasel [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-list from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=DM6PR11MB28093390C284F771EA9F50A3E6780@DM6PR11MB2809.namprd11.prod.outlook.com \
--to=devel@edk2.groups.io \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox