https://git.reactos.org/?p=reactos.git;a=commitdiff;h=453edbb5dae32aca2b417…
commit 453edbb5dae32aca2b4170830a63b261a266366d
Author: Hervé Poussineau <hpoussin(a)reactos.org>
AuthorDate: Sat Mar 7 11:39:37 2020 +0100
Commit: Hervé Poussineau <hpoussin(a)reactos.org>
CommitDate: Mon Nov 16 08:55:02 2020 +0100
[NTOS:KD] Implement empty versions of
KdDebuggerInitialize0/KdSendPacket/KdReceivePacket
Move KdDebuggerInitialize1 to common code.
Add #defines to local names to prevent clashes with kdcom.dll
---
ntoskrnl/include/ntoskrnl.h | 6 ++++++
ntoskrnl/kd/arm/kdbg.c | 7 -------
ntoskrnl/kd/i386/kdbg.c | 8 --------
ntoskrnl/kd/kdio.c | 25 +++++++++++++++++++++++++
ntoskrnl/kd/kdmain.c | 16 ++++++++++++++++
5 files changed, 47 insertions(+), 15 deletions(-)
diff --git a/ntoskrnl/include/ntoskrnl.h b/ntoskrnl/include/ntoskrnl.h
index 74921c4ac97..7685c36bcf1 100644
--- a/ntoskrnl/include/ntoskrnl.h
+++ b/ntoskrnl/include/ntoskrnl.h
@@ -82,6 +82,12 @@
#define NOEXTAPI
#include <windbgkd.h>
#include <wdbgexts.h>
+#ifdef KDBG
+#define KdDebuggerInitialize0 KdpDebuggerInitialize0
+#define KdDebuggerInitialize1 KdpDebuggerInitialize1
+#define KdSendPacket KdpSendPacket
+#define KdReceivePacket KdpReceivePacket
+#endif
#include <kddll.h>
#ifdef __ROS_ROSSYM__
#include <reactos/rossym.h>
diff --git a/ntoskrnl/kd/arm/kdbg.c b/ntoskrnl/kd/arm/kdbg.c
index bd83a58329c..2a754791014 100644
--- a/ntoskrnl/kd/arm/kdbg.c
+++ b/ntoskrnl/kd/arm/kdbg.c
@@ -25,13 +25,6 @@ CPPORT DefaultPort = {0, 0, 0};
/* REACTOS FUNCTIONS **********************************************************/
-NTSTATUS
-NTAPI
-KdDebuggerInitialize1(IN PLOADER_PARAMETER_BLOCK LoaderBlock OPTIONAL)
-{
- return STATUS_NOT_IMPLEMENTED;
-}
-
BOOLEAN
NTAPI
KdPortInitializeEx(IN PCPPORT PortInformation,
diff --git a/ntoskrnl/kd/i386/kdbg.c b/ntoskrnl/kd/i386/kdbg.c
index 44bd7629e38..9869011460b 100644
--- a/ntoskrnl/kd/i386/kdbg.c
+++ b/ntoskrnl/kd/i386/kdbg.c
@@ -46,14 +46,6 @@ const ULONG BaseArray[] = {0, 0xF1012000};
/* REACTOS FUNCTIONS **********************************************************/
-NTSTATUS
-NTAPI
-KdDebuggerInitialize1(
- IN PLOADER_PARAMETER_BLOCK LoaderBlock OPTIONAL)
-{
- return STATUS_NOT_IMPLEMENTED;
-}
-
BOOLEAN
NTAPI
KdPortInitializeEx(
diff --git a/ntoskrnl/kd/kdio.c b/ntoskrnl/kd/kdio.c
index b1bfae48224..0e72108ec2c 100644
--- a/ntoskrnl/kd/kdio.c
+++ b/ntoskrnl/kd/kdio.c
@@ -728,4 +728,29 @@ KdpPromptString(
return FALSE;
}
+VOID
+NTAPI
+KdSendPacket(
+ IN ULONG PacketType,
+ IN PSTRING MessageHeader,
+ IN PSTRING MessageData,
+ IN OUT PKD_CONTEXT Context)
+{
+ UNIMPLEMENTED;
+ return;
+}
+
+KDSTATUS
+NTAPI
+KdReceivePacket(
+ IN ULONG PacketType,
+ OUT PSTRING MessageHeader,
+ OUT PSTRING MessageData,
+ OUT PULONG DataLength,
+ IN OUT PKD_CONTEXT Context)
+{
+ UNIMPLEMENTED;
+ return 0;
+}
+
/* EOF */
diff --git a/ntoskrnl/kd/kdmain.c b/ntoskrnl/kd/kdmain.c
index 118119a7b5c..36b95d4aa3f 100644
--- a/ntoskrnl/kd/kdmain.c
+++ b/ntoskrnl/kd/kdmain.c
@@ -440,4 +440,20 @@ KdSystemDebugControl(IN SYSDBG_COMMAND Command,
PKDEBUG_ROUTINE KiDebugRoutine = KdpEnterDebuggerException;
+NTSTATUS
+NTAPI
+KdDebuggerInitialize0(
+ IN PLOADER_PARAMETER_BLOCK LoaderBlock OPTIONAL)
+{
+ return STATUS_NOT_IMPLEMENTED;
+}
+
+NTSTATUS
+NTAPI
+KdDebuggerInitialize1(
+ IN PLOADER_PARAMETER_BLOCK LoaderBlock OPTIONAL)
+{
+ return STATUS_NOT_IMPLEMENTED;
+}
+
/* EOF */