From dee9376ffc6e5522bb5e50512b521952a5421fa5 Mon Sep 17 00:00:00 2001 From: Jordan Justen Date: Thu, 13 Nov 2014 18:30:09 +0000 Subject: [PATCH] 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 --- UefiCpuPkg/CpuDxe/CpuMp.c | 3 +++ 1 file changed, 3 insertions(+) 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)); -- 2.39.2