Annotation of ntddk/src/krnldbg/kdapis/windbgkd.h, revision 1.1.1.1

1.1       root        1: /*++ BUILD Version: 0045    // Increment this if a change has global effects
                      2: 
                      3: Copyright (c) 1990-1992  Microsoft Corporation
                      4: 
                      5: Module Name:
                      6: 
                      7:     windbgkd.h
                      8: 
                      9: Abstract:
                     10: 
                     11:     This module defines the 32-Bit Windows Kernel Debugger interface.
                     12: 
                     13: Revision History:
                     14: 
                     15: --*/
                     16: 
                     17: #ifndef _WINDBGKD_
                     18: #define _WINDBGKD_
                     19: 
                     20: typedef LARGE_INTEGER PHYSICAL_ADDRESS, *PPHYSICAL_ADDRESS; 
                     21: 
                     22: #ifdef _X86_
                     23: 
                     24: //
                     25: // DBGKD_CONTROL_REPORT
                     26: //
                     27: // This structure contains machine specific data passed to the debugger
                     28: // when a Wait_State_Change message is sent.  Idea is to allow debugger
                     29: // to do what it needes without reading any more packets.
                     30: // Structure is filled in by KdpSetControlReport
                     31: //
                     32: 
                     33: #define DBGKD_MAXSTREAM 16
                     34: 
                     35: typedef struct _DBGKD_CONTROL_REPORT {
                     36:     DWORD   Dr6;
                     37:     DWORD   Dr7;
                     38:     WORD    InstructionCount;
                     39:     WORD    ReportFlags;
                     40:     BYTE    InstructionStream[DBGKD_MAXSTREAM];
                     41:     WORD    SegCs;
                     42:     WORD    SegDs;
                     43:     WORD    SegEs;
                     44:     WORD    SegFs;
                     45:     DWORD   EFlags;
                     46: } DBGKD_CONTROL_REPORT, *PDBGKD_CONTROL_REPORT;
                     47: 
                     48: #define REPORT_INCLUDES_SEGS    0x0001  // this is for backward compatibility
                     49: 
                     50: //
                     51: // DBGKD_CONTROL_SET
                     52: //
                     53: // This structure control value the debugger wants to set on every
                     54: // continue, and thus sets here to avoid packet traffic.
                     55: //
                     56: 
                     57: typedef struct _DBGKD_CONTROL_SET {
                     58:     DWORD   TraceFlag;                  // WARNING: This must NOT be a BOOLEAN,
                     59:                                         //     or host and target will end
                     60:                                         //     up with different alignments!
                     61:     DWORD   Dr7;
                     62:     DWORD   CurrentSymbolStart;         // Range in which to trace locally
                     63:     DWORD   CurrentSymbolEnd;
                     64: } DBGKD_CONTROL_SET, *PDBGKD_CONTROL_SET;
                     65: 
                     66: #endif //_X86_
                     67: 
                     68: 
                     69: typedef struct _DESCRIPTOR_TABLE_ENTRY {
                     70:     DWORD Selector;
                     71:     LDT_ENTRY Descriptor;
                     72: } DESCRIPTOR_TABLE_ENTRY, *PDESCRIPTOR_TABLE_ENTRY;
                     73: 
                     74: 
                     75: #if defined(_MIPS_)
                     76: 
                     77: // end_ntddk end_nthal
                     78: 
                     79: //
                     80: // Define MIPS specific kernel debugger information.
                     81: //
                     82: // The following structure contains machine specific data passed to
                     83: // the host system kernel debugger in a wait state change message.
                     84: //
                     85: 
                     86: #define DBGKD_MAXSTREAM 16
                     87: 
                     88: typedef struct _DBGKD_CONTROL_REPORT {
                     89:     DWORD InstructionCount;
                     90:     BYTE  InstructionStream[DBGKD_MAXSTREAM];
                     91: } DBGKD_CONTROL_REPORT, *PDBGKD_CONTROL_REPORT;
                     92: 
                     93: //
                     94: // The following structure contains information that the host system
                     95: // kernel debugger wants to set on every continue operation and avoids
                     96: // the need to send extra packets of information.
                     97: //
                     98: 
                     99: typedef DWORD DBGKD_CONTROL_SET, *PDBGKD_CONTROL_SET;
                    100: 
                    101: #endif                          // ntddk nthal
                    102: 
                    103: #ifdef _ALPHA_
                    104: 
                    105: //
                    106: // Define Alpha specific kernel debugger information.
                    107: //
                    108: // The following structure contains machine specific data passed to
                    109: // the host system kernel debugger in a wait state change message.
                    110: //
                    111: 
                    112: #define DBGKD_MAXSTREAM 16
                    113: 
                    114: typedef struct _DBGKD_CONTROL_REPORT {
                    115:     DWORD InstructionCount;
                    116:     BYTE  InstructionStream[DBGKD_MAXSTREAM];
                    117: } DBGKD_CONTROL_REPORT, *PDBGKD_CONTROL_REPORT;
                    118: 
                    119: //
                    120: // The following structure contains information that the host system
                    121: // kernel debugger wants to set on every continue operation and avoids
                    122: // the need to send extra packets of information.
                    123: //
                    124: 
                    125: typedef DWORD DBGKD_CONTROL_SET, *PDBGKD_CONTROL_SET;
                    126: 
                    127: #endif // _ALPHA_
                    128: 
                    129: #ifdef _X86_
                    130: //
                    131: // Special Registers for i386
                    132: //
                    133: 
                    134: typedef struct _DESCRIPTOR {
                    135:     WORD    Pad;
                    136:     WORD    Limit;
                    137:     DWORD   Base;
                    138: } KDESCRIPTOR, *PKDESCRIPTOR;
                    139: 
                    140: typedef struct _KSPECIAL_REGISTERS {
                    141:     DWORD Cr0;
                    142:     DWORD Cr2;
                    143:     DWORD Cr3;
                    144:     DWORD Cr4;
                    145:     DWORD KernelDr0;
                    146:     DWORD KernelDr1;
                    147:     DWORD KernelDr2;
                    148:     DWORD KernelDr3;
                    149:     DWORD KernelDr6;
                    150:     DWORD KernelDr7;
                    151:     KDESCRIPTOR Gdtr;
                    152:     KDESCRIPTOR Idtr;
                    153:     WORD   Tr;
                    154:     WORD   Ldtr;
                    155:     DWORD Reserved[6];
                    156: } KSPECIAL_REGISTERS, *PKSPECIAL_REGISTERS;
                    157: 
                    158: //
                    159: // Processor State frame: Before a processor freezes itself, it
                    160: // dumps the processor state to the processor state frame for
                    161: // debugger to examine.
                    162: //
                    163: 
                    164: typedef struct _KPROCESSOR_STATE {
                    165:     struct _CONTEXT ContextFrame;
                    166:     struct _KSPECIAL_REGISTERS SpecialRegisters;
                    167: } KPROCESSOR_STATE, *PKPROCESSOR_STATE;
                    168: #endif // _X86_
                    169: 
                    170: typedef struct _DBGKM_EXCEPTION {
                    171:     EXCEPTION_RECORD ExceptionRecord;
                    172:     DWORD FirstChance;
                    173: } DBGKM_EXCEPTION, *PDBGKM_EXCEPTION;
                    174: 
                    175: 
                    176: //
                    177: // DbgKd APIs are for the portable kernel debugger
                    178: //
                    179: 
                    180: //
                    181: // KD_PACKETS are the low level data format used in KD. All packets
                    182: // begin with a packet leader, byte count, packet type. The sequence
                    183: // for accepting a packet is:
                    184: //
                    185: //  - read 4 bytes to get packet leader.  If read times out (10 seconds)
                    186: //    with a short read, or if packet leader is incorrect, then retry
                    187: //    the read.
                    188: //
                    189: //  - next read 2 byte packet type.  If read times out (10 seconds) with
                    190: //    a short read, or if packet type is bad, then start again looking
                    191: //    for a packet leader.
                    192: //
                    193: //  - next read 4 byte packet Id.  If read times out (10 seconds)
                    194: //    with a short read, or if packet Id is not what we expect, then
                    195: //    ask for resend and restart again looking for a packet leader.
                    196: //
                    197: //  - next read 2 byte byte count.  If read times out (10 seconds) with
                    198: //    a short read, or if byte count is greater than PACKET_MAX_SIZE,
                    199: //    then start again looking for a packet leader.
                    200: //
                    201: //  - next read 4 byte packet data checksum.
                    202: //
                    203: //  - The packet data immediately follows the packet.  There should be
                    204: //    ByteCount bytes following the packet header.  Read the packet
                    205: //    data, if read times out (10 seconds) then start again looking for
                    206: //    a packet leader.
                    207: //
                    208: 
                    209: 
                    210: typedef struct _KD_PACKET {
                    211:     DWORD PacketLeader;
                    212:     WORD   PacketType;
                    213:     WORD   ByteCount;
                    214:     DWORD PacketId;
                    215:     DWORD Checksum;
                    216: } KD_PACKET, *PKD_PACKET;
                    217: 
                    218: 
                    219: #define PACKET_MAX_SIZE 4000
                    220: #define INITIAL_PACKET_ID 0x80800000   // DON't use 0
                    221: #define SYNC_PACKET_ID   0x00000800    // Or in with INITIAL_PACKET_ID
                    222:                                        // to force a packet ID reset.
                    223: 
                    224: //
                    225: // BreakIn packet
                    226: //
                    227: 
                    228: #define BREAKIN_PACKET                  0x62626262
                    229: #define BREAKIN_PACKET_BYTE             0x62
                    230: 
                    231: //
                    232: // Packet lead in sequence
                    233: //
                    234: 
                    235: #define PACKET_LEADER                   0x30303030 //0x77000077
                    236: #define PACKET_LEADER_BYTE              0x30
                    237: 
                    238: #define CONTROL_PACKET_LEADER           0x69696969
                    239: #define CONTROL_PACKET_LEADER_BYTE      0x69
                    240: 
                    241: //
                    242: // Packet Trailing Byte
                    243: //
                    244: 
                    245: #define PACKET_TRAILING_BYTE            0xAA
                    246: 
                    247: //
                    248: // Packet Types
                    249: //
                    250: 
                    251: #define PACKET_TYPE_UNUSED              0
                    252: #define PACKET_TYPE_KD_STATE_CHANGE     1
                    253: #define PACKET_TYPE_KD_STATE_MANIPULATE 2
                    254: #define PACKET_TYPE_KD_DEBUG_IO         3
                    255: #define PACKET_TYPE_KD_ACKNOWLEDGE      4       // Packet-control type
                    256: #define PACKET_TYPE_KD_RESEND           5       // Packet-control type
                    257: #define PACKET_TYPE_KD_RESET            6       // Packet-control type
                    258: #define PACKET_TYPE_MAX                 7
                    259: 
                    260: //
                    261: // If the packet type is PACKET_TYPE_KD_STATE_CHANGE, then
                    262: // the format of the packet data is as follows:
                    263: //
                    264: 
                    265: #define DbgKdExceptionStateChange   0x00003030L
                    266: #define DbgKdLoadSymbolsStateChange 0x00003031L
                    267: 
                    268: //
                    269: // Pathname Data follows directly
                    270: //
                    271: 
                    272: typedef struct _DBGKD_LOAD_SYMBOLS {
                    273:     DWORD PathNameLength;
                    274:     PVOID BaseOfDll;
                    275:     DWORD ProcessId;
                    276:     DWORD CheckSum;
                    277:     DWORD SizeOfImage;
                    278:     BOOLEAN UnloadSymbols;
                    279: } DBGKD_LOAD_SYMBOLS, *PDBGKD_LOAD_SYMBOLS;
                    280: 
                    281: typedef struct _DBGKD_WAIT_STATE_CHANGE {
                    282:     DWORD NewState;
                    283:     WORD   ProcessorType;
                    284:     WORD   Processor;
                    285:     DWORD NumberProcessors;
                    286:     PVOID Thread;
                    287:     PVOID ProgramCounter;
                    288:     union {
                    289:         DBGKM_EXCEPTION Exception;
                    290:         DBGKD_LOAD_SYMBOLS LoadSymbols;
                    291:     } u;
                    292:     DBGKD_CONTROL_REPORT ControlReport;
                    293: } DBGKD_WAIT_STATE_CHANGE, *PDBGKD_WAIT_STATE_CHANGE;
                    294: 
                    295: //
                    296: // If the packet type is PACKET_TYPE_KD_STATE_MANIPULATE, then
                    297: // the format of the packet data is as follows:
                    298: //
                    299: // Api Numbers for state manipulation
                    300: //
                    301: 
                    302: #define DbgKdReadVirtualMemoryApi     0x00003130L
                    303: #define DbgKdWriteVirtualMemoryApi    0x00003131L
                    304: #define DbgKdGetContextApi            0x00003132L
                    305: #define DbgKdSetContextApi            0x00003133L
                    306: #define DbgKdWriteBreakPointApi       0x00003134L
                    307: #define DbgKdRestoreBreakPointApi     0x00003135L
                    308: #define DbgKdContinueApi              0x00003136L
                    309: #define DbgKdReadControlSpaceApi      0x00003137L
                    310: #define DbgKdWriteControlSpaceApi     0x00003138L
                    311: #define DbgKdReadIoSpaceApi           0x00003139L
                    312: #define DbgKdWriteIoSpaceApi          0x0000313AL
                    313: #define DbgKdRebootApi                0x0000313BL
                    314: #define DbgKdContinueApi2             0x0000313CL
                    315: #define DbgKdReadPhysicalMemoryApi    0x0000313DL
                    316: #define DbgKdWritePhysicalMemoryApi   0x0000313EL
                    317: #define DbgKdQuerySpecialCallsApi     0x0000313FL
                    318: #define DbgKdSetSpecialCallApi        0x00003140L
                    319: #define DbgKdClearSpecialCallsApi     0x00003141L
                    320: #define DbgKdSetInternalBreakPointApi 0x00003142L
                    321: #define DbgKdGetInternalBreakPointApi 0x00003143L
                    322: #define DbgKdReadIoSpaceExtendedApi   0x00003144L
                    323: #define DbgKdWriteIoSpaceExtendedApi  0x00003145L
                    324: 
                    325: //
                    326: // Response is a read memory message with data following
                    327: //
                    328: 
                    329: typedef struct _DBGKD_READ_MEMORY {
                    330:     PVOID TargetBaseAddress;
                    331:     DWORD TransferCount;
                    332:     DWORD ActualBytesRead;
                    333: } DBGKD_READ_MEMORY, *PDBGKD_READ_MEMORY;
                    334: 
                    335: //
                    336: // Data follows directly
                    337: //
                    338: 
                    339: typedef struct _DBGKD_WRITE_MEMORY {
                    340:     PVOID TargetBaseAddress;
                    341:     DWORD TransferCount;
                    342:     DWORD ActualBytesWritten;
                    343: } DBGKD_WRITE_MEMORY, *PDBGKD_WRITE_MEMORY;
                    344: 
                    345: //
                    346: // Response is a get context message with a full context record following
                    347: //
                    348: 
                    349: typedef struct _DBGKD_GET_CONTEXT {
                    350:     DWORD ContextFlags;
                    351: } DBGKD_GET_CONTEXT, *PDBGKD_GET_CONTEXT;
                    352: 
                    353: //
                    354: // Full Context record follows
                    355: //
                    356: 
                    357: typedef struct _DBGKD_SET_CONTEXT {
                    358:     DWORD ContextFlags;
                    359: } DBGKD_SET_CONTEXT, *PDBGKD_SET_CONTEXT;
                    360: 
                    361: typedef struct _DBGKD_WRITE_BREAKPOINT {
                    362:     PVOID BreakPointAddress;
                    363:     DWORD BreakPointHandle;
                    364: } DBGKD_WRITE_BREAKPOINT, *PDBGKD_WRITE_BREAKPOINT;
                    365: 
                    366: typedef struct _DBGKD_RESTORE_BREAKPOINT {
                    367:     DWORD BreakPointHandle;
                    368: } DBGKD_RESTORE_BREAKPOINT, *PDBGKD_RESTORE_BREAKPOINT;
                    369: 
                    370: typedef struct _DBGKD_CONTINUE {
                    371:     DWORD    ContinueStatus;
                    372: } DBGKD_CONTINUE, *PDBGKD_CONTINUE;
                    373: 
                    374: typedef struct _DBGKD_CONTINUE2 {
                    375:     DWORD    ContinueStatus;
                    376:     DBGKD_CONTROL_SET ControlSet;
                    377: } DBGKD_CONTINUE2, *PDBGKD_CONTINUE2;
                    378: 
                    379: typedef struct _DBGKD_READ_WRITE_IO {
                    380:     DWORD DataSize;                     // 1, 2, 4
                    381:     PVOID IoAddress;
                    382:     DWORD DataValue;
                    383: } DBGKD_READ_WRITE_IO, *PDBGKD_READ_WRITE_IO;
                    384: 
                    385: typedef struct _DBGKD_READ_WRITE_IO_EXTENDED {
                    386:     DWORD DataSize;                     // 1, 2, 4
                    387:     DWORD InterfaceType;
                    388:     DWORD BusNumber;
                    389:     DWORD AddressSpace;
                    390:     PVOID IoAddress;
                    391:     DWORD DataValue;
                    392: } DBGKD_READ_WRITE_IO_EXTENDED, *PDBGKD_READ_WRITE_IO_EXTENDED;
                    393: 
                    394: typedef struct _DBGKD_QUERY_SPECIAL_CALLS {
                    395:     DWORD NumberOfSpecialCalls;
                    396:     // DWORD SpecialCalls[];
                    397: } DBGKD_QUERY_SPECIAL_CALLS, *PDBGKD_QUERY_SPECIAL_CALLS;
                    398: 
                    399: typedef struct _DBGKD_SET_SPECIAL_CALL {
                    400:     DWORD SpecialCall;
                    401: } DBGKD_SET_SPECIAL_CALL, *PDBGKD_SET_SPECIAL_CALL;
                    402: 
                    403: typedef struct _DBGKD_SET_INTERNAL_BREAKPOINT {
                    404:     DWORD BreakpointAddress;
                    405:     DWORD Flags;
                    406: } DBGKD_SET_INTERNAL_BREAKPOINT, *PDBGKD_SET_INTERNAL_BREAKPOINT;
                    407: 
                    408: typedef struct _DBGKD_GET_INTERNAL_BREAKPOINT {
                    409:     DWORD BreakpointAddress;
                    410:     DWORD Flags;
                    411:     DWORD Calls;
                    412:     DWORD MaxCallsPerPeriod;
                    413:     DWORD MinInstructions;
                    414:     DWORD MaxInstructions;
                    415:     DWORD TotalInstructions;
                    416: } DBGKD_GET_INTERNAL_BREAKPOINT, *PDBGKD_GET_INTERNAL_BREAKPOINT;
                    417: 
                    418: #define DBGKD_INTERNAL_BP_FLAG_COUNTONLY 0x00000001 // don't count instructions
                    419: #define DBGKD_INTERNAL_BP_FLAG_INVALID   0x00000002 // disabled BP
                    420: #define DBGKD_INTERNAL_BP_FLAG_SUSPENDED 0x00000004 // temporarily suspended
                    421: #define DBGKD_INTERNAL_BP_FLAG_DYING     0x00000008 // kill on exit
                    422: 
                    423: typedef struct _DBGKD_MANIPULATE_STATE {
                    424:     DWORD ApiNumber;
                    425:     WORD   ProcessorType;
                    426:     WORD   Processor;
                    427:     DWORD    ReturnStatus;
                    428:     union {
                    429:         DBGKD_READ_MEMORY ReadMemory;
                    430:         DBGKD_WRITE_MEMORY WriteMemory;
                    431:         DBGKD_GET_CONTEXT GetContext;
                    432:         DBGKD_SET_CONTEXT SetContext;
                    433:         DBGKD_WRITE_BREAKPOINT WriteBreakPoint;
                    434:         DBGKD_RESTORE_BREAKPOINT RestoreBreakPoint;
                    435:         DBGKD_CONTINUE Continue;
                    436:         DBGKD_CONTINUE2 Continue2;
                    437:         DBGKD_READ_WRITE_IO ReadWriteIo;
                    438:         DBGKD_READ_WRITE_IO_EXTENDED ReadWriteIoExtended;
                    439:         DBGKD_QUERY_SPECIAL_CALLS QuerySpecialCalls;
                    440:         DBGKD_SET_SPECIAL_CALL SetSpecialCall;
                    441:         DBGKD_SET_INTERNAL_BREAKPOINT SetInternalBreakpoint;
                    442:         DBGKD_GET_INTERNAL_BREAKPOINT GetInternalBreakpoint;
                    443:     } u;
                    444: } DBGKD_MANIPULATE_STATE, *PDBGKD_MANIPULATE_STATE;
                    445: 
                    446: //
                    447: // This is the format for the trace data passed back from the kernel to
                    448: // the debugger to describe multiple calls that have returned since the
                    449: // last trip back.  The basic format is that there are a bunch of these
                    450: // (4 byte) unions stuck together.  Each union is of one of two types: a
                    451: // 4 byte unsigned long interger, or a three field struct, describing a
                    452: // call (where "call" is delimited by returning or exiting the symbol
                    453: // scope).  If the number of instructions executed is too big to fit
                    454: // into a WORD   -1, then the Instructions field has
                    455: // TRACE_DATA_INSTRUCTIONS_BIG and the next union is a LongNumber
                    456: // containing the real number of instructions executed.
                    457: //
                    458: // The very first union returned in each callback is a LongNumber
                    459: // containing the number of unions returned (including the "size"
                    460: // record, os it's always at least 1 even if there's no data to return).
                    461: //
                    462: // This is all returned to the debugger when one of two things
                    463: // happens:
                    464: //
                    465: //   1) The pc moves out of all defined symbol ranges
                    466: //   2) The buffer of trace data entries is filled.
                    467: //
                    468: // The "trace done" case is hacked around on the debugger side.  It
                    469: // guarantees that the pc address that indicates a trace exit never
                    470: // winds up in a defined symbol range.
                    471: //
                    472: // The only other complexity in this system is handling the SymbolNumber
                    473: // table.  This table is kept in parallel by the kernel and the
                    474: // debugger.  When the PC exits a known symbol range, the Begin and End
                    475: // symbol ranges are set by the debugger and are allocated to the next
                    476: // symbol slot upon return.  "The next symbol slot" means the numerical
                    477: // next slot number, unless we've filled all slots, in which case it is
                    478: // #0.  (ie., allocation is cyclic and not LRU or something).  The
                    479: // SymbolNumber table is flushed when a SpecialCalls call is made (ie.,
                    480: // at the beginning of the WatchTrace).
                    481: //
                    482: 
                    483: typedef union _DBGKD_TRACE_DATA {
                    484:     struct {
                    485:         BYTE  SymbolNumber;
                    486:         CHAR LevelChange;
                    487:         WORD   Instructions;
                    488:     } s;
                    489:     DWORD LongNumber;
                    490: } DBGKD_TRACE_DATA, *PDBGKD_TRACE_DATA;
                    491: 
                    492: #define TRACE_DATA_INSTRUCTIONS_BIG 0xffff
                    493: 
                    494: #define TRACE_DATA_BUFFER_MAX_SIZE 40
                    495: 
                    496: //
                    497: // If the packet type is PACKET_TYPE_KD_DEBUG_IO, then
                    498: // the format of the packet data is as follows:
                    499: //
                    500: 
                    501: #define DbgKdPrintStringApi     0x00003230L
                    502: #define DbgKdGetStringApi       0x00003231L
                    503: 
                    504: //
                    505: // For print string, the Null terminated string to print
                    506: // immediately follows the message
                    507: //
                    508: typedef struct _DBGKD_PRINT_STRING {
                    509:     DWORD LengthOfString;
                    510: } DBGKD_PRINT_STRING, *PDBGKD_PRINT_STRING;
                    511: 
                    512: //
                    513: // For get string, the Null terminated promt string
                    514: // immediately follows the message. The LengthOfStringRead
                    515: // field initially contains the maximum number of characters
                    516: // to read. Upon reply, this contains the number of bytes actually
                    517: // read. The data read immediately follows the message.
                    518: //
                    519: //
                    520: typedef struct _DBGKD_GET_STRING {
                    521:     DWORD LengthOfPromptString;
                    522:     DWORD LengthOfStringRead;
                    523: } DBGKD_GET_STRING, *PDBGKD_GET_STRING;
                    524: 
                    525: typedef struct _DBGKD_DEBUG_IO {
                    526:     DWORD ApiNumber;
                    527:     WORD   ProcessorType;
                    528:     WORD   Processor;
                    529:     union {
                    530:         DBGKD_PRINT_STRING PrintString;
                    531:         DBGKD_GET_STRING GetString;
                    532:     } u;
                    533: } DBGKD_DEBUG_IO, *PDBGKD_DEBUG_IO;
                    534: 
                    535: 
                    536: VOID
                    537: NTAPI
                    538: DbgKdSendBreakIn(
                    539:     VOID
                    540:     );
                    541: 
                    542: PBYTE 
                    543: NTAPI
                    544: DbgKdGets(
                    545:     PBYTE  Buffer,
                    546:     WORD   Length
                    547:     );
                    548: 
                    549: DWORD   
                    550: NTAPI
                    551: DbgKdWaitStateChange(
                    552:     OUT PDBGKD_WAIT_STATE_CHANGE StateChange,
                    553:     OUT PVOID Buffer,
                    554:     IN DWORD BufferLength
                    555:     );
                    556: 
                    557: DWORD   
                    558: NTAPI
                    559: DbgKdContinue (
                    560:     IN DWORD    ContinueStatus
                    561:     );
                    562: 
                    563: DWORD   
                    564: NTAPI
                    565: DbgKdContinue2 (
                    566:     IN DWORD    ContinueStatus,
                    567:     IN DBGKD_CONTROL_SET ControlSet
                    568:     );
                    569: 
                    570: DWORD   
                    571: NTAPI
                    572: DbgKdReadVirtualMemory(
                    573:     IN PVOID TargetBaseAddress,
                    574:     OUT PVOID UserInterfaceBuffer,
                    575:     IN DWORD TransferCount,
                    576:     OUT PDWORD ActualBytesRead OPTIONAL
                    577:     );
                    578: 
                    579: DWORD   
                    580: NTAPI
                    581: DbgKdWriteVirtualMemory(
                    582:     IN PVOID TargetBaseAddress,
                    583:     OUT PVOID UserInterfaceBuffer,
                    584:     IN DWORD TransferCount,
                    585:     OUT PDWORD ActualBytesWritten OPTIONAL
                    586:     );
                    587: 
                    588: DWORD   
                    589: NTAPI
                    590: DbgKdReadPhysicalMemory(
                    591:     IN PHYSICAL_ADDRESS TargetBaseAddress,
                    592:     OUT PVOID UserInterfaceBuffer,
                    593:     IN DWORD TransferCount,
                    594:     OUT PDWORD ActualBytesRead OPTIONAL
                    595:     );
                    596: 
                    597: DWORD   
                    598: NTAPI
                    599: DbgKdWritePhysicalMemory(
                    600:     IN PHYSICAL_ADDRESS TargetBaseAddress,
                    601:     OUT PVOID UserInterfaceBuffer,
                    602:     IN DWORD TransferCount,
                    603:     OUT PDWORD ActualBytesWritten OPTIONAL
                    604:     );
                    605: 
                    606: DWORD   
                    607: NTAPI
                    608: DbgKdReadControlSpace(
                    609:     IN WORD   Processor,
                    610:     IN PVOID TargetBaseAddress,
                    611:     OUT PVOID UserInterfaceBuffer,
                    612:     IN DWORD TransferCount,
                    613:     OUT PDWORD ActualBytesRead OPTIONAL
                    614:     );
                    615: 
                    616: DWORD   
                    617: NTAPI
                    618: DbgKdWriteControlSpace(
                    619:     IN WORD   Processor,
                    620:     IN PVOID TargetBaseAddress,
                    621:     OUT PVOID UserInterfaceBuffer,
                    622:     IN DWORD TransferCount,
                    623:     OUT PDWORD ActualBytesWritten OPTIONAL
                    624:     );
                    625: 
                    626: DWORD   
                    627: NTAPI
                    628: DbgKdReadIoSpace(
                    629:     IN PVOID IoAddress,
                    630:     OUT PVOID ReturnedData,
                    631:     IN DWORD DataSize
                    632:     );
                    633: 
                    634: DWORD   
                    635: NTAPI
                    636: DbgKdWriteIoSpace(
                    637:     IN PVOID IoAddress,
                    638:     IN DWORD DataValue,
                    639:     IN DWORD DataSize
                    640:     );
                    641: 
                    642: DWORD   
                    643: NTAPI
                    644: DbgKdGetContext(
                    645:     IN WORD   Processor,
                    646:     IN OUT PCONTEXT Context
                    647:     );
                    648: 
                    649: DWORD   
                    650: NTAPI
                    651: DbgKdSetContext(
                    652:     IN WORD   Processor,
                    653:     IN PCONTEXT Context
                    654:     );
                    655: 
                    656: DWORD   
                    657: NTAPI
                    658: DbgKdWriteBreakPoint(
                    659:     IN PVOID BreakPointAddress,
                    660:     OUT PDWORD BreakPointHandle
                    661:     );
                    662: 
                    663: DWORD   
                    664: NTAPI
                    665: DbgKdRestoreBreakPoint(
                    666:     IN DWORD BreakPointHandle
                    667:     );
                    668: 
                    669: DWORD   
                    670: NTAPI
                    671: DbgKdReboot(
                    672:     VOID
                    673:     );
                    674: 
                    675: #ifdef _X86_
                    676: DWORD   
                    677: NTAPI
                    678: DbgKdLookupSelector(
                    679:     IN WORD   Processor,
                    680:     IN OUT PDESCRIPTOR_TABLE_ENTRY pDescriptorTableEntry
                    681:     );
                    682: #endif
                    683: 
                    684: #define DBG_EXCEPTION_HANDLED           ((DWORD   )0x00010001L) 
                    685: 
                    686: #endif // _WINDBGKD_
                    687: 

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.