From 091269232629660ef5b1997d66658c94b58b009d Mon Sep 17 00:00:00 2001 From: Jeff Fan Date: Wed, 2 Sep 2015 03:15:20 +0000 Subject: UefiCpuPkg/CpuMpPei: Update the old/new BSP state in SwitchBsp() (Sync patch r18372 from main trunk.) Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jeff Fan Reviewed-by: Feng Tian git-svn-id: https://svn.code.sf.net/p/edk2/code/branches/UDK2015@18380 6f19259b-4bc3-4df7-8a09-765794883524 --- UefiCpuPkg/CpuMpPei/PeiMpServices.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/UefiCpuPkg/CpuMpPei/PeiMpServices.c b/UefiCpuPkg/CpuMpPei/PeiMpServices.c index 503778fd93..625c24a6f4 100644 --- a/UefiCpuPkg/CpuMpPei/PeiMpServices.c +++ b/UefiCpuPkg/CpuMpPei/PeiMpServices.c @@ -804,6 +804,16 @@ PeiSwitchBSP ( ApicBaseMsr.Uint64 = AsmReadMsr64 (MSR_IA32_APIC_BASE_ADDRESS); ApicBaseMsr.Bits.Bsp = 1; AsmWriteMsr64 (MSR_IA32_APIC_BASE_ADDRESS, ApicBaseMsr.Uint64); + // + // Set old BSP enable state + // + if (!EnableOldBSP) { + PeiCpuMpData->CpuData[PeiCpuMpData->BspNumber].State = CpuStateDisabled; + } + // + // Save new BSP number + // + PeiCpuMpData->BspNumber = (UINT32) ProcessorNumber; return EFI_SUCCESS; } -- cgit v1.2.3