Skip to content

Commit 6d88300

Browse files
committed
[NTOS:KD] Remove some now useless tests on _WINKD_
1 parent d711768 commit 6d88300

File tree

6 files changed

+1
-19
lines changed

6 files changed

+1
-19
lines changed

ntoskrnl/ex/dbgctrl.c

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414

1515
/* DATA **********************************************************************/
1616

17-
// #ifdef _WINKD_
1817
/*
1918
* WinDBG Debugger Worker State Machine data
2019
*/
@@ -27,11 +26,9 @@ WINKD_WORKER_STATE ExpDebuggerWork;
2726
PEPROCESS ExpDebuggerProcessAttach;
2827
PEPROCESS ExpDebuggerProcessKill;
2928
ULONG_PTR ExpDebuggerPageIn;
30-
// #endif /* _WINKD_ */
3129

3230
/* FUNCTIONS *****************************************************************/
3331

34-
// #ifdef _WINKD_
3532
/*
3633
* WinDBG Debugger Worker State Machine
3734
*
@@ -142,7 +139,6 @@ ExpDebuggerWorker(IN PVOID Context)
142139
ObDereferenceObject(Process);
143140
}
144141
}
145-
// #endif /* _WINKD_ */
146142

147143
/*++
148144
* @name NtSystemDebugControl

ntoskrnl/ex/work.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -487,7 +487,6 @@ ExpWorkerThreadBalanceManager(IN PVOID Context)
487487
PsTerminateSystemThread(STATUS_SYSTEM_SHUTDOWN);
488488
}
489489

490-
// #ifdef _WINKD_
491490
/*
492491
* If WinDBG wants to attach or kill a user-mode process, and/or
493492
* page-in an address region, queue a debugger worker thread.
@@ -498,7 +497,6 @@ ExpWorkerThreadBalanceManager(IN PVOID Context)
498497
ExpDebuggerWork = WinKdWorkerInitialized;
499498
ExQueueWorkItem(&ExpDebuggerWorkItem, DelayedWorkQueue);
500499
}
501-
// #endif /* _WINKD_ */
502500
}
503501
}
504502

ntoskrnl/include/internal/ex.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,6 @@ extern UNICODE_STRING CmVersionString;
4747
extern UNICODE_STRING CmCSDVersionString;
4848
extern CHAR NtBuildLab[];
4949

50-
// #ifdef _WINKD_
5150
/*
5251
* WinDBG Debugger Worker State Machine data (see dbgctrl.c)
5352
*/
@@ -65,7 +64,6 @@ extern PEPROCESS ExpDebuggerProcessKill;
6564
extern ULONG_PTR ExpDebuggerPageIn;
6665

6766
VOID NTAPI ExpDebuggerWorker(IN PVOID Context);
68-
// #endif /* _WINKD_ */
6967

7068
#ifdef _WIN64
7169
#define HANDLE_LOW_BITS (PAGE_SHIFT - 4)

ntoskrnl/ke/amd64/trap.S

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,7 @@ EXTERN KiXmmExceptionHandler:PROC
2222
EXTERN KiDeliverApc:PROC
2323
EXTERN KiDpcInterruptHandler:PROC
2424

25-
#ifdef _WINKD_
2625
EXTERN KdSetOwedBreakpoints:PROC
27-
#endif
2826

2927

3028
/* GLOBALS *******************************************************************/
@@ -512,9 +510,6 @@ FUNC KiPageFault
512510

513511
/* Check for success */
514512
test eax, eax
515-
#ifndef _WINKD_
516-
jge PageFaultReturn
517-
#else
518513
jl PageFaultError
519514

520515
/* Check whether the kernel debugger has owed breakpoints to be inserted */
@@ -523,7 +518,6 @@ FUNC KiPageFault
523518
jmp PageFaultReturn
524519

525520
PageFaultError:
526-
#endif
527521

528522
/* Disable interrupts again for the debugger */
529523
cli

ntoskrnl/ke/i386/traphdlr.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1363,10 +1363,8 @@ KiTrap0EHandler(IN PKTRAP_FRAME TrapFrame)
13631363
TrapFrame);
13641364
if (NT_SUCCESS(Status))
13651365
{
1366-
#ifdef _WINKD_
13671366
/* Check whether the kernel debugger has owed breakpoints to be inserted */
13681367
KdSetOwedBreakpoints();
1369-
#endif
13701368
/* We succeeded, return */
13711369
KiEoiHelper(TrapFrame);
13721370
}

ntoskrnl/mm/ARM3/mmdbg.c

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,7 @@
1515
#define MODULE_INVOLVED_IN_ARM3
1616
#include <mm/ARM3/miarm.h>
1717

18-
#ifndef _WINKD_
19-
#define KdpDprintf DPRINT
20-
#elif defined(NDEBUG)
18+
#ifdef NDEBUG
2119
#define KdpDprintf(...)
2220
#endif
2321

0 commit comments

Comments
 (0)