UefiCpuPkg: Build MpInfo2HOB in CpuMpPei

Build MpInfo2HOB in CpuMpPei module so that later
PiSmmCpuDxe or other StandaloneMm module can consume
the HOB.
Since there might be more one gMpInformationHobGuid2
in HOB list, CpuMpPei create a gMpInformationHobGuid2
with 0 value NumberOfProcessors field in the end of the
process to indicate it's the last MP_INFORMATION2_HOB.

Signed-off-by: Dun Tan <dun.tan@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Reviewed-by: Ray Ni <ray.ni@intel.com>
Cc: Rahul Kumar <rahul1.kumar@intel.com>
Cc: Gerd Hoffmann <kraxel@redhat.com>
This commit is contained in:
Dun Tan
2023-11-24 15:53:33 +08:00
committed by mergify[bot]
parent c02eed8e5a
commit e10f1f5a04
3 changed files with 96 additions and 2 deletions

View File

@@ -1,7 +1,7 @@
/** @file
Definitions to install Multiple Processor PPI.
Copyright (c) 2015 - 2021, Intel Corporation. All rights reserved.<BR>
Copyright (c) 2015 - 2023, Intel Corporation. All rights reserved.<BR>
SPDX-License-Identifier: BSD-2-Clause-Patent
**/
@@ -30,6 +30,8 @@
#include <Library/MemoryAllocationLib.h>
#include <Library/CpuPageTableLib.h>
#include <Guid/MpInformation2.h>
extern EFI_PEI_PPI_DESCRIPTOR mPeiCpuMpPpiDesc;
/**