summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormdkinney <mdkinney@6f19259b-4bc3-4df7-8a09-765794883524>2006-11-09 22:05:07 +0000
committermdkinney <mdkinney@6f19259b-4bc3-4df7-8a09-765794883524>2006-11-09 22:05:07 +0000
commit5a0c25f8177525999683c4dc875217c3eab93d29 (patch)
tree196aebe94eb6f20088c323773620179f2f42e516
parent395859376eb5342ea1fd06f0c8d8682be8921d6f (diff)
downloadedk2-5a0c25f8177525999683c4dc875217c3eab93d29.zip
edk2-5a0c25f8177525999683c4dc875217c3eab93d29.tar.gz
edk2-5a0c25f8177525999683c4dc875217c3eab93d29.tar.bz2
Use CPU_STACK_ALIGNMENT to align stack allocated for used in the DXE Phase.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@1925 6f19259b-4bc3-4df7-8a09-765794883524
-rw-r--r--EdkModulePkg/Core/DxeIplX64Peim/DxeLoadX64.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/EdkModulePkg/Core/DxeIplX64Peim/DxeLoadX64.c b/EdkModulePkg/Core/DxeIplX64Peim/DxeLoadX64.c
index c7d6dd7..c9792ee 100644
--- a/EdkModulePkg/Core/DxeIplX64Peim/DxeLoadX64.c
+++ b/EdkModulePkg/Core/DxeIplX64Peim/DxeLoadX64.c
@@ -262,7 +262,8 @@ Returns:
// Compute the top of the stack we were allocated. Pre-allocate a 32 bytes
// for safety (PpisNeededByDxe and DxeCore).
//
- TopOfStack = BaseOfStack + EFI_SIZE_TO_PAGES (STACK_SIZE) * EFI_PAGE_SIZE - 32;
+ TopOfStack = BaseOfStack + EFI_SIZE_TO_PAGES (STACK_SIZE) * EFI_PAGE_SIZE - CPU_STACK_ALIGNMENT;
+ TopOfStack = ALIGN_POINTER (TopOfStack, CPU_STACK_ALIGNMENT);
//
// Add architecture-specifc HOBs (including the BspStore HOB)