summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStar Zeng <star.zeng@intel.com>2016-01-29 16:24:10 +0800
committerStar Zeng <star.zeng@intel.com>2016-02-15 18:12:02 +0800
commit09159a29d1b9a35745a033fd6434df264a751d0e (patch)
tree96f87bcf241c01c2d557dd8d6ccd2c4a51603c6a
parent82ea9a6b59b5f4f48712644d9b32d4d52a097a2e (diff)
downloadedk2-platforms-09159a29d1b9a35745a033fd6434df264a751d0e.tar.xz
MdeModulePkg DxeCore: Missing change for OEM reserved memory type at R17460
At the end of CoreFreePoolI(), the check to see if it is a specific memory type should also cover OEM reserved memory type. It was missed when adding OEM reserved memory type support at R17460. Cc: Liming Gao <liming.gao@intel.com> Cc: Feng Tian <feng.tian@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
-rw-r--r--MdeModulePkg/Core/Dxe/Mem/Pool.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/MdeModulePkg/Core/Dxe/Mem/Pool.c b/MdeModulePkg/Core/Dxe/Mem/Pool.c
index e5fee1abfc..ad9a85feaf 100644
--- a/MdeModulePkg/Core/Dxe/Mem/Pool.c
+++ b/MdeModulePkg/Core/Dxe/Mem/Pool.c
@@ -1,7 +1,7 @@
/** @file
UEFI Memory pool management functions.
-Copyright (c) 2006 - 2015, Intel Corporation. All rights reserved.<BR>
+Copyright (c) 2006 - 2016, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -658,11 +658,11 @@ CoreFreePoolI (
}
//
- // If this is an OS specific memory type, then check to see if the last
+ // If this is an OS/OEM specific memory type, then check to see if the last
// portion of that memory type has been freed. If it has, then free the
// list entry for that memory type
//
- if ((INT32)Pool->MemoryType < 0 && Pool->Used == 0) {
+ if (((UINT32) Pool->MemoryType >= MEMORY_TYPE_OEM_RESERVED_MIN) && Pool->Used == 0) {
RemoveEntryList (&Pool->Link);
CoreFreePoolI (Pool);
}