Feng,

Good point. 
This module will be dispatched after memory is ready. Actually, Pei Core will 
shadow the PEI module (dispatched after memory is initialized) into memory 
automatically. 
PeiServicesRegisterForShadow () is not required more.

Best Regards,
Jeff
-----Original Message-----
From: Tian, Feng 
Sent: Tuesday, July 14, 2015 11:02 AM
To: Fan, Jeff; edk2-devel@lists.sourceforge.net
Cc: Tian, Feng
Subject: RE: [edk2] [Patch 00/28] UefiCpuPkg: Add CpuMpPei install PI CPU MP PPI

Shall you allow shadow in CpuMpPei driver entry point like below?
  //
  // Shadow this PEIM to run from memory
  //
  if (!EFI_ERROR (PeiServicesRegisterForShadow (FileHandle))) {
    return EFI_SUCCESS;
  }

Others look good to me

Reviewed-by: Feng Tian <feng.t...@intel.com>

-----Original Message-----
From: Jeff Fan [mailto:jeff....@intel.com]
Sent: Friday, July 03, 2015 11:10 PM
To: edk2-devel@lists.sourceforge.net
Subject: [edk2] [Patch 00/28] UefiCpuPkg: Add CpuMpPei install PI CPU MP PPI

PI 1.4 introduced CPU MP PPI to provide MP service in PEI.
This serial patches include:
A. Added three PCDs in UefiCpuPkg: PcdCpuApInitTimeOutInMicroSeconds,
   PcdCpuMicrocodePatchAddress and PcdCpuMicrocodePatchRegionSize.
B. Added some CPU ID definitions in Include\Register\LocalApic.h.
C. Added CpuMpPei driver in UefiCpuPkg.
   1. Prepare wakeup buffer and wakeup Aps to collect Aps count.
   2. Load GDT on BSP/Aps.
   3. Load microcode on BSP/Aps.
   4. Sync BSP's mtrr setting to Aps.
   5. Install CPU MP PPI to provide MP service in PEI defined in PI 1.4.
   6. Collect and publish Aps BIST information.

Jeff Fan (28):
  UefiCpuPkg: Add CpuMpPei module
  UefiCpuPkg/CpuMpPei: Load GDT table on BSP
  UefiCpuPkg/CpuMpPei: Find available memory < 1MB for AP reset code
  UefiCpuPkg/CpuMpPei: Add MP exchange structure definition
  UefiCpuPkg/CpuMpPei: Add AP reset IA32 assembly code
  UefiCpuPkg/CpuMpPei: Add AP reset x64 assembly code
  UefiCpuPkg/CpuMpPei: Initialize FPU per UEFI specification
  UefiCpuPkg/CpuMpPei: Get AP reset code size and far jump information
  UefiCpuPkg/CpuMpPei: Prepare for buffer for AP wakeup and CPU MP data
  UefiCpuPkg: Add PcdCpuApInitTimeOutInMicroSeconds
  UefiCpuPkg/CpuMpPei: Wakeup APs and collect AP count
  UefiCpuPkg/CpuMpPei: Sort APIC ID in ascending order
  UefiCpuPkg/CpuMpPei: Sync BPS's mtrr setting to APs
  UefiCpuPkg: Add microcode PCDs
  UefiCpuPkg: Add some CPUID definitions
  UefiCpuPkg/CpuMpPei: Load microcode on BSP and APs
  UefiCpuPkg/CpuMpPei: Build one GUIDed HOB to save CPU MP Data
  UefiCpuPkg/CpuMpPei: Update and publish CPU BIST information
  UefiCpuPkg/CpuMpPei: Implementation of PeiWhoAmI ()
  UefiCpuPkg/CpuMpPei: Implementation of PeiGetNumberOfProcessors ()
  UefiCpuPkg/CpuMpPei: Implementation of PeiGetProcessorInfo ()
  UefiCpuPkg/CpuMpPei: Implementation of PeiStartupAllAPs ()
  UefiCpuPkg/CpuMpPei: Implementation of PeiStartupThisAP ()
  UefiCpuPkg/CpuMpPei: Implementation of PeiSwitchBSP ()
  UefiCpuPkg/CpuMpPei: Implementation of PeiEnableDisableAP ()
  UefiCpuPkg/CpuMpPei: Install PI CPU MP PPI
  UefiCpuPkg/CpuMpPei: Add AsmHltLoop ()
  UefiCpuPkg/CpuMpPei: Register callback on End Of Pei PPI

 UefiCpuPkg/CpuMpPei/CpuBist.c           | 260 +++++++++
 UefiCpuPkg/CpuMpPei/CpuMpPei.c          | 565 +++++++++++++++++++
 UefiCpuPkg/CpuMpPei/CpuMpPei.h          | 302 ++++++++++
 UefiCpuPkg/CpuMpPei/CpuMpPei.inf        |  90 +++
 UefiCpuPkg/CpuMpPei/CpuMpPei.uni        | Bin 0 -> 1706 bytes
 UefiCpuPkg/CpuMpPei/CpuMpPeiExtra.uni   | Bin 0 -> 1344 bytes
 UefiCpuPkg/CpuMpPei/Ia32/MpEqu.inc      |  40 ++
 UefiCpuPkg/CpuMpPei/Ia32/MpFuncs.asm    | 276 +++++++++
 UefiCpuPkg/CpuMpPei/Ia32/MpFuncs.nasm   | 255 +++++++++
 UefiCpuPkg/CpuMpPei/Microcode.c         | 200 +++++++
 UefiCpuPkg/CpuMpPei/Microcode.h         |  68 +++
 UefiCpuPkg/CpuMpPei/PeiMpServices.c     | 960 ++++++++++++++++++++++++++++++++
 UefiCpuPkg/CpuMpPei/PeiMpServices.h     | 395 +++++++++++++
 UefiCpuPkg/CpuMpPei/X64/MpEqu.inc       |  45 ++
 UefiCpuPkg/CpuMpPei/X64/MpFuncs.asm     | 334 +++++++++++
 UefiCpuPkg/CpuMpPei/X64/MpFuncs.nasm    | 327 +++++++++++
 UefiCpuPkg/Include/Register/LocalApic.h |   6 +-
 UefiCpuPkg/UefiCpuPkg.dec               |  13 +-
 UefiCpuPkg/UefiCpuPkg.dsc               |   1 +
 19 files changed, 4135 insertions(+), 2 deletions(-)  create mode 100644 
UefiCpuPkg/CpuMpPei/CpuBist.c  create mode 100644 
UefiCpuPkg/CpuMpPei/CpuMpPei.c  create mode 100644 
UefiCpuPkg/CpuMpPei/CpuMpPei.h  create mode 100644 
UefiCpuPkg/CpuMpPei/CpuMpPei.inf  create mode 100644 
UefiCpuPkg/CpuMpPei/CpuMpPei.uni  create mode 100644 
UefiCpuPkg/CpuMpPei/CpuMpPeiExtra.uni
 create mode 100644 UefiCpuPkg/CpuMpPei/Ia32/MpEqu.inc
 create mode 100644 UefiCpuPkg/CpuMpPei/Ia32/MpFuncs.asm
 create mode 100644 UefiCpuPkg/CpuMpPei/Ia32/MpFuncs.nasm
 create mode 100644 UefiCpuPkg/CpuMpPei/Microcode.c  create mode 100644 
UefiCpuPkg/CpuMpPei/Microcode.h  create mode 100644 
UefiCpuPkg/CpuMpPei/PeiMpServices.c
 create mode 100644 UefiCpuPkg/CpuMpPei/PeiMpServices.h
 create mode 100644 UefiCpuPkg/CpuMpPei/X64/MpEqu.inc  create mode 100644 
UefiCpuPkg/CpuMpPei/X64/MpFuncs.asm
 create mode 100644 UefiCpuPkg/CpuMpPei/X64/MpFuncs.nasm

--
1.9.5.msysgit.0


------------------------------------------------------------------------------
Don't Limit Your Business. Reach for the Cloud.
GigeNET's Cloud Solutions provide you with the tools and support that you need 
to offload your IT needs and focus on growing your business.
Configured For All Businesses. Start Your Cloud Today.
https://www.gigenetcloud.com/
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/edk2-devel

------------------------------------------------------------------------------
Don't Limit Your Business. Reach for the Cloud.
GigeNET's Cloud Solutions provide you with the tools and support that
you need to offload your IT needs and focus on growing your business.
Configured For All Businesses. Start Your Cloud Today.
https://www.gigenetcloud.com/
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/edk2-devel

Reply via email to