Revision: 18012
http://sourceforge.net/p/edk2/code/18012
Author: vanjeff
Date: 2015-07-15 03:45:11 +0000 (Wed, 15 Jul 2015)
Log Message:
-----------
UefiCpuPkg/CpuMpPei: Install PI CPU MP PPI
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Fan <[email protected]>
Reviewed-by: Feng Tian <[email protected]>
Reviewed-by: Jiewen Yao <[email protected]>
Modified Paths:
--------------
trunk/edk2/UefiCpuPkg/CpuMpPei/CpuMpPei.c
trunk/edk2/UefiCpuPkg/CpuMpPei/CpuMpPei.h
trunk/edk2/UefiCpuPkg/CpuMpPei/CpuMpPei.inf
trunk/edk2/UefiCpuPkg/CpuMpPei/PeiMpServices.c
Modified: trunk/edk2/UefiCpuPkg/CpuMpPei/CpuMpPei.c
===================================================================
--- trunk/edk2/UefiCpuPkg/CpuMpPei/CpuMpPei.c 2015-07-15 03:44:42 UTC (rev
18011)
+++ trunk/edk2/UefiCpuPkg/CpuMpPei/CpuMpPei.c 2015-07-15 03:45:11 UTC (rev
18012)
@@ -436,7 +436,7 @@
IN CONST EFI_PEI_SERVICES **PeiServices
)
{
-
+ EFI_STATUS Status;
PEI_CPU_MP_DATA *PeiCpuMpData;
UINT32 ProcessorCount;
@@ -464,6 +464,11 @@
// Update and publish CPU BIST information
//
CollectBistDataFromPpi (PeiServices, PeiCpuMpData);
+ //
+ // Install CPU MP PPI
+ //
+ Status = PeiServicesInstallPpi(&mPeiCpuMpPpiDesc);
+ ASSERT_EFI_ERROR (Status);
- return EFI_SUCCESS;
+ return Status;
}
Modified: trunk/edk2/UefiCpuPkg/CpuMpPei/CpuMpPei.h
===================================================================
--- trunk/edk2/UefiCpuPkg/CpuMpPei/CpuMpPei.h 2015-07-15 03:44:42 UTC (rev
18011)
+++ trunk/edk2/UefiCpuPkg/CpuMpPei/CpuMpPei.h 2015-07-15 03:45:11 UTC (rev
18012)
@@ -140,7 +140,9 @@
PEI_CPU_DATA *CpuData;
volatile MP_CPU_EXCHANGE_INFO *MpCpuExchangeInfo;
};
+extern EFI_PEI_PPI_DESCRIPTOR mPeiCpuMpPpiDesc;
+
/**
Assembly code to get starting address and size of the rendezvous entry for
APs.
Information for fixing a jump instruction in the code is also returned.
Modified: trunk/edk2/UefiCpuPkg/CpuMpPei/CpuMpPei.inf
===================================================================
--- trunk/edk2/UefiCpuPkg/CpuMpPei/CpuMpPei.inf 2015-07-15 03:44:42 UTC (rev
18011)
+++ trunk/edk2/UefiCpuPkg/CpuMpPei/CpuMpPei.inf 2015-07-15 03:45:11 UTC (rev
18012)
@@ -68,6 +68,7 @@
UefiCpuLib
[Ppis]
+ gEfiPeiMpServicesPpiGuid ## PRODUCES
gEfiSecPlatformInformationPpiGuid ## SOMETIMES_CONSUMES
## SOMETIMES_CONSUMES
## SOMETIMES_PRODUCES
Modified: trunk/edk2/UefiCpuPkg/CpuMpPei/PeiMpServices.c
===================================================================
--- trunk/edk2/UefiCpuPkg/CpuMpPei/PeiMpServices.c 2015-07-15 03:44:42 UTC
(rev 18011)
+++ trunk/edk2/UefiCpuPkg/CpuMpPei/PeiMpServices.c 2015-07-15 03:45:11 UTC
(rev 18012)
@@ -14,7 +14,25 @@
#include "PeiMpServices.h"
+//
+// CPU MP PPI to be installed
+//
+EFI_PEI_MP_SERVICES_PPI mMpServicesPpi = {
+ PeiGetNumberOfProcessors,
+ PeiGetProcessorInfo,
+ PeiStartupAllAPs,
+ PeiStartupThisAP,
+ PeiSwitchBSP,
+ PeiEnableDisableAP,
+ PeiWhoAmI,
+};
+EFI_PEI_PPI_DESCRIPTOR mPeiCpuMpPpiDesc = {
+ (EFI_PEI_PPI_DESCRIPTOR_PPI | EFI_PEI_PPI_DESCRIPTOR_TERMINATE_LIST),
+ &gEfiPeiMpServicesPpiGuid,
+ &mMpServicesPpi
+};
+
/**
Get CPU Package/Core/Thread location information.
------------------------------------------------------------------------------
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-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/edk2-commits