]>
Commit | Line | Data |
---|---|---|
878ddf1f | 1 | /*++\r |
2 | \r | |
3 | Copyright (c) 2006, Intel Corporation \r | |
4 | All rights reserved. This program and the accompanying materials \r | |
5 | are licensed and made available under the terms and conditions of the BSD License \r | |
6 | which accompanies this distribution. The full text of the license may be found at \r | |
7 | http://opensource.org/licenses/bsd-license.php \r | |
8 | \r | |
9 | THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, \r | |
10 | WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. \r | |
11 | \r | |
12 | Module Name:\r | |
13 | \r | |
14 | DebugAssert.h\r | |
15 | \r | |
16 | Abstract:\r | |
17 | \r | |
18 | This protocol allows provides debug services to a driver. This is not \r | |
19 | debugger support, but things like ASSERT() and DEBUG() macros\r | |
20 | \r | |
21 | --*/\r | |
22 | \r | |
23 | #ifndef _DEBUG_ASSERT_H_\r | |
24 | #define _DEBUG_ASSERT_H_\r | |
25 | \r | |
26 | \r | |
27 | #define EFI_DEBUG_ASSERT_PROTOCOL_GUID \\r | |
28 | { 0xbe499c92, 0x7d4b, 0x11d4, {0xbc, 0xee, 0x0, 0x80, 0xc7, 0x3c, 0x88, 0x81 } }\r | |
29 | \r | |
30 | //\r | |
31 | // Forward reference for pure ANSI compatability\r | |
32 | //\r | |
33 | typedef struct _EFI_DEBUG_ASSERT_PROTOCOL EFI_DEBUG_ASSERT_PROTOCOL;\r | |
34 | \r | |
35 | \r | |
36 | typedef\r | |
37 | EFI_STATUS\r | |
38 | (EFIAPI *EFI_DEBUG_ASSERT) (\r | |
39 | IN EFI_DEBUG_ASSERT_PROTOCOL *This,\r | |
40 | IN CHAR8 *FileName,\r | |
41 | IN INTN LineNumber,\r | |
42 | IN CHAR8 *Description\r | |
43 | );\r | |
44 | \r | |
45 | typedef\r | |
46 | EFI_STATUS\r | |
47 | (EFIAPI *EFI_DEBUG_PRINT) (\r | |
48 | IN EFI_DEBUG_ASSERT_PROTOCOL *This,\r | |
49 | IN UINTN ErrorLevel,\r | |
50 | IN CHAR8 *Format,\r | |
51 | IN VA_LIST Marker\r | |
52 | );\r | |
53 | \r | |
54 | typedef\r | |
55 | EFI_STATUS\r | |
56 | (EFIAPI *EFI_POST_CODE) (\r | |
57 | IN EFI_DEBUG_ASSERT_PROTOCOL *This,\r | |
58 | IN UINT16 PostCode,\r | |
59 | IN CHAR8 *PostCodeString OPTIONAL\r | |
60 | );\r | |
61 | \r | |
62 | typedef\r | |
63 | EFI_STATUS\r | |
64 | (EFIAPI *EFI_GET_ERROR_LEVEL) (\r | |
65 | IN EFI_DEBUG_ASSERT_PROTOCOL *This,\r | |
66 | IN UINTN *ErrorLevel\r | |
67 | );\r | |
68 | \r | |
69 | typedef\r | |
70 | EFI_STATUS\r | |
71 | (EFIAPI *EFI_SET_ERROR_LEVEL) (\r | |
72 | IN EFI_DEBUG_ASSERT_PROTOCOL *This,\r | |
73 | IN UINTN ErrorLevel\r | |
74 | );\r | |
75 | \r | |
76 | struct _EFI_DEBUG_ASSERT_PROTOCOL {\r | |
77 | \r | |
78 | EFI_DEBUG_ASSERT Assert;\r | |
79 | EFI_DEBUG_PRINT Print;\r | |
80 | EFI_POST_CODE PostCode;\r | |
81 | \r | |
82 | EFI_GET_ERROR_LEVEL GetErrorLevel;\r | |
83 | EFI_SET_ERROR_LEVEL SetErrorLevel;\r | |
84 | \r | |
85 | };\r | |
86 | \r | |
87 | extern EFI_GUID gEfiDebugAssertProtocolGuid;\r | |
88 | \r | |
89 | #endif\r |