Reactos
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

at listview 140 lines 2.7 kB view raw
1#pragma once 2 3/* KD ROUTINES ***************************************************************/ 4 5struct _KD_DISPATCH_TABLE; 6 7typedef 8NTSTATUS 9(NTAPI *PKDP_INIT_ROUTINE)( 10 _In_ struct _KD_DISPATCH_TABLE *DispatchTable, 11 _In_ ULONG BootPhase); 12 13typedef 14VOID 15(NTAPI *PKDP_PRINT_ROUTINE)( 16 _In_ PCCH String, 17 _In_ ULONG Length); 18 19VOID 20KdIoPuts( 21 _In_ PCSTR String); 22 23VOID 24__cdecl 25KdIoPrintf( 26 _In_ PCSTR Format, 27 ...); 28 29SIZE_T 30KdIoReadLine( 31 _Out_ PCHAR Buffer, 32 _In_ SIZE_T Size); 33 34 35/* INIT ROUTINES *************************************************************/ 36 37KIRQL 38NTAPI 39KdbpAcquireLock( 40 _In_ PKSPIN_LOCK SpinLock); 41 42VOID 43NTAPI 44KdbpReleaseLock( 45 _In_ PKSPIN_LOCK SpinLock, 46 _In_ KIRQL OldIrql); 47 48VOID 49KdpScreenAcquire(VOID); 50 51VOID 52KdpScreenRelease(VOID); 53 54NTSTATUS 55NTAPI 56KdpScreenInit( 57 _In_ struct _KD_DISPATCH_TABLE *DispatchTable, 58 _In_ ULONG BootPhase); 59 60NTSTATUS 61NTAPI 62KdpSerialInit( 63 _In_ struct _KD_DISPATCH_TABLE *DispatchTable, 64 _In_ ULONG BootPhase); 65 66NTSTATUS 67NTAPI 68KdpDebugLogInit( 69 _In_ struct _KD_DISPATCH_TABLE *DispatchTable, 70 _In_ ULONG BootPhase); 71 72#ifdef KDBG 73#define KdpKdbgInit KdbInitialize 74#endif 75 76 77/* KD GLOBALS ****************************************************************/ 78 79/* Serial debug connection */ 80#define DEFAULT_DEBUG_PORT 2 /* COM2 */ 81#define DEFAULT_DEBUG_COM1_IRQ 4 /* COM1 IRQ */ 82#define DEFAULT_DEBUG_COM2_IRQ 3 /* COM2 IRQ */ 83#define DEFAULT_DEBUG_BAUD_RATE 115200 /* 115200 Baud */ 84 85/* KD Native Modes */ 86// #define KdScreen 0 87// #define KdSerial 1 88// #define KdFile 2 89#ifdef KDBG 90// #define KdKdbg 3 91#define KdMax 4 92#else 93#define KdMax 3 94#endif 95 96/* KD Private Debug Modes */ 97typedef struct _KDP_DEBUG_MODE 98{ 99 union 100 { 101 struct 102 { 103 /* Native Modes */ 104 UCHAR Screen :1; 105 UCHAR Serial :1; 106 UCHAR File :1; 107 }; 108 109 /* Generic Value */ 110 ULONG Value; 111 }; 112} KDP_DEBUG_MODE; 113 114/* Dispatch Table for Wrapper Functions */ 115typedef struct _KD_DISPATCH_TABLE 116{ 117 LIST_ENTRY KdProvidersList; 118 PKDP_INIT_ROUTINE KdpInitRoutine; 119 PKDP_PRINT_ROUTINE KdpPrintRoutine; 120 NTSTATUS InitStatus; 121} KD_DISPATCH_TABLE, *PKD_DISPATCH_TABLE; 122 123/* The current Debugging Mode */ 124extern KDP_DEBUG_MODE KdpDebugMode; 125 126/* Port Information for the Serial Native Mode */ 127extern ULONG SerialPortNumber; 128extern CPPORT SerialPortInfo; 129 130/* Logging file path */ 131extern ANSI_STRING KdpLogFileName; 132 133/* Init Functions for Native Providers */ 134extern PKDP_INIT_ROUTINE InitRoutines[KdMax]; 135 136/* Dispatch Tables for Native Providers */ 137extern KD_DISPATCH_TABLE DispatchTable[KdMax]; 138 139/* The KD Native Provider List */ 140extern LIST_ENTRY KdProviders;