UefiCpuPkg:Remove code to wakeup AP and relocate ap
After the code to load mtrr setting, set register table, handle APIC setting and Interrupt after INIT-SIPI-SIPI is moved, the InitializeCpuProcedure() only contains following code logic: 1.Bsp runs ExecuteFirstSmiInit(). 2.Bsp transfers AP to safe hlt-loop During S3 boot, since APs will be relocated to new safe buffer by the callback of gEdkiiEndOfS3ResumeGuid in PeiMpLib, Bsp doesn't need to transfer AP to safe hlt-loop any more. SmmRestoreCpu() in CpuS3 only needs to runs the ExecuteFirstSmiInit() on BSP. So remove code to wakeup AP by INIT-SIPI-SIPI and remove code to relocate ap to safe hlt-loop. Signed-off-by: Dun Tan <dun.tan@intel.com> Reviewed-by: Ray Ni <ray.ni@intel.com> Cc: Rahul Kumar <rahul1.kumar@intel.com> Cc: Gerd Hoffmann <kraxel@redhat.com> Reviewed-by: Jiaxin Wu <jiaxin.wu@intel.com>
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
/** @file
|
||||
SMM CPU misc functions for Ia32 arch specific.
|
||||
|
||||
Copyright (c) 2015 - 2023, Intel Corporation. All rights reserved.<BR>
|
||||
Copyright (c) 2015 - 2024, Intel Corporation. All rights reserved.<BR>
|
||||
SPDX-License-Identifier: BSD-2-Clause-Patent
|
||||
|
||||
**/
|
||||
@@ -141,33 +141,6 @@ InitGdt (
|
||||
return GdtTssTables;
|
||||
}
|
||||
|
||||
/**
|
||||
Transfer AP to safe hlt-loop after it finished restore CPU features on S3 patch.
|
||||
|
||||
@param[in] ApHltLoopCode The address of the safe hlt-loop function.
|
||||
@param[in] TopOfStack A pointer to the new stack to use for the ApHltLoopCode.
|
||||
@param[in] NumberToFinishAddress Address of Semaphore of APs finish count.
|
||||
|
||||
**/
|
||||
VOID
|
||||
TransferApToSafeState (
|
||||
IN UINTN ApHltLoopCode,
|
||||
IN UINTN TopOfStack,
|
||||
IN UINTN NumberToFinishAddress
|
||||
)
|
||||
{
|
||||
SwitchStack (
|
||||
(SWITCH_STACK_ENTRY_POINT)ApHltLoopCode,
|
||||
(VOID *)NumberToFinishAddress,
|
||||
NULL,
|
||||
(VOID *)TopOfStack
|
||||
);
|
||||
//
|
||||
// It should never reach here
|
||||
//
|
||||
ASSERT (FALSE);
|
||||
}
|
||||
|
||||
/**
|
||||
Initialize the shadow stack related data structure.
|
||||
|
||||
|
Reference in New Issue
Block a user