https://git.reactos.org/?p=reactos.git;a=commitdiff;h=c2946ced9234d825297c5…
commit c2946ced9234d825297c59c2e492acd320fc153f
Author: Hervé Poussineau <hpoussin(a)reactos.org>
AuthorDate: Sat Mar 7 19:30:15 2020 +0100
Commit: Hervé Poussineau <hpoussin(a)reactos.org>
CommitDate: Mon Nov 16 08:55:03 2020 +0100
[NTOS:KD] Remove some now useless tests on _WINKD_
---
ntoskrnl/ex/dbgctrl.c | 4 ----
ntoskrnl/ex/work.c | 2 --
ntoskrnl/include/internal/ex.h | 2 --
ntoskrnl/ke/amd64/trap.S | 6 ------
ntoskrnl/ke/i386/traphdlr.c | 2 --
ntoskrnl/mm/ARM3/mmdbg.c | 4 +---
6 files changed, 1 insertion(+), 19 deletions(-)
diff --git a/ntoskrnl/ex/dbgctrl.c b/ntoskrnl/ex/dbgctrl.c
index f72774e3220..70280703a31 100644
--- a/ntoskrnl/ex/dbgctrl.c
+++ b/ntoskrnl/ex/dbgctrl.c
@@ -14,7 +14,6 @@
/* DATA **********************************************************************/
-// #ifdef _WINKD_
/*
* WinDBG Debugger Worker State Machine data
*/
@@ -27,11 +26,9 @@ WINKD_WORKER_STATE ExpDebuggerWork;
PEPROCESS ExpDebuggerProcessAttach;
PEPROCESS ExpDebuggerProcessKill;
ULONG_PTR ExpDebuggerPageIn;
-// #endif /* _WINKD_ */
/* FUNCTIONS *****************************************************************/
-// #ifdef _WINKD_
/*
* WinDBG Debugger Worker State Machine
*
@@ -142,7 +139,6 @@ ExpDebuggerWorker(IN PVOID Context)
ObDereferenceObject(Process);
}
}
-// #endif /* _WINKD_ */
/*++
* @name NtSystemDebugControl
diff --git a/ntoskrnl/ex/work.c b/ntoskrnl/ex/work.c
index 3884eb0b952..03ab0c4bfdf 100644
--- a/ntoskrnl/ex/work.c
+++ b/ntoskrnl/ex/work.c
@@ -483,7 +483,6 @@ ExpWorkerThreadBalanceManager(IN PVOID Context)
PsTerminateSystemThread(STATUS_SYSTEM_SHUTDOWN);
}
-// #ifdef _WINKD_
/*
* If WinDBG wants to attach or kill a user-mode process, and/or
* page-in an address region, queue a debugger worker thread.
@@ -494,7 +493,6 @@ ExpWorkerThreadBalanceManager(IN PVOID Context)
ExpDebuggerWork = WinKdWorkerInitialized;
ExQueueWorkItem(&ExpDebuggerWorkItem, DelayedWorkQueue);
}
-// #endif /* _WINKD_ */
}
}
diff --git a/ntoskrnl/include/internal/ex.h b/ntoskrnl/include/internal/ex.h
index fae2026fc1c..3dcc38ff944 100644
--- a/ntoskrnl/include/internal/ex.h
+++ b/ntoskrnl/include/internal/ex.h
@@ -47,7 +47,6 @@ extern UNICODE_STRING CmVersionString;
extern UNICODE_STRING CmCSDVersionString;
extern CHAR NtBuildLab[];
-// #ifdef _WINKD_
/*
* WinDBG Debugger Worker State Machine data (see dbgctrl.c)
*/
@@ -65,7 +64,6 @@ extern PEPROCESS ExpDebuggerProcessKill;
extern ULONG_PTR ExpDebuggerPageIn;
VOID NTAPI ExpDebuggerWorker(IN PVOID Context);
-// #endif /* _WINKD_ */
#ifdef _WIN64
#define HANDLE_LOW_BITS (PAGE_SHIFT - 4)
diff --git a/ntoskrnl/ke/amd64/trap.S b/ntoskrnl/ke/amd64/trap.S
index 731e21b250a..2d7194b82de 100644
--- a/ntoskrnl/ke/amd64/trap.S
+++ b/ntoskrnl/ke/amd64/trap.S
@@ -24,9 +24,7 @@ EXTERN PsConvertToGuiThread:PROC
EXTERN MmCreateKernelStack:PROC
EXTERN MmDeleteKernelStack:PROC
-#ifdef _WINKD_
EXTERN KdSetOwedBreakpoints:PROC
-#endif
/* Helper Macros *************************************************************/
@@ -430,9 +428,6 @@ FUNC KiPageFault
/* Check for success */
test eax, eax
-#ifndef _WINKD_
- jge PageFaultReturn
-#else
jl PageFaultError
/* Check whether the kernel debugger has owed breakpoints to be inserted */
@@ -441,7 +436,6 @@ FUNC KiPageFault
jmp PageFaultReturn
PageFaultError:
-#endif
/* Disable interrupts again for the debugger */
cli
diff --git a/ntoskrnl/ke/i386/traphdlr.c b/ntoskrnl/ke/i386/traphdlr.c
index 0614efc398b..cf4dbdd92ee 100644
--- a/ntoskrnl/ke/i386/traphdlr.c
+++ b/ntoskrnl/ke/i386/traphdlr.c
@@ -1376,10 +1376,8 @@ KiTrap0EHandler(IN PKTRAP_FRAME TrapFrame)
TrapFrame);
if (NT_SUCCESS(Status))
{
-#ifdef _WINKD_
/* Check whether the kernel debugger has owed breakpoints to be inserted */
KdSetOwedBreakpoints();
-#endif
/* We succeeded, return */
KiEoiHelper(TrapFrame);
}
diff --git a/ntoskrnl/mm/ARM3/mmdbg.c b/ntoskrnl/mm/ARM3/mmdbg.c
index 82fa5023cb6..c47b8cfe156 100644
--- a/ntoskrnl/mm/ARM3/mmdbg.c
+++ b/ntoskrnl/mm/ARM3/mmdbg.c
@@ -15,9 +15,7 @@
#define MODULE_INVOLVED_IN_ARM3
#include <mm/ARM3/miarm.h>
-#ifndef _WINKD_
-#define KdpDprintf DPRINT
-#elif defined(NDEBUG)
+#ifdef NDEBUG
#define KdpDprintf(...)
#endif