mirror of https://github.com/acidanthera/audk.git
ArmPkg/DefaultExceptionHandlerLib: Replace the Print() by SerialOutputWrite() function
Print() is using the Console Output Protocol that cannot be available at the time of the exception. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12629 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
ce4b2bd4c2
commit
7755dfd3a5
|
@ -18,7 +18,9 @@
|
||||||
#include <Library/BaseLib.h>
|
#include <Library/BaseLib.h>
|
||||||
#include <Library/DebugLib.h>
|
#include <Library/DebugLib.h>
|
||||||
#include <Library/PeCoffGetEntryPointLib.h>
|
#include <Library/PeCoffGetEntryPointLib.h>
|
||||||
|
#include <Library/PrintLib.h>
|
||||||
#include <Library/ArmDisassemblerLib.h>
|
#include <Library/ArmDisassemblerLib.h>
|
||||||
|
#include <Library/SerialPortLib.h>
|
||||||
|
|
||||||
#include <Guid/DebugImageInfoTable.h>
|
#include <Guid/DebugImageInfoTable.h>
|
||||||
#include <Protocol/DebugSupport.h>
|
#include <Protocol/DebugSupport.h>
|
||||||
|
@ -220,12 +222,17 @@ DefaultExceptionHandler (
|
||||||
IN OUT EFI_SYSTEM_CONTEXT SystemContext
|
IN OUT EFI_SYSTEM_CONTEXT SystemContext
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
|
CHAR8 Buffer[100];
|
||||||
|
UINTN CharCount;
|
||||||
UINT32 DfsrStatus;
|
UINT32 DfsrStatus;
|
||||||
UINT32 IfsrStatus;
|
UINT32 IfsrStatus;
|
||||||
BOOLEAN DfsrWrite;
|
BOOLEAN DfsrWrite;
|
||||||
UINT32 PcAdjust = 0;
|
UINT32 PcAdjust = 0;
|
||||||
|
|
||||||
Print(L"\n%a Exception PC at 0x%08x CPSR 0x%08x ", gExceptionTypeString[ExceptionType], SystemContext.SystemContextArm->PC, SystemContext.SystemContextArm->CPSR);
|
CharCount = AsciiSPrint (Buffer,sizeof (Buffer),"\n%a Exception PC at 0x%08x CPSR 0x%08x ",
|
||||||
|
gExceptionTypeString[ExceptionType], SystemContext.SystemContextArm->PC, SystemContext.SystemContextArm->CPSR);
|
||||||
|
SerialPortWrite ((UINT8 *) Buffer, CharCount);
|
||||||
|
|
||||||
DEBUG_CODE_BEGIN ();
|
DEBUG_CODE_BEGIN ();
|
||||||
CHAR8 *Pdb;
|
CHAR8 *Pdb;
|
||||||
UINT32 ImageBase;
|
UINT32 ImageBase;
|
||||||
|
|
Loading…
Reference in New Issue