Add stub for KeWaitForMultipleObjects.

This commit is contained in:
Erich E. Hoover 2015-01-22 13:50:03 -07:00
parent 6a10f6d38f
commit 6a1d2cdd7b
5 changed files with 99 additions and 1 deletions

View File

@ -37,8 +37,9 @@ Wine. All those differences are also documented on the
Included bug fixes and improvements
===================================
**Bugfixes and features included in the next upcoming release [16]:**
**Bugfixes and features included in the next upcoming release [17]:**
* Add stub for KeWaitForMultipleObjects
* Add stubs for D3DXCreateAnimationController interface
* Anno 1602 installer depends on Windows 98 behavior of SHFileOperationW ([Wine Bug #37916](https://bugs.winehq.org/show_bug.cgi?id=37916))
* Avseq crashes when multisampling is enabled ([Wine Bug #31998](https://bugs.winehq.org/show_bug.cgi?id=31998))

1
debian/changelog vendored
View File

@ -1,4 +1,5 @@
wine-staging (1.7.35) UNRELEASED; urgency=low
* Add stub for KeWaitForMultipleObjects.
* Add support for patchinstall.sh parameters '--no-patchlist' and '--no-autoconf'.
* Add support for Gentoo epatch backend to patchinstall.sh.
* Automatically enable fallback method to apply patches when running from inside of a git subdirectory.

View File

@ -0,0 +1,79 @@
From 0fa1a31ae872769dc2ccf069184d36117b767435 Mon Sep 17 00:00:00 2001
From: Austin English <austinenglish@gmail.com>
Date: Wed, 24 Dec 2014 15:35:23 -0600
Subject: ntoskrnl.exe: add KeWaitForMultipleObjects stub
---
dlls/ntoskrnl.exe/ntoskrnl.c | 13 +++++++++++++
dlls/ntoskrnl.exe/ntoskrnl.exe.spec | 2 +-
include/ddk/ntddk.h | 17 +++++++++++++++++
3 files changed, 31 insertions(+), 1 deletion(-)
diff --git a/dlls/ntoskrnl.exe/ntoskrnl.c b/dlls/ntoskrnl.exe/ntoskrnl.c
index af1626d..97e09a7 100644
--- a/dlls/ntoskrnl.exe/ntoskrnl.c
+++ b/dlls/ntoskrnl.exe/ntoskrnl.c
@@ -1480,6 +1480,19 @@ NTSTATUS WINAPI KeWaitForSingleObject(PVOID Object,
}
/***********************************************************************
+ * KeWaitForMultipleObjects (NTOSKRNL.EXE.@)
+ */
+NTSTATUS WINAPI KeWaitForMultipleObjects(ULONG Count, PVOID Object[], WAIT_TYPE WaitType,
+ KWAIT_REASON WaitReason, KPROCESSOR_MODE WaitMode,
+ BOOLEAN Alertable, PLARGE_INTEGER Timeout,
+ PKWAIT_BLOCK WaitBlockArray)
+{
+ FIXME( "stub: %u, %p, %d, %d, %d, %d, %p, %p\n", Count, Object, WaitType, WaitReason, WaitMode,
+ Alertable, Timeout, WaitBlockArray );
+ return STATUS_NOT_IMPLEMENTED;
+}
+
+/***********************************************************************
* IoRegisterFileSystem (NTOSKRNL.EXE.@)
*/
VOID WINAPI IoRegisterFileSystem(PDEVICE_OBJECT DeviceObject)
diff --git a/dlls/ntoskrnl.exe/ntoskrnl.exe.spec b/dlls/ntoskrnl.exe/ntoskrnl.exe.spec
index b824250..720ce3e 100644
--- a/dlls/ntoskrnl.exe/ntoskrnl.exe.spec
+++ b/dlls/ntoskrnl.exe/ntoskrnl.exe.spec
@@ -627,7 +627,7 @@
@ stub KeUpdateRunTime
@ stub KeUpdateSystemTime
@ stub KeUserModeCallback
-@ stub KeWaitForMultipleObjects
+@ stdcall KeWaitForMultipleObjects(long ptr long long long long ptr ptr)
@ stdcall KeWaitForMutexObject(ptr long long long ptr)
@ stdcall KeWaitForSingleObject(ptr long long long ptr)
@ stub KiBugCheckData
diff --git a/include/ddk/ntddk.h b/include/ddk/ntddk.h
index 56f2f35..ac6484f 100644
--- a/include/ddk/ntddk.h
+++ b/include/ddk/ntddk.h
@@ -140,6 +140,23 @@ typedef struct _FILE_VALID_DATA_LENGTH_INFORMATION
LARGE_INTEGER ValidDataLength;
} FILE_VALID_DATA_LENGTH_INFORMATION, *PFILE_VALID_DATA_LENGTH_INFORMATION;
+typedef struct _KWAIT_BLOCK
+{
+ LIST_ENTRY WaitListEntry;
+ PKTHREAD Thread;
+ PVOID Object;
+ struct _KWAIT_BLOCK *NextWaitBlock;
+ USHORT WaitKey;
+ USHORT WaitType;
+} KWAIT_BLOCK, *PKWAIT_BLOCK;
+
+/* FIXME: belongs in ntdef.h */
+typedef enum _WAIT_TYPE
+{
+ WaitAll,
+ WaitAny
+} WAIT_TYPE;
+
typedef VOID (WINAPI *PDRIVER_NOTIFICATION_CALLBACK_ROUTINE)(PVOID,PVOID);
typedef VOID (WINAPI *PDRIVER_REINITIALIZE)(PDRIVER_OBJECT,PVOID,ULONG);
typedef VOID (WINAPI *PLOAD_IMAGE_NOTIFY_ROUTINE)(PUNICODE_STRING,HANDLE,PIMAGE_INFO);
--
1.9.1

View File

@ -0,0 +1 @@
Fixes: Add stub for KeWaitForMultipleObjects

View File

@ -128,6 +128,7 @@ patch_enable_all ()
enable_ntdll_WRITECOPY="$1"
enable_ntdll_WinSqm="$1"
enable_ntoskrnl_Emulator="$1"
enable_ntoskrnl_KeWaitForMultipleObjects="$1"
enable_nvapi_Stub_DLL="$1"
enable_nvcuda_CUDA_Support="$1"
enable_nvcuvid_CUDA_Video_Support="$1"
@ -411,6 +412,9 @@ patch_enable ()
ntoskrnl-Emulator)
enable_ntoskrnl_Emulator="$2"
;;
ntoskrnl-KeWaitForMultipleObjects)
enable_ntoskrnl_KeWaitForMultipleObjects="$2"
;;
nvapi-Stub_DLL)
enable_nvapi_Stub_DLL="$2"
;;
@ -2195,6 +2199,18 @@ if test "$enable_ntoskrnl_Emulator" -eq 1; then
) >> "$patchlist"
fi
# Patchset ntoskrnl-KeWaitForMultipleObjects
# |
# | Modified files:
# | * dlls/ntoskrnl.exe/ntoskrnl.c, dlls/ntoskrnl.exe/ntoskrnl.exe.spec, include/ddk/ntddk.h
# |
if test "$enable_ntoskrnl_KeWaitForMultipleObjects" -eq 1; then
patch_apply ntoskrnl-KeWaitForMultipleObjects/0001-ntoskrnl.exe-add-KeWaitForMultipleObjects-stub.patch
(
echo '+ { "Austin English", "ntoskrnl.exe: add KeWaitForMultipleObjects stub.", 1 },';
) >> "$patchlist"
fi
# Patchset nvcuda-CUDA_Support
# |
# | Modified files: