MdeModulePkg: Update Dxe to handle unaccepted memory type
RFC: https://bugzilla.tianocore.org/show_bug.cgi?id=3937 Unaccepted memory is a kind of new memory type, CoreInitializeGcdServices() and CoreGetMemoryMap() are updated to handle the unaccepted memory type. Ref: microsoft/mu_basecore@97e9c31 Cc: Jian J Wang <jian.j.wang@intel.com> Cc: Liming Gao <gaoliming@byosoft.com.cn> Cc: Ray Ni <ray.ni@intel.com> Cc: Erdem Aktas <erdemaktas@google.com> Cc: Gerd Hoffmann <kraxel@redhat.com> Cc: James Bottomley <jejb@linux.ibm.com> Cc: Jiewen Yao <jiewen.yao@intel.com> Cc: Tom Lendacky <thomas.lendacky@amd.com> Acked-by: Gerd Hoffmann <kraxel@redhat.com> Reviewed-by: Liming Gao <gaoliming@byosoft.com.cn> Signed-off-by: Min Xu <min.m.xu@intel.com>
This commit is contained in:
@@ -8,6 +8,8 @@ SPDX-License-Identifier: BSD-2-Clause-Patent
|
||||
|
||||
**/
|
||||
|
||||
#include <Pi/PrePiDxeCis.h>
|
||||
#include <Pi/PrePiHob.h>
|
||||
#include "DxeMain.h"
|
||||
#include "Gcd.h"
|
||||
#include "Mem/HeapGuard.h"
|
||||
@@ -103,6 +105,7 @@ GLOBAL_REMOVE_IF_UNREFERENCED CONST CHAR8 *mGcdMemoryTypeNames[] = {
|
||||
"MMIO ", // EfiGcdMemoryTypeMemoryMappedIo
|
||||
"PersisMem", // EfiGcdMemoryTypePersistent
|
||||
"MoreRelia", // EfiGcdMemoryTypeMoreReliable
|
||||
"Unaccepte", // EFI_GCD_MEMORY_TYPE_UNACCEPTED
|
||||
"Unknown " // EfiGcdMemoryTypeMaximum
|
||||
};
|
||||
|
||||
@@ -2600,6 +2603,9 @@ CoreInitializeGcdServices (
|
||||
case EFI_RESOURCE_MEMORY_RESERVED:
|
||||
GcdMemoryType = EfiGcdMemoryTypeReserved;
|
||||
break;
|
||||
case BZ3937_EFI_RESOURCE_MEMORY_UNACCEPTED:
|
||||
GcdMemoryType = EFI_GCD_MEMORY_TYPE_UNACCEPTED;
|
||||
break;
|
||||
case EFI_RESOURCE_IO:
|
||||
GcdIoType = EfiGcdIoTypeIo;
|
||||
break;
|
||||
|
Reference in New Issue
Block a user