From nobody Mon May 6 00:47:19 2024 Delivered-To: importer@patchew.org Received-SPF: none (zoho.com: 198.145.21.10 is neither permitted nor denied by domain of lists.01.org) client-ip=198.145.21.10; envelope-from=edk2-devel-bounces@lists.01.org; helo=ml01.01.org; Authentication-Results: mx.zohomail.com; spf=none (zoho.com: 198.145.21.10 is neither permitted nor denied by domain of lists.01.org) smtp.mailfrom=edk2-devel-bounces@lists.01.org Return-Path: Received: from ml01.01.org (ml01.01.org [198.145.21.10]) by mx.zohomail.com with SMTPS id 1505880166639723.2623468982064; Tue, 19 Sep 2017 21:02:46 -0700 (PDT) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id EFDB221E94612; Tue, 19 Sep 2017 20:59:39 -0700 (PDT) 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 CC18A21E87979 for ; Tue, 19 Sep 2017 20:59:37 -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 Received: from lgao4-mobl1.ccr.corp.intel.com ([10.255.27.1]) by fmsmga002.fm.intel.com with ESMTP; 19 Sep 2017 21:02:42 -0700 X-Original-To: edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.42,420,1500966000"; d="scan'208";a="1221252615" From: Liming Gao To: edk2-devel@lists.01.org Date: Wed, 20 Sep 2017 12:02:36 +0800 Message-Id: <20170920040237.13832-2-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: [edk2] [Patch 1/2] MdePkg: Correct EfiGcdMemoryTypePersistent name to follow PI spec 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: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Errors-To: edk2-devel-bounces@lists.01.org Sender: "edk2-devel" X-ZohoMail: RSF_4 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" PI spec defines EfiGcdMemoryTypePersistent name, MdePkg uses EfiGcdMemoryTypePersistentMemory name. So, EfiGcdMemoryTypePersistent is added. And, EfiGcdMemoryTypePersistentMemory is kept for compatility. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Liming Gao Reviewed-by: Star Zeng --- MdePkg/Include/Pi/PiDxeCis.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/MdePkg/Include/Pi/PiDxeCis.h b/MdePkg/Include/Pi/PiDxeCis.h index 3292809851..079dd3eab1 100644 --- a/MdePkg/Include/Pi/PiDxeCis.h +++ b/MdePkg/Include/Pi/PiDxeCis.h @@ -52,7 +52,11 @@ typedef enum { /// A memory region that is visible to the boot processor.=20 /// This memory supports byte-addressable non-volatility.=20 /// - EfiGcdMemoryTypePersistentMemory, + EfiGcdMemoryTypePersistent, + // + // Keep original one for the compatibility. + // + EfiGcdMemoryTypePersistentMemory =3D EfiGcdMemoryTypePersistent, /// /// A memory region that provides higher reliability relative to other m= emory in the /// system. If all memory has the same reliability, then this bit is not= used. --=20 2.11.0.windows.1 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel From nobody Mon May 6 00:47:19 2024 Delivered-To: importer@patchew.org Received-SPF: none (zoho.com: 198.145.21.10 is neither permitted nor denied by domain of lists.01.org) client-ip=198.145.21.10; envelope-from=edk2-devel-bounces@lists.01.org; helo=ml01.01.org; Authentication-Results: mx.zohomail.com; spf=none (zoho.com: 198.145.21.10 is neither permitted nor denied by domain of lists.01.org) smtp.mailfrom=edk2-devel-bounces@lists.01.org Return-Path: Received: from ml01.01.org (ml01.01.org [198.145.21.10]) by mx.zohomail.com with SMTPS id 1505880169037196.12823306496568; Tue, 19 Sep 2017 21:02:49 -0700 (PDT) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 344B021E94615; Tue, 19 Sep 2017 20:59:40 -0700 (PDT) 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 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 X-Original-To: edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.42,420,1500966000"; d="scan'208";a="1221252622" 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: [edk2] [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: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Errors-To: edk2-devel-bounces@lists.01.org Sender: "edk2-devel" X-ZohoMail: RSF_4 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Liming Gao Reviewed-by: Star Zeng --- 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/Gc= d.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 *mGcdMemoryTy= peNames[] =3D { "Reserved ", // EfiGcdMemoryTypeReserved "SystemMem", // EfiGcdMemoryTypeSystemMemory "MMIO ", // EfiGcdMemoryTypeMemoryMappedIo - "PersisMem", // EfiGcdMemoryTypePersistentMemory + "PersisMem", // EfiGcdMemoryTypePersistent "MoreRelia", // EfiGcdMemoryTypeMoreReliable "Unknown " // EfiGcdMemoryTypeMaximum }; @@ -2407,7 +2407,7 @@ CoreInitializeGcdServices ( GcdMemoryType =3D EfiGcdMemoryTypeReserved; } if ((ResourceHob->ResourceAttribute & EFI_RESOURCE_ATTRIBUTE_PERSI= STENT) =3D=3D EFI_RESOURCE_ATTRIBUTE_PERSISTENT) { - GcdMemoryType =3D EfiGcdMemoryTypePersistentMemory; + GcdMemoryType =3D EfiGcdMemoryTypePersistent; } break; case EFI_RESOURCE_MEMORY_MAPPED_IO: diff --git a/MdeModulePkg/Core/Dxe/Mem/Page.c b/MdeModulePkg/Core/Dxe/Mem/P= age.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 =3D 0; for (Link =3D mGcdMemorySpaceMap.ForwardLink; Link !=3D &mGcdMemorySpace= Map; Link =3D Link->ForwardLink) { GcdMapEntry =3D CR (Link, EFI_GCD_MAP_ENTRY, Link, EFI_GCD_MAP_SIGNATU= RE); - if ((GcdMapEntry->GcdMemoryType =3D=3D EfiGcdMemoryTypePersistentMemor= y) ||=20 + if ((GcdMapEntry->GcdMemoryType =3D=3D EfiGcdMemoryTypePersistent) ||=20 (GcdMapEntry->GcdMemoryType =3D=3D EfiGcdMemoryTypeReserved) || ((GcdMapEntry->GcdMemoryType =3D=3D EfiGcdMemoryTypeMemoryMappedIo= ) && ((GcdMapEntry->Attributes & EFI_MEMORY_RUNTIME) =3D=3D EFI_MEMORY_= RUNTIME))) { @@ -1783,7 +1783,7 @@ CoreGetMemoryMap ( MemoryMap =3D MergeMemoryMapDescriptor (MemoryMapStart, MemoryMap, S= ize); } =20 - if (MergeGcdMapEntry.GcdMemoryType =3D=3D EfiGcdMemoryTypePersistentMe= mory) { + if (MergeGcdMapEntry.GcdMemoryType =3D=3D EfiGcdMemoryTypePersistent) { // // Page Align GCD range is required. When it is converted to EFI_MEM= ORY_DESCRIPTOR,=20 // it will be recorded as page PhysicalStart and NumberOfPages.=20 --=20 2.11.0.windows.1 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel