From: Jordan Justen Date: Thu, 13 Nov 2014 18:30:09 +0000 (+0000) Subject: UefiCpuPkg/CpuDxe: Startup APs X-Git-Tag: edk2-stable201903~10640 X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=commitdiff_plain;h=dee9376ffc6e5522bb5e50512b521952a5421fa5 UefiCpuPkg/CpuDxe: Startup APs This sequence should happen: * CpuMp.c: Allocate a stack for the APs * ApStartup.c: Send Start IPI to wake APs in 16-bit real mode * MpAsm.S: AP enters CpuDxe driver code without stack - AP grabs a lock - AP sets up stack - AP calls CpuMp.c:ApEntryPointInC Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jordan Justen Signed-off-by: Chen Fan Reviewed-by: Jeff Fan git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16370 6f19259b-4bc3-4df7-8a09-765794883524 --- diff --git a/UefiCpuPkg/CpuDxe/CpuMp.c b/UefiCpuPkg/CpuDxe/CpuMp.c index 5d5c7db765..2bc9f70bbb 100644 --- a/UefiCpuPkg/CpuDxe/CpuMp.c +++ b/UefiCpuPkg/CpuDxe/CpuMp.c @@ -1500,6 +1500,9 @@ InitializeMpSupport ( PrepareAPStartupCode (); + StartApsStackless (); + + DEBUG ((DEBUG_INFO, "Detect CPU count: %d\n", mMpSystemData.NumberOfProcessors)); if (mMpSystemData.NumberOfProcessors == 1) { FreeApStartupCode (); FreePages (mCommonStack, EFI_SIZE_TO_PAGES (gMaxLogicalProcessorNumber * gApStackSize));