summaryrefslogtreecommitdiff
path: root/MdeModulePkg/Core/Dxe/Misc/MemoryAttributesTable.c
diff options
context:
space:
mode:
authorJiewen Yao <jiewen.yao@intel.com>2016-02-23 12:43:57 +0800
committerHao Wu <hao.a.wu@intel.com>2016-02-25 11:23:43 +0800
commit82f0f411c7912de105d1484fd294bde8aacb6c1e (patch)
tree00d5c3c6cef23160c6f786397beffe2ca9bb2fdf /MdeModulePkg/Core/Dxe/Misc/MemoryAttributesTable.c
parent97033ebfa3cb10562c434a8927e2cba9e3940ec7 (diff)
downloadedk2-platforms-82f0f411c7912de105d1484fd294bde8aacb6c1e.tar.xz
MdeModulePkg: Fix Memory Attributes table type issue
According to the spec, each entry in the Memory Attributes table shall have the same type as the region it was carved out of in the UEFI memory map. The current attribute uses RTData for PE Data, but it should be RTCode. This patch fixed the issue. It is validated with or without PropertiesTable. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: "Yao, Jiewen" <jiewen.yao@intel.com> Tested-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Liming Gao <liming.gao@intel.com>
Diffstat (limited to 'MdeModulePkg/Core/Dxe/Misc/MemoryAttributesTable.c')
-rw-r--r--MdeModulePkg/Core/Dxe/Misc/MemoryAttributesTable.c6
1 files changed, 0 insertions, 6 deletions
diff --git a/MdeModulePkg/Core/Dxe/Misc/MemoryAttributesTable.c b/MdeModulePkg/Core/Dxe/Misc/MemoryAttributesTable.c
index c84146a8e8..416ed3dca8 100644
--- a/MdeModulePkg/Core/Dxe/Misc/MemoryAttributesTable.c
+++ b/MdeModulePkg/Core/Dxe/Misc/MemoryAttributesTable.c
@@ -72,8 +72,6 @@ CoreGetMemoryMapPropertiesTable (
extern EFI_PROPERTIES_TABLE mPropertiesTable;
-BOOLEAN mIsConstructingMemoryAttributesTable = FALSE;
-
/**
Install MemoryAttributesTable.
@@ -105,8 +103,6 @@ InstallMemoryAttributesTable (
return ;
}
- mIsConstructingMemoryAttributesTable = TRUE;
-
MemoryMapSize = 0;
MemoryMap = NULL;
Status = CoreGetMemoryMapPropertiesTable (
@@ -181,8 +177,6 @@ InstallMemoryAttributesTable (
Status = gBS->InstallConfigurationTable (&gEfiMemoryAttributesTableGuid, MemoryAttributesTable);
ASSERT_EFI_ERROR (Status);
-
- mIsConstructingMemoryAttributesTable = FALSE;
}
/**