Dump new stack base and size information could help developer to narrow down
stack crash issue.
Cc: Feng Tian <feng.tian@intel.com>
Cc: Liming Gao <liming.gao@intel.com>
Cc: Michael Kinney <michael.d.kinney@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Fan <jeff.fan@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
Reviewed-by: Feng Tian <feng.tian@intel.com>
\r
AsmWriteIdtr (&gLidtDescriptor);\r
\r
+ DEBUG ((\r
+ DEBUG_INFO,\r
+ "%a() Stack Base: 0x%lx, Stack Size: 0x%x\n",\r
+ __FUNCTION__,\r
+ BaseOfStack,\r
+ STACK_SIZE\r
+ ));\r
+\r
//\r
// Go to Long Mode and transfer control to DxeCore.\r
// Interrupts will not get turned on until the CPU AP is loaded.\r
//\r
UpdateStackHob (BaseOfStack, STACK_SIZE);\r
\r
+ DEBUG ((\r
+ DEBUG_INFO,\r
+ "%a() Stack Base: 0x%lx, Stack Size: 0x%x\n",\r
+ __FUNCTION__,\r
+ BaseOfStack,\r
+ STACK_SIZE\r
+ ));\r
+\r
//\r
// Transfer the control to the entry point of DxeCore.\r
//\r
//\r
AsmWriteCr3 ((UINTN) PageTableAddress);\r
\r
+ DEBUG ((\r
+ DEBUG_INFO,\r
+ "%a() Stack Base: 0x%lx, Stack Size: 0x%lx\n",\r
+ __FUNCTION__,\r
+ Context->StackBufferBase,\r
+ Context->StackBufferLength\r
+ ));\r
+\r
//\r
// Disable interrupt of Debug timer, since the IDT table cannot work in long mode\r
//\r
\r
ReturnContext->ReturnStatus = Status;\r
\r
+ DEBUG ((\r
+ DEBUG_INFO,\r
+ "%a() Stack Base: 0x%lx, Stack Size: 0x%lx\n",\r
+ __FUNCTION__,\r
+ EntrypointContext->StackBufferBase,\r
+ EntrypointContext->StackBufferLength\r
+ ));\r
+\r
//\r
// Disable interrupt of Debug timer, since the new IDT table cannot work in long mode\r
//\r