From 0f4c4d67760fc31cbb92112be492f9ede35a6170 Mon Sep 17 00:00:00 2001 From: Zebediah Figura Date: Wed, 22 Aug 2018 13:29:56 -0500 Subject: [PATCH 17/17] ntoskrnl.exe: Implement KeDelayExecutionThread(). Signed-off-by: Zebediah Figura --- dlls/ntoskrnl.exe/ntoskrnl.c | 9 --------- dlls/ntoskrnl.exe/sync.c | 9 +++++++++ include/ddk/wdm.h | 1 + 3 files changed, 10 insertions(+), 9 deletions(-) diff --git a/dlls/ntoskrnl.exe/ntoskrnl.c b/dlls/ntoskrnl.exe/ntoskrnl.c index a7638c9..32fd1d0 100644 --- a/dlls/ntoskrnl.exe/ntoskrnl.c +++ b/dlls/ntoskrnl.exe/ntoskrnl.c @@ -2998,15 +2998,6 @@ NTSTATUS WINAPI CmUnRegisterCallback(LARGE_INTEGER cookie) } /*********************************************************************** - * KeDelayExecutionThread (NTOSKRNL.EXE.@) - */ -NTSTATUS WINAPI KeDelayExecutionThread(KPROCESSOR_MODE waitmode, BOOLEAN alertable, PLARGE_INTEGER interval) -{ - FIXME("(%u, %u, %p): stub\n", waitmode, alertable, interval); - return STATUS_NOT_IMPLEMENTED; -} - -/*********************************************************************** * IoAttachDevice (NTOSKRNL.EXE.@) */ NTSTATUS WINAPI IoAttachDevice(DEVICE_OBJECT *source, UNICODE_STRING *target, DEVICE_OBJECT *attached) diff --git a/dlls/ntoskrnl.exe/sync.c b/dlls/ntoskrnl.exe/sync.c index 1b7650d..21778a3 100644 --- a/dlls/ntoskrnl.exe/sync.c +++ b/dlls/ntoskrnl.exe/sync.c @@ -364,3 +364,12 @@ BOOLEAN WINAPI KeCancelTimer( KTIMER *timer ) return ret; } + +/*********************************************************************** + * KeDelayExecutionThread (NTOSKRNL.EXE.@) + */ +NTSTATUS WINAPI KeDelayExecutionThread( KPROCESSOR_MODE mode, BOOLEAN alertable, LARGE_INTEGER *timeout ) +{ + TRACE("mode %d, alertable %u, timeout %p.\n", mode, alertable, timeout); + return NtDelayExecution( alertable, timeout ); +} diff --git a/include/ddk/wdm.h b/include/ddk/wdm.h index 6be07b2..b5e4424 100644 --- a/include/ddk/wdm.h +++ b/include/ddk/wdm.h @@ -1420,6 +1420,7 @@ NTSTATUS WINAPI IoWMIRegistrationControl(PDEVICE_OBJECT,ULONG); BOOLEAN WINAPI KeCancelTimer(KTIMER*); void WINAPI KeClearEvent(PRKEVENT); +NTSTATUS WINAPI KeDelayExecutionThread(KPROCESSOR_MODE,BOOLEAN,LARGE_INTEGER*); PKTHREAD WINAPI KeGetCurrentThread(void); void WINAPI KeInitializeEvent(PRKEVENT,EVENT_TYPE,BOOLEAN); void WINAPI KeInitializeMutex(PRKMUTEX,ULONG); -- 2.7.4