summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorlgao4 <lgao4@6f19259b-4bc3-4df7-8a09-765794883524>2007-12-11 05:14:16 +0000
committerlgao4 <lgao4@6f19259b-4bc3-4df7-8a09-765794883524>2007-12-11 05:14:16 +0000
commitb2c5e194a80f85c733a57814dece83a4b816f07b (patch)
tree02fd5ba3fbde485b1189657ddf71c061b2473cf1
parentbc4b81899a51aac86479bbbf403f78f8d6ff1e0a (diff)
downloadedk2-platforms-b2c5e194a80f85c733a57814dece83a4b816f07b.tar.xz
Use AllocatePage for FvImage.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@4385 6f19259b-4bc3-4df7-8a09-765794883524
-rw-r--r--MdeModulePkg/Core/Dxe/Dispatcher/Dispatcher.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/MdeModulePkg/Core/Dxe/Dispatcher/Dispatcher.c b/MdeModulePkg/Core/Dxe/Dispatcher/Dispatcher.c
index d348c82a9e..01d2c9fe5a 100644
--- a/MdeModulePkg/Core/Dxe/Dispatcher/Dispatcher.c
+++ b/MdeModulePkg/Core/Dxe/Dispatcher/Dispatcher.c
@@ -894,8 +894,7 @@ Returns:
if (FvAlignment < 8) {
FvAlignment = 8;
}
-
- AlignedBuffer = AllocateAlignedPool ((UINTN) BufferSize, (UINTN) FvAlignment);
+ AlignedBuffer = AllocateAlignedPages (EFI_SIZE_TO_PAGES (BufferSize), (UINTN) FvAlignment);
if (AlignedBuffer == NULL) {
Status = EFI_OUT_OF_RESOURCES;
} else {
@@ -926,7 +925,7 @@ Returns:
}
if (AlignedBuffer != NULL) {
- FreeAlignedPool (AlignedBuffer);
+ FreeAlignedPages (AlignedBuffer, EFI_SIZE_TO_PAGES (BufferSize));
}
}