]> git.proxmox.com Git - mirror_edk2.git/commitdiff
UefiCpuPkg/MpInitLib: Set new AP to idle state after switching BSP
authorJeff Fan <jeff.fan@intel.com>
Mon, 26 Dec 2016 11:16:23 +0000 (19:16 +0800)
committerJeff Fan <jeff.fan@intel.com>
Wed, 28 Dec 2016 07:38:26 +0000 (15:38 +0800)
We need to set new AP to idle state if it is expected to be waken up by new BSP
later.

Cc: Feng Tian <feng.tian@intel.com>
Cc: Kinney Michael D <michael.d.kinney@intel.com>
Cc: Ruiyu Ni <ruiyu.ni@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Fan <jeff.fan@intel.com>
Reviewed-by: Feng Tian <feng.tian@intel.com>
UefiCpuPkg/Library/MpInitLib/MpLib.c

index 77d855a29a96eaf1212dd0b77dc99aca4c925501..78d18b616eb5e954feae419787adfd9530da6372 100644 (file)
@@ -1608,6 +1608,8 @@ SwitchBSPWorker (
   //\r
   if (!EnableOldBSP) {\r
     SetApState (&CpuMpData->CpuData[CallerNumber], CpuStateDisabled);\r
+  } else {\r
+    SetApState (&CpuMpData->CpuData[CallerNumber], CpuStateIdle);\r
   }\r
   //\r
   // Save new BSP number\r