mirror of
https://github.com/acidanthera/audk.git
synced 2025-07-23 13:44:33 +02:00
UefiCpuPkg/MpLib: Remove NotifyOnS3SmmInitDonePpi
Previously, the SMM S3 resume code required taking control of APs to perform SMM rebase, which would overwrite the context set by MpLib. As a result, MpLib needed to wake up APs using InitSipiSipi to restore the context after SMM S3 resume. With the recent change where SMM rebase occurs in the early PEI phase, the SMM S3 resume code no longer modifies AP context. Therefore, the forced use of InitSipiSipi after SMM S3 resume is no longer necessary. Signed-off-by: Zhiguang Liu <zhiguang.liu@intel.com>
This commit is contained in:
parent
6f17bd5eaf
commit
0bae161fed
@ -87,7 +87,6 @@
|
||||
gEdkiiPeiShadowMicrocodePpiGuid ## SOMETIMES_CONSUMES
|
||||
|
||||
[Guids]
|
||||
gEdkiiS3SmmInitDoneGuid
|
||||
gEdkiiMicrocodePatchHobGuid
|
||||
gGhcbApicIdsGuid ## SOMETIMES_CONSUMES
|
||||
gEdkiiEndOfS3ResumeGuid
|
||||
|
@ -14,68 +14,6 @@
|
||||
|
||||
STATIC UINT64 mSevEsPeiWakeupBuffer = BASE_1MB;
|
||||
|
||||
/**
|
||||
S3 SMM Init Done notification function.
|
||||
|
||||
@param PeiServices Indirect reference to the PEI Services Table.
|
||||
@param NotifyDesc Address of the notification descriptor data structure.
|
||||
@param InvokePpi Address of the PPI that was invoked.
|
||||
|
||||
@retval EFI_SUCCESS The function completes successfully.
|
||||
|
||||
**/
|
||||
EFI_STATUS
|
||||
EFIAPI
|
||||
NotifyOnS3SmmInitDonePpi (
|
||||
IN EFI_PEI_SERVICES **PeiServices,
|
||||
IN EFI_PEI_NOTIFY_DESCRIPTOR *NotifyDesc,
|
||||
IN VOID *InvokePpi
|
||||
);
|
||||
|
||||
//
|
||||
// Global function
|
||||
//
|
||||
EFI_PEI_NOTIFY_DESCRIPTOR mS3SmmInitDoneNotifyDesc = {
|
||||
EFI_PEI_PPI_DESCRIPTOR_NOTIFY_CALLBACK | EFI_PEI_PPI_DESCRIPTOR_TERMINATE_LIST,
|
||||
&gEdkiiS3SmmInitDoneGuid,
|
||||
NotifyOnS3SmmInitDonePpi
|
||||
};
|
||||
|
||||
/**
|
||||
S3 SMM Init Done notification function.
|
||||
|
||||
@param PeiServices Indirect reference to the PEI Services Table.
|
||||
@param NotifyDesc Address of the notification descriptor data structure.
|
||||
@param InvokePpi Address of the PPI that was invoked.
|
||||
|
||||
@retval EFI_SUCCESS The function completes successfully.
|
||||
|
||||
**/
|
||||
EFI_STATUS
|
||||
EFIAPI
|
||||
NotifyOnS3SmmInitDonePpi (
|
||||
IN EFI_PEI_SERVICES **PeiServices,
|
||||
IN EFI_PEI_NOTIFY_DESCRIPTOR *NotifyDesc,
|
||||
IN VOID *InvokePpi
|
||||
)
|
||||
{
|
||||
CPU_MP_DATA *CpuMpData;
|
||||
|
||||
CpuMpData = GetCpuMpData ();
|
||||
|
||||
//
|
||||
// PiSmmCpuDxeSmm driver hardcode change the loop mode to HLT mode.
|
||||
// So in this notify function, code need to check the current loop
|
||||
// mode, if it is not HLT mode, code need to change loop mode back
|
||||
// to the original mode.
|
||||
//
|
||||
if (CpuMpData->ApLoopMode != ApInHltLoop) {
|
||||
CpuMpData->WakeUpByInitSipiSipi = TRUE;
|
||||
}
|
||||
|
||||
return EFI_SUCCESS;
|
||||
}
|
||||
|
||||
/**
|
||||
Enable Debug Agent to support source debugging on AP function.
|
||||
|
||||
@ -510,8 +448,6 @@ InitMpGlobalData (
|
||||
///
|
||||
/// Install Notify
|
||||
///
|
||||
Status = PeiServicesNotifyPpi (&mS3SmmInitDoneNotifyDesc);
|
||||
ASSERT_EFI_ERROR (Status);
|
||||
|
||||
Status = PeiServicesNotifyPpi (&mEndOfS3ResumeNotifyDesc);
|
||||
ASSERT_EFI_ERROR (Status);
|
||||
|
Loading…
x
Reference in New Issue
Block a user