Deleted Added
full compact
efidebug.h (96893) efidebug.h (163898)
1/* $FreeBSD: head/sys/boot/efi/include/efidebug.h 96893 2002-05-19 03:17:22Z marcel $ */
1/* $FreeBSD: head/sys/boot/efi/include/efidebug.h 163898 2006-11-02 02:42:48Z marcel $ */
2#ifndef _EFI_DEBUG_H
3#define _EFI_DEBUG_H
4
5/*++
6
2#ifndef _EFI_DEBUG_H
3#define _EFI_DEBUG_H
4
5/*++
6
7Copyright (c) 1998 Intel Corporation
7Copyright (c) 1999 - 2002 Intel Corporation. All rights reserved
8This software and associated documentation (if any) is furnished
9under a license and may only be used or copied in accordance
10with the terms of the license. Except as permitted by such
11license, no part of this software or documentation may be
12reproduced, stored in a retrieval system, or transmitted in any
13form or by any means without the express written consent of
14Intel Corporation.
8
9Module Name:
10
11 efidebug.h
12
13Abstract:
14
15 EFI library debug functions

--- 23 unchanged lines hidden (view full) ---

39 #define DBGSETMEM(a,l) SetMem(a,l,(CHAR8)BAD_POINTER)
40
41#else
42
43 #define DBGSETMEM(a,l)
44
45#endif
46
15
16Module Name:
17
18 efidebug.h
19
20Abstract:
21
22 EFI library debug functions

--- 23 unchanged lines hidden (view full) ---

46 #define DBGSETMEM(a,l) SetMem(a,l,(CHAR8)BAD_POINTER)
47
48#else
49
50 #define DBGSETMEM(a,l)
51
52#endif
53
47#define D_INIT 0x00000001 /* Initialization style messages */
48#define D_WARN 0x00000002 /* Warnings */
49#define D_LOAD 0x00000004 /* Load events */
50#define D_FS 0x00000008 /* EFI File system */
51#define D_POOL 0x00000010 /* Alloc & Free's */
52#define D_PAGE 0x00000020 /* Alloc & Free's */
53#define D_INFO 0x00000040 /* Verbose */
54#define D_VAR 0x00000100 /* Variable */
55#define D_PARSE 0x00000200 /* Command parsing */
56#define D_BM 0x00000400 /* Boot manager */
57#define D_BLKIO 0x00001000 /* BlkIo Driver */
58#define D_BLKIO_ULTRA 0x00002000 /* BlkIo Driver */
59#define D_NET 0x00004000 /* SNI Driver */
60#define D_NET_ULTRA 0x00008000 /* SNI Driver */
61#define D_TXTIN 0x00010000 /* Simple Input Driver */
62#define D_TXTOUT 0x00020000 /* Simple Text Output Driver */
63#define D_ERROR_ATA 0x00040000 /* ATA error messages */
64#define D_ERROR 0x80000000 /* Error */
54#define D_INIT 0x00000001 // Initialization style messages
55#define D_WARN 0x00000002 // Warnings
56#define D_LOAD 0x00000004 // Load events
57#define D_FS 0x00000008 // EFI File system
58#define D_POOL 0x00000010 // Alloc & Free's
59#define D_PAGE 0x00000020 // Alloc & Free's
60#define D_INFO 0x00000040 // Verbose
61#define D_VARIABLE 0x00000100 // Variable
62#define D_VAR 0x00000100 // Variable
63#define D_BM 0x00000400 // Boot Manager
64#define D_BLKIO 0x00001000 // BlkIo Driver
65#define D_BLKIO_ULTRA 0x00002000 // BlkIo Driver
66#define D_NET 0x00004000 // SNI Driver
67#define D_NET_ULTRA 0x00008000 // SNI Driver
68#define D_UNDI 0x00010000 // UNDI Driver
69#define D_LOADFILE 0x00020000 // UNDI Driver
70#define D_EVENT 0x00080000 // Event messages
65
71
66#define D_RESERVED 0x7fffC880 /* Bits not reserved above */
72#define D_ERROR 0x80000000 // Error
67
73
68/*
69 * Current Debug level of the system, value of EFIDebug
70 */
74#define D_RESERVED 0x7ff40A80 // Bits not reserved above
75
76//
77// Current Debug level of the system, value of EFIDebug
78//
79//#define EFI_DBUG_MASK (D_ERROR | D_WARN | D_LOAD | D_BLKIO | D_INIT)
71#define EFI_DBUG_MASK (D_ERROR)
72
80#define EFI_DBUG_MASK (D_ERROR)
81
82//
83//
84//
85
73#if EFI_DEBUG
74
75 #define ASSERT(a) if(!(a)) DBGASSERT(a)
76 #define ASSERT_LOCKED(l) if(!(l)->Lock) DBGASSERT(l not locked)
77 #define ASSERT_STRUCT(p,t) DBGASSERT(t not structure), p
78
79#else
80
81 #define ASSERT(a)
82 #define ASSERT_LOCKED(l)
83 #define ASSERT_STRUCT(p,t)
84
85#endif
86
86#if EFI_DEBUG
87
88 #define ASSERT(a) if(!(a)) DBGASSERT(a)
89 #define ASSERT_LOCKED(l) if(!(l)->Lock) DBGASSERT(l not locked)
90 #define ASSERT_STRUCT(p,t) DBGASSERT(t not structure), p
91
92#else
93
94 #define ASSERT(a)
95 #define ASSERT_LOCKED(l)
96 #define ASSERT_STRUCT(p,t)
97
98#endif
99
87/*
88 * Prototypes
89 */
100//
101// Prototypes
102//
90
91INTN
92DbgAssert (
93 CHAR8 *file,
94 INTN lineno,
95 CHAR8 *string
96 );
97
98INTN
99DbgPrint (
100 INTN mask,
101 CHAR8 *format,
102 ...
103 );
104
105#endif
103
104INTN
105DbgAssert (
106 CHAR8 *file,
107 INTN lineno,
108 CHAR8 *string
109 );
110
111INTN
112DbgPrint (
113 INTN mask,
114 CHAR8 *format,
115 ...
116 );
117
118#endif