* Sync up to trunk head (r60691).
[reactos.git] / drivers / base / kdcom / kddll.h
1 /*
2 * COPYRIGHT: GPL, see COPYING in the top level directory
3 * PROJECT: ReactOS kernel
4 * FILE: drivers/base/kddll/kddll.h
5 * PURPOSE: Base definitions for the kernel debugger.
6 * PROGRAMMER: Timo Kreuzer (timo.kreuzer@ewactos.org)
7 */
8
9 #pragma once
10
11 #define NOEXTAPI
12 #include <ntifs.h>
13 #include <arc/arc.h>
14 #include <halfuncs.h>
15 #include <windbgkd.h>
16 #include <wdbgexts.h>
17 #include <ioaccess.h> /* port intrinsics */
18
19 #define NDEBUG
20 #include <debug.h>
21
22 //#define KDDEBUG /* uncomment to enable debugging this dll */
23
24 typedef ULONG (*PFNDBGPRNT)(const char *Format, ...);
25 extern PFNDBGPRNT KdpDbgPrint;
26
27 #ifndef KDDEBUG
28 #define KDDBGPRINT(...)
29 #else
30 #define KDDBGPRINT KdpDbgPrint
31 #endif
32
33 typedef enum
34 {
35 KDP_PACKET_RECEIVED = 0,
36 KDP_PACKET_TIMEOUT = 1,
37 KDP_PACKET_RESEND = 2
38 } KDP_STATUS;
39
40 VOID
41 NTAPI
42 KdpSendBuffer(
43 IN PVOID Buffer,
44 IN ULONG Size);
45
46 KDP_STATUS
47 NTAPI
48 KdpReceiveBuffer(
49 OUT PVOID Buffer,
50 IN ULONG Size);
51
52 KDP_STATUS
53 NTAPI
54 KdpReceivePacketLeader(
55 OUT PULONG PacketLeader);
56
57 VOID
58 NTAPI
59 KdpSendByte(IN UCHAR Byte);
60
61 KDP_STATUS
62 NTAPI
63 KdpPollByte(OUT PUCHAR OutByte);
64
65 KDP_STATUS
66 NTAPI
67 KdpReceiveByte(OUT PUCHAR OutByte);
68
69 KDP_STATUS
70 NTAPI
71 KdpPollBreakIn(VOID);
72
73 /* EOF */