summaryrefslogtreecommitdiffstats
path: root/MdeModulePkg/Core/DxeIplPeim/DxeLoad.c
diff options
context:
space:
mode:
authorLiming Gao <liming.gao@intel.com>2018-01-10 13:33:29 +0800
committerLiming Gao <liming.gao@intel.com>2018-01-19 13:20:24 +0800
commit5367f17db4727a4d43ae3ab519c944e61463716d (patch)
tree016d64444ebffa6d7d39f34aa62eefaeab6559d5 /MdeModulePkg/Core/DxeIplPeim/DxeLoad.c
parentbc6a7a27ce119c256c4cd10111a7eb7917382e73 (diff)
downloadedk2-5367f17db4727a4d43ae3ab519c944e61463716d.tar.gz
edk2-5367f17db4727a4d43ae3ab519c944e61463716d.tar.bz2
edk2-5367f17db4727a4d43ae3ab519c944e61463716d.zip
MdeModulePkg DxeIpl: remove the hard code alignment adjustment.
Section data alignment should be made in the build generation. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Liming Gao <liming.gao@intel.com> Cc: Star Zeng <star.zeng@intel.com> Reviewed-by: Star Zeng <star.zeng@intel.com>
Diffstat (limited to 'MdeModulePkg/Core/DxeIplPeim/DxeLoad.c')
-rw-r--r--MdeModulePkg/Core/DxeIplPeim/DxeLoad.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/MdeModulePkg/Core/DxeIplPeim/DxeLoad.c b/MdeModulePkg/Core/DxeIplPeim/DxeLoad.c
index 1f626a9e86..f4d7528985 100644
--- a/MdeModulePkg/Core/DxeIplPeim/DxeLoad.c
+++ b/MdeModulePkg/Core/DxeIplPeim/DxeLoad.c
@@ -3,7 +3,7 @@
Responsibility of this module is to load the DXE Core from a Firmware Volume.
Copyright (c) 2016 HP Development Company, L.P.
-Copyright (c) 2006 - 2016, Intel Corporation. All rights reserved.<BR>
+Copyright (c) 2006 - 2018, 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
@@ -593,16 +593,11 @@ CustomGuidedSectionExtract (
//
// Allocate output buffer
//
- *OutputBuffer = AllocatePages (EFI_SIZE_TO_PAGES (OutputBufferSize) + 1);
+ *OutputBuffer = AllocatePages (EFI_SIZE_TO_PAGES (OutputBufferSize));
if (*OutputBuffer == NULL) {
return EFI_OUT_OF_RESOURCES;
}
DEBUG ((DEBUG_INFO, "Customized Guided section Memory Size required is 0x%x and address is 0x%p\n", OutputBufferSize, *OutputBuffer));
- //
- // *OutputBuffer still is one section. Adjust *OutputBuffer offset,
- // skip EFI section header to make section data at page alignment.
- //
- *OutputBuffer = (VOID *)((UINT8 *) *OutputBuffer + EFI_PAGE_SIZE - sizeof (EFI_COMMON_SECTION_HEADER));
}
Status = ExtractGuidedSectionDecode (