From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id A805521E87979 for ; Tue, 19 Sep 2017 20:59:38 -0700 (PDT) Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by fmsmga101.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 19 Sep 2017 21:02:43 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.42,420,1500966000"; d="scan'208";a="1221252622" Received: from lgao4-mobl1.ccr.corp.intel.com ([10.255.27.1]) by fmsmga002.fm.intel.com with ESMTP; 19 Sep 2017 21:02:43 -0700 From: Liming Gao To: edk2-devel@lists.01.org Date: Wed, 20 Sep 2017 12:02:37 +0800 Message-Id: <20170920040237.13832-3-liming.gao@intel.com> X-Mailer: git-send-email 2.11.0.windows.1 In-Reply-To: <20170920040237.13832-1-liming.gao@intel.com> References: <20170920040237.13832-1-liming.gao@intel.com> Subject: [Patch 2/2] MdeModulePkg: Update DxeCore to consume PI EfiGcdMemoryTypePersistent X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 20 Sep 2017 03:59:38 -0000 Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Liming Gao --- MdeModulePkg/Core/Dxe/Gcd/Gcd.c | 4 ++-- MdeModulePkg/Core/Dxe/Mem/Page.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/MdeModulePkg/Core/Dxe/Gcd/Gcd.c b/MdeModulePkg/Core/Dxe/Gcd/Gcd.c index a06f8bb77c..4f03b3e408 100644 --- a/MdeModulePkg/Core/Dxe/Gcd/Gcd.c +++ b/MdeModulePkg/Core/Dxe/Gcd/Gcd.c @@ -108,7 +108,7 @@ GLOBAL_REMOVE_IF_UNREFERENCED CONST CHAR8 *mGcdMemoryTypeNames[] = { "Reserved ", // EfiGcdMemoryTypeReserved "SystemMem", // EfiGcdMemoryTypeSystemMemory "MMIO ", // EfiGcdMemoryTypeMemoryMappedIo - "PersisMem", // EfiGcdMemoryTypePersistentMemory + "PersisMem", // EfiGcdMemoryTypePersistent "MoreRelia", // EfiGcdMemoryTypeMoreReliable "Unknown " // EfiGcdMemoryTypeMaximum }; @@ -2407,7 +2407,7 @@ CoreInitializeGcdServices ( GcdMemoryType = EfiGcdMemoryTypeReserved; } if ((ResourceHob->ResourceAttribute & EFI_RESOURCE_ATTRIBUTE_PERSISTENT) == EFI_RESOURCE_ATTRIBUTE_PERSISTENT) { - GcdMemoryType = EfiGcdMemoryTypePersistentMemory; + GcdMemoryType = EfiGcdMemoryTypePersistent; } break; case EFI_RESOURCE_MEMORY_MAPPED_IO: diff --git a/MdeModulePkg/Core/Dxe/Mem/Page.c b/MdeModulePkg/Core/Dxe/Mem/Page.c index a142c79ee2..3dd6d1b4a0 100644 --- a/MdeModulePkg/Core/Dxe/Mem/Page.c +++ b/MdeModulePkg/Core/Dxe/Mem/Page.c @@ -1635,7 +1635,7 @@ CoreGetMemoryMap ( NumberOfEntries = 0; for (Link = mGcdMemorySpaceMap.ForwardLink; Link != &mGcdMemorySpaceMap; Link = Link->ForwardLink) { GcdMapEntry = CR (Link, EFI_GCD_MAP_ENTRY, Link, EFI_GCD_MAP_SIGNATURE); - if ((GcdMapEntry->GcdMemoryType == EfiGcdMemoryTypePersistentMemory) || + if ((GcdMapEntry->GcdMemoryType == EfiGcdMemoryTypePersistent) || (GcdMapEntry->GcdMemoryType == EfiGcdMemoryTypeReserved) || ((GcdMapEntry->GcdMemoryType == EfiGcdMemoryTypeMemoryMappedIo) && ((GcdMapEntry->Attributes & EFI_MEMORY_RUNTIME) == EFI_MEMORY_RUNTIME))) { @@ -1783,7 +1783,7 @@ CoreGetMemoryMap ( MemoryMap = MergeMemoryMapDescriptor (MemoryMapStart, MemoryMap, Size); } - if (MergeGcdMapEntry.GcdMemoryType == EfiGcdMemoryTypePersistentMemory) { + if (MergeGcdMapEntry.GcdMemoryType == EfiGcdMemoryTypePersistent) { // // Page Align GCD range is required. When it is converted to EFI_MEMORY_DESCRIPTOR, // it will be recorded as page PhysicalStart and NumberOfPages. -- 2.11.0.windows.1