[PATCH 1/7] ntoskrnl.exe: Partially implement KeInitializeDpc() function.

Paul Gofman pgofman at codeweavers.com
Thu May 28 04:15:14 CDT 2020


Signed-off-by: Paul Gofman <pgofman at codeweavers.com>
---
 dlls/ntoskrnl.exe/ntoskrnl.c | 8 ++++++--
 include/ddk/wdm.h            | 1 +
 2 files changed, 7 insertions(+), 2 deletions(-)

diff --git a/dlls/ntoskrnl.exe/ntoskrnl.c b/dlls/ntoskrnl.exe/ntoskrnl.c
index bfac3970117..d50eac6c821 100644
--- a/dlls/ntoskrnl.exe/ntoskrnl.c
+++ b/dlls/ntoskrnl.exe/ntoskrnl.c
@@ -3079,9 +3079,13 @@ MM_SYSTEMSIZE WINAPI MmQuerySystemSize(void)
 /***********************************************************************
  *           KeInitializeDpc   (NTOSKRNL.EXE.@)
  */
-VOID WINAPI KeInitializeDpc(PRKDPC Dpc, PKDEFERRED_ROUTINE DeferredRoutine, PVOID DeferredContext)
+void WINAPI KeInitializeDpc(KDPC *dpc, PKDEFERRED_ROUTINE deferred_routine, void *deferred_context)
 {
-    FIXME("stub\n");
+    FIXME("dpc %p, deferred_routine %p, deferred_context %p semi-stub.\n",
+            dpc, deferred_routine, deferred_context);
+
+    dpc->DeferredRoutine = deferred_routine;
+    dpc->DeferredContext = deferred_context;
 }
 
 /***********************************************************************
diff --git a/include/ddk/wdm.h b/include/ddk/wdm.h
index 8368f8c6e9f..9dce98516b6 100644
--- a/include/ddk/wdm.h
+++ b/include/ddk/wdm.h
@@ -1695,6 +1695,7 @@ void      WINAPI KeEnterCriticalRegion(void);
 void      WINAPI KeGenericCallDpc(PKDEFERRED_ROUTINE,PVOID);
 ULONG     WINAPI KeGetCurrentProcessorNumber(void);
 PKTHREAD  WINAPI KeGetCurrentThread(void);
+void      WINAPI KeInitializeDpc(KDPC*,PKDEFERRED_ROUTINE,void*);
 void      WINAPI KeInitializeEvent(PRKEVENT,EVENT_TYPE,BOOLEAN);
 void      WINAPI KeInitializeMutex(PRKMUTEX,ULONG);
 void      WINAPI KeInitializeSemaphore(PRKSEMAPHORE,LONG,LONG);
-- 
2.26.2




More information about the wine-devel mailing list