\r
CpuInitDataInitialize ();\r
\r
- //\r
- // Wakeup all APs for data collection.\r
- //\r
- StartupAPsWorker (CollectProcessorData, NULL);\r
+ if (CpuFeaturesData->NumberOfCpus > 1) {\r
+ //\r
+ // Wakeup all APs for data collection.\r
+ //\r
+ StartupAPsWorker (CollectProcessorData, NULL);\r
+ }\r
\r
//\r
// Collect data on BSP\r
OldBspNumber = GetProcessorIndex (CpuFeaturesData);\r
CpuFeaturesData->BspNumber = OldBspNumber;\r
\r
- Status = gBS->CreateEvent (\r
- EVT_NOTIFY_WAIT,\r
- TPL_CALLBACK,\r
- EfiEventEmptyFunction,\r
- NULL,\r
- &MpEvent\r
- );\r
- ASSERT_EFI_ERROR (Status);\r
+ if (CpuFeaturesData->NumberOfCpus > 1) {\r
+ Status = gBS->CreateEvent (\r
+ EVT_NOTIFY_WAIT,\r
+ TPL_CALLBACK,\r
+ EfiEventEmptyFunction,\r
+ NULL,\r
+ &MpEvent\r
+ );\r
+ ASSERT_EFI_ERROR (Status);\r
+\r
+ //\r
+ // Wakeup all APs for programming.\r
+ //\r
+ StartupAPsWorker (SetProcessorRegister, MpEvent);\r
+ }\r
\r
- //\r
- // Wakeup all APs for programming.\r
- //\r
- StartupAPsWorker (SetProcessorRegister, MpEvent);\r
//\r
// Programming BSP\r
//\r
SetProcessorRegister (CpuFeaturesData);\r
\r
- //\r
- // Wait all processors to finish the task.\r
- //\r
- do {\r
- Status = gBS->CheckEvent (MpEvent);\r
- } while (Status == EFI_NOT_READY);\r
- ASSERT_EFI_ERROR (Status);\r
+ if (CpuFeaturesData->NumberOfCpus > 1) {\r
+ //\r
+ // Wait all processors to finish the task.\r
+ //\r
+ do {\r
+ Status = gBS->CheckEvent (MpEvent);\r
+ } while (Status == EFI_NOT_READY);\r
+ ASSERT_EFI_ERROR (Status);\r
+ }\r
\r
//\r
// Switch to new BSP if required\r
// DXE type instance.\r
//\r
\r
- //\r
- // Wakeup all APs for programming.\r
- //\r
- StartupAPsWorker (SetProcessorRegister, NULL);\r
+ if (CpuFeaturesData->NumberOfCpus > 1) {\r
+ //\r
+ // Wakeup all APs for programming.\r
+ //\r
+ StartupAPsWorker (SetProcessorRegister, NULL);\r
+ }\r
+\r
//\r
// Programming BSP\r
//\r