From 6fb389d0a180ae4e623c39d051a3ddb38515b614 Mon Sep 17 00:00:00 2001 From: Jeff Fan Date: Thu, 3 Nov 2016 15:47:06 +0800 Subject: MdeModulePkg: Display new stack base and size Dump new stack base and size information could help developer to narrow down stack crash issue. Cc: Feng Tian Cc: Liming Gao Cc: Michael Kinney Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jeff Fan Reviewed-by: Liming Gao Reviewed-by: Feng Tian --- MdeModulePkg/Core/DxeIplPeim/Ia32/DxeLoadFunc.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'MdeModulePkg/Core/DxeIplPeim') diff --git a/MdeModulePkg/Core/DxeIplPeim/Ia32/DxeLoadFunc.c b/MdeModulePkg/Core/DxeIplPeim/Ia32/DxeLoadFunc.c index 8ce72cb..6ec51ff 100644 --- a/MdeModulePkg/Core/DxeIplPeim/Ia32/DxeLoadFunc.c +++ b/MdeModulePkg/Core/DxeIplPeim/Ia32/DxeLoadFunc.c @@ -317,6 +317,14 @@ HandOffToDxeCore ( AsmWriteIdtr (&gLidtDescriptor); + DEBUG (( + DEBUG_INFO, + "%a() Stack Base: 0x%lx, Stack Size: 0x%x\n", + __FUNCTION__, + BaseOfStack, + STACK_SIZE + )); + // // Go to Long Mode and transfer control to DxeCore. // Interrupts will not get turned on until the CPU AP is loaded. @@ -387,6 +395,14 @@ HandOffToDxeCore ( // UpdateStackHob (BaseOfStack, STACK_SIZE); + DEBUG (( + DEBUG_INFO, + "%a() Stack Base: 0x%lx, Stack Size: 0x%x\n", + __FUNCTION__, + BaseOfStack, + STACK_SIZE + )); + // // Transfer the control to the entry point of DxeCore. // -- cgit v1.1