]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdePkg/Include/Protocol/DebugSupport.h
Fix file headers and a few comments
[mirror_edk2.git] / MdePkg / Include / Protocol / DebugSupport.h
index deb9c29016038ae9f2971b68ef612e69bb909dc2..e3b0d02e31602f72e953169aed1f88b24133615e 100644 (file)
@@ -5,7 +5,8 @@
   The DebugSupport protocol is used by source level debuggers to abstract the\r
   processor and handle context save and restore operations.\r
 \r
-  Copyright (c) 2006 - 2009, Intel Corporation                                                         \r
+  Copyright (c) 2006 - 2009, Intel Corporation<BR>       \r
+  Portions copyright (c) 2008-2009 Apple Inc. All rights reserved.<BR>\r
   All rights reserved. This program and the accompanying materials                          \r
   are licensed and made available under the terms and conditions of the BSD License         \r
   which accompanies this distribution.  The full text of the license may be found at        \r
@@ -19,7 +20,6 @@
 #ifndef __DEBUG_SUPPORT_H__\r
 #define __DEBUG_SUPPORT_H__\r
 \r
-#include <ProcessorBind.h>\r
 #include <IndustryStandard/PeImage.h>\r
 \r
 typedef struct _EFI_DEBUG_SUPPORT_PROTOCOL EFI_DEBUG_SUPPORT_PROTOCOL;\r
@@ -286,7 +286,7 @@ typedef struct {
 typedef struct {\r
   //\r
   // The first reserved field is necessary to preserve alignment for the correct\r
-  // bits in UNAT and to insure F2 is 16 byte aligned..\r
+  // bits in UNAT and to insure F2 is 16 byte aligned.\r
   //\r
   UINT64  Reserved;\r
   UINT64  R1;\r
@@ -472,6 +472,52 @@ typedef struct {
   UINT64  Ip;\r
 } EFI_SYSTEM_CONTEXT_EBC;\r
 \r
+\r
+\r
+///\r
+///  ARM processor exception types\r
+///\r
+#define EXCEPT_ARM_RESET                    0\r
+#define EXCEPT_ARM_UNDEFINED_INSTRUCTION    1\r
+#define EXCEPT_ARM_SOFTWARE_INTERRUPT       2\r
+#define EXCEPT_ARM_PREFETCH_ABORT           3\r
+#define EXCEPT_ARM_DATA_ABORT               4\r
+#define EXCEPT_ARM_RESERVED                 5\r
+#define EXCEPT_ARM_IRQ                      6\r
+#define EXCEPT_ARM_FIQ                      7\r
+\r
+///\r
+/// For coding convenience, define the maximum valid ARM exception.\r
+///\r
+#define MAX_ARM_EXCEPTION EXCEPT_ARM_FIQ\r
+\r
+///\r
+///  ARM processor context definition\r
+///\r
+typedef struct {\r
+  UINT32  R0;\r
+  UINT32  R1;\r
+  UINT32  R2;\r
+  UINT32  R3;\r
+  UINT32  R4;\r
+  UINT32  R5;\r
+  UINT32  R6;\r
+  UINT32  R7;\r
+  UINT32  R8;\r
+  UINT32  R9;\r
+  UINT32  R10;\r
+  UINT32  R11;\r
+  UINT32  R12;\r
+  UINT32  SP;\r
+  UINT32  LR;\r
+  UINT32  PC;\r
+  UINT32  CPSR;\r
+  UINT32  DFSR;\r
+  UINT32  DFAR;\r
+  UINT32  IFSR;\r
+  UINT32  IFAR;\r
+} EFI_SYSTEM_CONTEXT_ARM;\r
+\r
 ///\r
 /// Universal EFI_SYSTEM_CONTEXT definition\r
 ///\r
@@ -480,6 +526,7 @@ typedef union {
   EFI_SYSTEM_CONTEXT_IA32 *SystemContextIa32;\r
   EFI_SYSTEM_CONTEXT_X64  *SystemContextX64;\r
   EFI_SYSTEM_CONTEXT_IPF  *SystemContextIpf;\r
+  EFI_SYSTEM_CONTEXT_ARM  *SystemContextArm;\r
 } EFI_SYSTEM_CONTEXT;\r
 \r
 //\r
@@ -516,10 +563,11 @@ VOID
 /// Machine type definition\r
 ///\r
 typedef enum {\r
-  IsaIa32 = IMAGE_FILE_MACHINE_I386,  ///< 0x014C\r
-  IsaX64  = IMAGE_FILE_MACHINE_X64,   ///< 0x8664\r
-  IsaIpf  = IMAGE_FILE_MACHINE_IA64,  ///< 0x0200\r
-  IsaEbc  = IMAGE_FILE_MACHINE_EBC    ///< 0x0EBC\r
+  IsaIa32 = IMAGE_FILE_MACHINE_I386,           ///< 0x014C\r
+  IsaX64  = IMAGE_FILE_MACHINE_X64,            ///< 0x8664\r
+  IsaIpf  = IMAGE_FILE_MACHINE_IA64,           ///< 0x0200\r
+  IsaEbc  = IMAGE_FILE_MACHINE_EBC,            ///< 0x0EBC\r
+  IsaArm  = IMAGE_FILE_MACHINE_ARMTHUMB_MIXED  ///< 0x01c2\r
 } EFI_INSTRUCTION_SET_ARCHITECTURE;\r
 \r
 \r