wine-staging/patches/kernel32-UmsStubs/0001-kernel32-Add-a-bunch-of-kernel32-stubs.patch
2016-08-20 15:47:51 +02:00

585 lines
26 KiB
Diff

From d3338512fe2237158a7c360e039335584f105068 Mon Sep 17 00:00:00 2001
From: Dmitry Timoshkov <dmitry@baikal.ru>
Date: Thu, 16 Jun 2016 18:56:21 +0800
Subject: kernel32: Add a bunch of kernel32 stubs.
64-bit ACDSee Pro 9.0 on start up queries them with GetProcAddress() and
fails to start if any of these APIs is missing.
---
.../api-ms-win-core-processthreads-l1-1-0.spec | 8 +-
.../api-ms-win-core-processthreads-l1-1-1.spec | 8 +-
.../api-ms-win-core-processthreads-l1-1-2.spec | 8 +-
dlls/kernel32/kernel32.spec | 34 ++---
dlls/kernel32/sync.c | 145 +++++++++++++++++++++
dlls/kernel32/thread.c | 48 +++++++
dlls/kernelbase/kernelbase.spec | 8 +-
include/winbase.h | 19 +++
include/winnt.h | 22 +++-
9 files changed, 266 insertions(+), 34 deletions(-)
diff --git a/dlls/api-ms-win-core-processthreads-l1-1-0/api-ms-win-core-processthreads-l1-1-0.spec b/dlls/api-ms-win-core-processthreads-l1-1-0/api-ms-win-core-processthreads-l1-1-0.spec
index 80a4780..ed4e803 100644
--- a/dlls/api-ms-win-core-processthreads-l1-1-0/api-ms-win-core-processthreads-l1-1-0.spec
+++ b/dlls/api-ms-win-core-processthreads-l1-1-0/api-ms-win-core-processthreads-l1-1-0.spec
@@ -2,9 +2,9 @@
@ stub CreateProcessAsUserW
@ stdcall CreateProcessW(wstr wstr ptr ptr long long ptr wstr ptr ptr) kernel32.CreateProcessW
@ stdcall CreateRemoteThread(long ptr long ptr long long ptr) kernel32.CreateRemoteThread
-@ stub CreateRemoteThreadEx
+@ stdcall CreateRemoteThreadEx(long ptr long ptr long long ptr ptr) kernel32.CreateRemoteThreadEx
@ stdcall CreateThread(ptr long ptr long long ptr) kernel32.CreateThread
-@ stub DeleteProcThreadAttributeList
+@ stdcall DeleteProcThreadAttributeList(ptr) kernel32.DeleteProcThreadAttributeList
@ stdcall ExitProcess(long) kernel32.ExitProcess
@ stdcall ExitThread(long) kernel32.ExitThread
@ stdcall FlushProcessWriteBuffers() kernel32.FlushProcessWriteBuffers
@@ -23,7 +23,7 @@
@ stdcall GetThreadId(ptr) kernel32.GetThreadId
@ stdcall GetThreadPriority(long) kernel32.GetThreadPriority
@ stdcall GetThreadPriorityBoost(long ptr) kernel32.GetThreadPriorityBoost
-@ stub InitializeProcThreadAttributeList
+@ stdcall InitializeProcThreadAttributeList(ptr long long ptr) kernel32.InitializeProcThreadAttributeList
@ stub OpenProcessToken
@ stdcall OpenThread(long long long) kernel32.OpenThread
@ stub OpenThreadToken
@@ -46,4 +46,4 @@
@ stdcall TlsFree(long) kernel32.TlsFree
@ stdcall TlsGetValue(long) kernel32.TlsGetValue
@ stdcall TlsSetValue(long ptr) kernel32.TlsSetValue
-@ stub UpdateProcThreadAttribute
+@ stdcall UpdateProcThreadAttribute(ptr long long ptr long ptr ptr) kernel32.UpdateProcThreadAttribute
diff --git a/dlls/api-ms-win-core-processthreads-l1-1-1/api-ms-win-core-processthreads-l1-1-1.spec b/dlls/api-ms-win-core-processthreads-l1-1-1/api-ms-win-core-processthreads-l1-1-1.spec
index 84f43d8..9d321af 100644
--- a/dlls/api-ms-win-core-processthreads-l1-1-1/api-ms-win-core-processthreads-l1-1-1.spec
+++ b/dlls/api-ms-win-core-processthreads-l1-1-1/api-ms-win-core-processthreads-l1-1-1.spec
@@ -2,9 +2,9 @@
@ stdcall CreateProcessAsUserW(long wstr wstr ptr ptr long long ptr wstr ptr ptr) advapi32.CreateProcessAsUserW
@ stdcall CreateProcessW(wstr wstr ptr ptr long long ptr wstr ptr ptr) kernel32.CreateProcessW
@ stdcall CreateRemoteThread(long ptr long ptr long long ptr) kernel32.CreateRemoteThread
-@ stub CreateRemoteThreadEx
+@ stdcall CreateRemoteThreadEx(long ptr long ptr long long ptr ptr) kernel32.CreateRemoteThreadEx
@ stdcall CreateThread(ptr long ptr long long ptr) kernel32.CreateThread
-@ stub DeleteProcThreadAttributeList
+@ stdcall DeleteProcThreadAttributeList(ptr) kernel32.DeleteProcThreadAttributeList
@ stdcall ExitProcess(long) kernel32.ExitProcess
@ stdcall ExitThread(long) kernel32.ExitThread
@ stdcall FlushInstructionCache(long long long) kernel32.FlushInstructionCache
@@ -32,7 +32,7 @@
@ stdcall GetThreadPriority(long) kernel32.GetThreadPriority
@ stdcall GetThreadPriorityBoost(long ptr) kernel32.GetThreadPriorityBoost
@ stdcall GetThreadTimes(long ptr ptr ptr ptr) kernel32.GetThreadTimes
-@ stub InitializeProcThreadAttributeList
+@ stdcall InitializeProcThreadAttributeList(ptr long long ptr) kernel32.InitializeProcThreadAttributeList
@ stdcall IsProcessorFeaturePresent(long) kernel32.IsProcessorFeaturePresent
@ stdcall OpenProcess(long long long) kernel32.OpenProcess
@ stdcall OpenProcessToken(long long ptr) advapi32.OpenProcessToken
@@ -60,4 +60,4 @@
@ stdcall TlsFree(long) kernel32.TlsFree
@ stdcall TlsGetValue(long) kernel32.TlsGetValue
@ stdcall TlsSetValue(long ptr) kernel32.TlsSetValue
-@ stub UpdateProcThreadAttribute
+@ stdcall UpdateProcThreadAttribute(ptr long long ptr long ptr ptr) kernel32.UpdateProcThreadAttribute
diff --git a/dlls/api-ms-win-core-processthreads-l1-1-2/api-ms-win-core-processthreads-l1-1-2.spec b/dlls/api-ms-win-core-processthreads-l1-1-2/api-ms-win-core-processthreads-l1-1-2.spec
index 6430c63..0e30f18 100644
--- a/dlls/api-ms-win-core-processthreads-l1-1-2/api-ms-win-core-processthreads-l1-1-2.spec
+++ b/dlls/api-ms-win-core-processthreads-l1-1-2/api-ms-win-core-processthreads-l1-1-2.spec
@@ -2,9 +2,9 @@
@ stub CreateProcessAsUserW
@ stdcall CreateProcessW(wstr wstr ptr ptr long long ptr wstr ptr ptr) kernel32.CreateProcessW
@ stdcall CreateRemoteThread(long ptr long ptr long long ptr) kernel32.CreateRemoteThread
-@ stub CreateRemoteThreadEx
+@ stdcall CreateRemoteThreadEx(long ptr long ptr long long ptr ptr) kernel32.CreateRemoteThreadEx
@ stdcall CreateThread(ptr long ptr long long ptr) kernel32.CreateThread
-@ stub DeleteProcThreadAttributeList
+@ stdcall DeleteProcThreadAttributeList(ptr) kernel32.DeleteProcThreadAttributeList
@ stdcall ExitProcess(long) kernel32.ExitProcess
@ stdcall ExitThread(long) kernel32.ExitThread
@ stdcall FlushInstructionCache(long long long) kernel32.FlushInstructionCache
@@ -36,7 +36,7 @@
@ stdcall GetThreadPriority(long) kernel32.GetThreadPriority
@ stdcall GetThreadPriorityBoost(long ptr) kernel32.GetThreadPriorityBoost
@ stdcall GetThreadTimes(long ptr ptr ptr ptr) kernel32.GetThreadTimes
-@ stub InitializeProcThreadAttributeList
+@ stdcall InitializeProcThreadAttributeList(ptr long long ptr) kernel32.InitializeProcThreadAttributeList
@ stub IsProcessCritical
@ stdcall IsProcessorFeaturePresent(long) kernel32.IsProcessorFeaturePresent
@ stdcall OpenProcess(long long long) kernel32.OpenProcess
@@ -67,4 +67,4 @@
@ stdcall TlsFree(long) kernel32.TlsFree
@ stdcall TlsGetValue(long) kernel32.TlsGetValue
@ stdcall TlsSetValue(long ptr) kernel32.TlsSetValue
-@ stub UpdateProcThreadAttribute
+@ stdcall UpdateProcThreadAttribute(ptr long long ptr long ptr ptr) kernel32.UpdateProcThreadAttribute
diff --git a/dlls/kernel32/kernel32.spec b/dlls/kernel32/kernel32.spec
index 239965f..91df122 100644
--- a/dlls/kernel32/kernel32.spec
+++ b/dlls/kernel32/kernel32.spec
@@ -319,7 +319,7 @@
# @ stub CreateProcessInternalWSecure
@ stdcall CreateProcessW(wstr wstr ptr ptr long long ptr wstr ptr ptr)
@ stdcall CreateRemoteThread(long ptr long ptr long long ptr)
-# @ stub CreateRemoteThreadEx
+@ stdcall CreateRemoteThreadEx(long ptr long ptr long long ptr ptr)
@ stdcall CreateSemaphoreA(ptr long long str)
@ stdcall CreateSemaphoreExA(ptr long long str long long)
@ stdcall CreateSemaphoreExW(ptr long long wstr long long)
@@ -340,8 +340,8 @@
@ stdcall CreateTimerQueue ()
@ stdcall CreateTimerQueueTimer(ptr long ptr ptr long long long)
@ stdcall CreateToolhelp32Snapshot(long long)
-# @ stub -arch=x86_64 CreateUmsCompletionList
-# @ stub -arch=x86_64 CreateUmsThreadContext
+@ stdcall -arch=x86_64 CreateUmsCompletionList(ptr)
+@ stdcall -arch=x86_64 CreateUmsThreadContext(ptr)
@ stub CreateVirtualBuffer
@ stdcall CreateWaitableTimerA(ptr long str)
@ stdcall CreateWaitableTimerExA(ptr str long long)
@@ -367,17 +367,17 @@
# @ stub DeleteFileTransactedA
# @ stub DeleteFileTransactedW
@ stdcall DeleteFileW(wstr)
-# @ stub DeleteProcThreadAttributeList
+@ stdcall DeleteProcThreadAttributeList(ptr)
# @ stub DisableThreadProfiling
@ stdcall DisassociateCurrentThreadFromCallback(ptr) ntdll.TpDisassociateCallback
@ stdcall DeleteTimerQueue(long)
@ stdcall DeleteTimerQueueEx (long long)
@ stdcall DeleteTimerQueueTimer(long long long)
-# @ stub -arch=x86_64 DeleteUmsCompletionList
-# @ stub -arch=x86_64 DeleteUmsThreadContext
+@ stdcall -arch=x86_64 DeleteUmsCompletionList(ptr)
+@ stdcall -arch=x86_64 DeleteUmsThreadContext(ptr)
@ stdcall DeleteVolumeMountPointA(str)
@ stdcall DeleteVolumeMountPointW(wstr)
-# @ stub -arch=x86_64 DequeueUmsCompletionListItems
+@ stdcall -arch=x86_64 DequeueUmsCompletionListItems(ptr long ptr)
@ stdcall DeviceIoControl(long long ptr long ptr long ptr ptr)
@ stdcall DisableThreadLibraryCalls(long)
@ stdcall DisconnectNamedPipe(long)
@@ -434,10 +434,10 @@
@ stdcall EnumUILanguagesW(ptr long long)
# @ stub EnumerateLocalComputerNamesA
# @ stub EnumerateLocalComputerNamesW
-# @ stub -arch=x86_64 EnterUmsSchedulingMode
+@ stdcall -arch=x86_64 EnterUmsSchedulingMode(ptr)
@ stdcall EraseTape(ptr long long)
@ stdcall EscapeCommFunction(long long)
-# @ stub -arch=x86_64 ExecuteUmsThread
+@ stdcall -arch=x86_64 ExecuteUmsThread(ptr)
@ stdcall ExitProcess(long)
@ stdcall ExitThread(long)
@ stub ExitVDM
@@ -635,7 +635,7 @@
@ stdcall GetCurrentProcessorNumberEx(ptr) ntdll.RtlGetCurrentProcessorNumberEx
@ stdcall -norelay GetCurrentThread()
@ stdcall -norelay GetCurrentThreadId()
-# @ stub -arch=x86_64 GetCurrentUmsThread
+@ stdcall -arch=x86_64 GetCurrentUmsThread()
@ stdcall GetDateFormatA(long long ptr str ptr long)
@ stdcall GetDateFormatEx(wstr long ptr wstr ptr long wstr)
@ stdcall GetDateFormatW(long long ptr wstr ptr long)
@@ -733,7 +733,7 @@
# @ stub GetNamedPipeServerProcessId
# @ stub GetNamedPipeServerSessionId
@ stdcall GetNativeSystemInfo(ptr)
-# @ stub -arch=x86_64 GetNextUmsListItem
+@ stdcall -arch=x86_64 GetNextUmsListItem(ptr)
@ stub GetNextVDMCommand
@ stub GetNlsSectionName
# @ stub GetNLSVersion
@@ -863,7 +863,7 @@
@ stdcall GetTimeZoneInformationForYear(long ptr ptr)
@ stdcall GetThreadUILanguage()
# @ stub GetUILanguageInfo
-# @ stub -arch=x86_64 GetUmsCompletionListEvent
+@ stdcall -arch=x86_64 GetUmsCompletionListEvent(ptr ptr)
# @ stub -arch=x86_64 GetUmsSystemThreadInformation
@ stdcall GetUserDefaultLCID()
@ stdcall GetUserDefaultLangID()
@@ -945,7 +945,7 @@
@ stdcall InitializeCriticalSection(ptr)
@ stdcall InitializeCriticalSectionAndSpinCount(ptr long)
@ stdcall InitializeCriticalSectionEx(ptr long long)
-# @ stub InitializeProcThreadAttributeList
+@ stdcall InitializeProcThreadAttributeList(ptr long long ptr)
@ stdcall InitializeSListHead(ptr) ntdll.RtlInitializeSListHead
@ stdcall InitializeSRWLock(ptr) ntdll.RtlInitializeSRWLock
@ stdcall -arch=i386 InterlockedCompareExchange (ptr long long)
@@ -1172,7 +1172,7 @@
@ stdcall QueryThreadCycleTime(long ptr)
# @ stub QueryThreadProfiling
# @ stub QueryThreadpoolStackInformation
-# @ stub -arch=x86_64 QueryUmsThreadInformation
+@ stdcall -arch=x86_64 QueryUmsThreadInformation(ptr long ptr long ptr)
@ stdcall QueryUnbiasedInterruptTime(ptr)
@ stub QueryWin31IniFilesMappedToRegistry
@ stdcall QueueUserAPC(ptr long long)
@@ -1461,7 +1461,7 @@
@ stdcall SetThreadpoolWait(ptr long ptr)
@ stdcall SetTimeZoneInformation(ptr)
@ stub SetTimerQueueTimer
-# @ stub -arch=x86_64 SetUmsThreadInformation
+@ stdcall -arch=x86_64 SetUmsThreadInformation(ptr long ptr long)
@ stdcall SetUnhandledExceptionFilter(ptr)
@ stdcall SetUserGeoID(long)
@ stub SetVDMCurrentDirectories
@@ -1521,7 +1521,7 @@
# @ stub -arch=x86_64 uaw_wcsicmp
# @ stub -arch=x86_64 uaw_wcslen
# @ stub -arch=x86_64 uaw_wcsrchr
-# @ stub -arch=x86_64 UmsThreadYield
+@ stdcall -arch=x86_64 UmsThreadYield(ptr)
# @ stub -arch=x86_64 __misaligned_access
@ stdcall -i386 -private UTRegister(long str str str ptr ptr ptr) krnl386.exe16.UTRegister
@ stdcall -i386 -private UTUnRegister(long) krnl386.exe16.UTUnRegister
@@ -1538,7 +1538,7 @@
@ stdcall UnregisterWait(long)
@ stdcall UnregisterWaitEx(long long)
# @ stub UpdateCalendarDayOfWeek
-# @ stub UpdateProcThreadAttribute
+@ stdcall UpdateProcThreadAttribute(ptr long long ptr long ptr ptr)
@ stdcall UpdateResourceA(long str str long ptr long)
@ stdcall UpdateResourceW(long wstr wstr long ptr long)
@ stub VDMConsoleOperation
diff --git a/dlls/kernel32/sync.c b/dlls/kernel32/sync.c
index b8222db..1eb591d 100644
--- a/dlls/kernel32/sync.c
+++ b/dlls/kernel32/sync.c
@@ -2452,3 +2452,148 @@ BOOL WINAPI SleepConditionVariableSRW( RTL_CONDITION_VARIABLE *variable, RTL_SRW
}
return TRUE;
}
+
+
+/***********************************************************************
+ * CreateUmsCompletionList (KERNEL32.@)
+ */
+BOOL WINAPI CreateUmsCompletionList( PUMS_COMPLETION_LIST *list )
+{
+ FIXME( "%p: stub\n", list );
+ SetLastError( ERROR_CALL_NOT_IMPLEMENTED );
+ return FALSE;
+}
+
+
+/***********************************************************************
+ * DequeueUmsCompletionListItems (KERNEL32.@)
+ */
+BOOL WINAPI DequeueUmsCompletionListItems( void *list, DWORD timeout, PUMS_CONTEXT *ctx )
+{
+ FIXME( "%p,%08x,%p: stub\n", list, timeout, ctx );
+ SetLastError( ERROR_CALL_NOT_IMPLEMENTED );
+ return FALSE;
+}
+
+
+/***********************************************************************
+ * DeleteUmsCompletionList (KERNEL32.@)
+ */
+BOOL WINAPI DeleteUmsCompletionList( PUMS_COMPLETION_LIST list )
+{
+ FIXME( "%p: stub\n", list );
+ SetLastError( ERROR_CALL_NOT_IMPLEMENTED );
+ return FALSE;
+}
+
+
+/***********************************************************************
+ * GetUmsCompletionListEvent (KERNEL32.@)
+ */
+BOOL WINAPI GetUmsCompletionListEvent( PUMS_COMPLETION_LIST list, HANDLE *event )
+{
+ FIXME( "%p,%p: stub\n", list, event );
+ SetLastError( ERROR_CALL_NOT_IMPLEMENTED );
+ return FALSE;
+}
+
+
+/***********************************************************************
+ * CreateUmsThreadContext (KERNEL32.@)
+ */
+BOOL WINAPI CreateUmsThreadContext( PUMS_CONTEXT *ctx )
+{
+ FIXME( "%p: stub\n", ctx );
+ SetLastError( ERROR_CALL_NOT_IMPLEMENTED );
+ return FALSE;
+}
+
+
+/***********************************************************************
+ * DeleteUmsThreadContext (KERNEL32.@)
+ */
+BOOL WINAPI DeleteUmsThreadContext( PUMS_CONTEXT ctx )
+{
+ FIXME( "%p: stub\n", ctx );
+ SetLastError( ERROR_CALL_NOT_IMPLEMENTED );
+ return FALSE;
+}
+
+
+/***********************************************************************
+ * EnterUmsSchedulingMode (KERNEL32.@)
+ */
+BOOL WINAPI EnterUmsSchedulingMode( UMS_SCHEDULER_STARTUP_INFO *info )
+{
+ FIXME( "%p: stub\n", info );
+ SetLastError( ERROR_CALL_NOT_IMPLEMENTED );
+ return FALSE;
+}
+
+
+/***********************************************************************
+ * ExecuteUmsThread (KERNEL32.@)
+ */
+BOOL WINAPI ExecuteUmsThread( PUMS_CONTEXT ctx )
+{
+ FIXME( "%p: stub\n", ctx );
+ SetLastError( ERROR_CALL_NOT_IMPLEMENTED );
+ return FALSE;
+}
+
+
+/***********************************************************************
+ * GetCurrentUmsThread (KERNEL32.@)
+ */
+PUMS_CONTEXT WINAPI GetCurrentUmsThread( void )
+{
+ FIXME( "stub\n" );
+ SetLastError( ERROR_CALL_NOT_IMPLEMENTED );
+ return FALSE;
+}
+
+
+/***********************************************************************
+ * GetNextUmsListItem (KERNEL32.@)
+ */
+PUMS_CONTEXT WINAPI GetNextUmsListItem( PUMS_CONTEXT ctx )
+{
+ FIXME( "%p: stub\n", ctx );
+ SetLastError( ERROR_CALL_NOT_IMPLEMENTED );
+ return NULL;
+}
+
+
+/***********************************************************************
+ * QueryUmsThreadInformation (KERNEL32.@)
+ */
+BOOL WINAPI QueryUmsThreadInformation( PUMS_CONTEXT ctx, UMS_THREAD_INFO_CLASS class,
+ void *buf, ULONG length, ULONG *ret_length )
+{
+ FIXME( "%p,%08x,%p,%08x,%p: stub\n", ctx, class, buf, length, ret_length );
+ SetLastError( ERROR_CALL_NOT_IMPLEMENTED );
+ return FALSE;
+}
+
+
+/***********************************************************************
+ * SetUmsThreadInformation (KERNEL32.@)
+ */
+BOOL WINAPI SetUmsThreadInformation( PUMS_CONTEXT ctx, UMS_THREAD_INFO_CLASS class,
+ void *buf, ULONG length )
+{
+ FIXME( "%p,%08x,%p,%08x: stub\n", ctx, class, buf, length );
+ SetLastError( ERROR_CALL_NOT_IMPLEMENTED );
+ return FALSE;
+}
+
+
+/***********************************************************************
+ * UmsThreadYield (KERNEL32.@)
+ */
+BOOL WINAPI UmsThreadYield( void *param )
+{
+ FIXME( "%p: stub\n", param );
+ SetLastError( ERROR_CALL_NOT_IMPLEMENTED );
+ return FALSE;
+}
diff --git a/dlls/kernel32/thread.c b/dlls/kernel32/thread.c
index 82ccebe..5ba3a7a 100644
--- a/dlls/kernel32/thread.c
+++ b/dlls/kernel32/thread.c
@@ -113,6 +113,54 @@ HANDLE WINAPI CreateRemoteThread( HANDLE hProcess, SECURITY_ATTRIBUTES *sa, SIZE
}
+/***************************************************************************
+ * CreateRemoteThreadEx (KERNEL32.@)
+ */
+HANDLE WINAPI CreateRemoteThreadEx( HANDLE hProcess, SECURITY_ATTRIBUTES *sa, SIZE_T stack,
+ LPTHREAD_START_ROUTINE start, LPVOID param, DWORD flags,
+ LPPROC_THREAD_ATTRIBUTE_LIST attrs, LPDWORD id )
+{
+ FIXME( "attribute list ignored\n" );
+ return CreateRemoteThread( hProcess, sa, stack, start, param, flags, id );
+}
+
+
+/***************************************************************************
+ * InitializeProcThreadAttributeList (KERNEL32.@)
+ */
+BOOL WINAPI InitializeProcThreadAttributeList( LPPROC_THREAD_ATTRIBUTE_LIST *attrs,
+ DWORD count, DWORD flags, PSIZE_T size )
+{
+ FIXME( "%p,%u,%08x,%p: stub\n", attrs, count, flags, size );
+ SetLastError( ERROR_CALL_NOT_IMPLEMENTED );
+ return FALSE;
+}
+
+
+/***************************************************************************
+ * DeleteProcThreadAttributeList (KERNEL32.@)
+ */
+void WINAPI DeleteProcThreadAttributeList( LPPROC_THREAD_ATTRIBUTE_LIST attrs )
+{
+ FIXME( "%p: stub\n", attrs );
+ SetLastError( ERROR_CALL_NOT_IMPLEMENTED );
+}
+
+
+/***************************************************************************
+ * UpdateProcThreadAttribute (KERNEL32.@)
+ */
+BOOL WINAPI UpdateProcThreadAttribute( LPPROC_THREAD_ATTRIBUTE_LIST attrs, DWORD flags,
+ DWORD_PTR attributes, void *value, SIZE_T size,
+ void *prev_value, SIZE_T *ret_size )
+{
+ FIXME( "%p,%08x,%08lx,%p,%08lx,%p,%p: stub\n", attrs, flags, attributes, value,
+ size, prev_value, ret_size );
+ SetLastError( ERROR_CALL_NOT_IMPLEMENTED );
+ return FALSE;
+}
+
+
/***********************************************************************
* OpenThread [KERNEL32.@] Retrieves a handle to a thread from its thread id
*/
diff --git a/dlls/kernelbase/kernelbase.spec b/dlls/kernelbase/kernelbase.spec
index e35ef8b..23ca440 100644
--- a/dlls/kernelbase/kernelbase.spec
+++ b/dlls/kernelbase/kernelbase.spec
@@ -85,7 +85,7 @@
@ stdcall CreatePrivateObjectSecurityEx(ptr ptr ptr ptr long long long ptr) advapi32.CreatePrivateObjectSecurityEx
@ stdcall CreatePrivateObjectSecurityWithMultipleInheritance(ptr ptr ptr ptr long long long long ptr) advapi32.CreatePrivateObjectSecurityWithMultipleInheritance
@ stdcall CreateRemoteThread(long ptr long ptr long long ptr) kernel32.CreateRemoteThread
-@ stub CreateRemoteThreadEx
+@ stdcall CreateRemoteThreadEx(long ptr long ptr long long ptr ptr) kernel32.CreateRemoteThreadEx
@ stdcall CreateRestrictedToken(long long long ptr long ptr long ptr ptr) advapi32.CreateRestrictedToken
@ stdcall CreateSemaphoreExW(ptr long long wstr long long) kernel32.CreateSemaphoreExW
@ stdcall CreateThread(ptr long ptr long long ptr) kernel32.CreateThread
@@ -107,7 +107,7 @@
@ stdcall DeleteCriticalSection(ptr) kernel32.DeleteCriticalSection
@ stdcall DeleteFileA(str) kernel32.DeleteFileA
@ stdcall DeleteFileW(wstr) kernel32.DeleteFileW
-@ stub DeleteProcThreadAttributeList
+@ stdcall DeleteProcThreadAttributeList(ptr) kernel32.DeleteProcThreadAttributeList
@ stdcall DeleteTimerQueueEx(long long) kernel32.DeleteTimerQueueEx
@ stdcall DeleteTimerQueueTimer(long long long) kernel32.DeleteTimerQueueTimer
@ stdcall DeleteVolumeMountPointW(wstr) kernel32.DeleteVolumeMountPointW
@@ -368,7 +368,7 @@
@ stdcall InitializeCriticalSection(ptr) kernel32.InitializeCriticalSection
@ stdcall InitializeCriticalSectionAndSpinCount(ptr long) kernel32.InitializeCriticalSectionAndSpinCount
@ stdcall InitializeCriticalSectionEx(ptr long long) kernel32.InitializeCriticalSectionEx
-@ stub InitializeProcThreadAttributeList
+@ stdcall InitializeProcThreadAttributeList(ptr long long ptr) kernel32.InitializeProcThreadAttributeList
@ stdcall InitializeSListHead(ptr) kernel32.InitializeSListHead
@ stdcall InitializeSRWLock(ptr) kernel32.InitializeSRWLock
@ stdcall InitializeSecurityDescriptor(ptr long) advapi32.InitializeSecurityDescriptor
@@ -586,7 +586,7 @@
@ stdcall UnlockFileEx(long long long long ptr) kernel32.UnlockFileEx
@ stdcall UnmapViewOfFile(ptr) kernel32.UnmapViewOfFile
@ stdcall UnregisterWaitEx(long long) kernel32.UnregisterWaitEx
-@ stub UpdateProcThreadAttribute
+@ stdcall UpdateProcThreadAttribute(ptr long long ptr long ptr ptr) kernel32.UpdateProcThreadAttribute
@ stdcall VerLanguageNameA(long str long) kernel32.VerLanguageNameA
@ stdcall VerLanguageNameW(long wstr long) kernel32.VerLanguageNameW
@ stdcall VirtualAlloc(ptr long long long) kernel32.VirtualAlloc
diff --git a/include/winbase.h b/include/winbase.h
index 99e3107..2311011 100644
--- a/include/winbase.h
+++ b/include/winbase.h
@@ -1644,6 +1644,21 @@ typedef struct _REASON_CONTEXT
#define RESOURCE_ENUM_MUI_SYSTEM 0x0004
#define RESOURCE_ENUM_VALIDATE 0x0008
+typedef struct _PROC_THREAD_ATTRIBUTE_LIST *PPROC_THREAD_ATTRIBUTE_LIST, *LPPROC_THREAD_ATTRIBUTE_LIST;
+typedef void *PUMS_CONTEXT;
+typedef void *PUMS_COMPLETION_LIST;
+typedef PRTL_UMS_SCHEDULER_ENTRY_POINT PUMS_SCHEDULER_ENTRY_POINT;
+typedef struct _UMS_SCHEDULER_STARTUP_INFO
+{
+ ULONG UmsVersion;
+ PUMS_COMPLETION_LIST CompletionList;
+ PUMS_SCHEDULER_ENTRY_POINT SchedulerProc;
+ PVOID SchedulerParam;
+} UMS_SCHEDULER_STARTUP_INFO, *PUMS_SCHEDULER_STARTUP_INFO;
+
+typedef enum _RTL_UMS_SCHEDULER_REASON UMS_SCHEDULER_REASON;
+typedef enum _RTL_UMS_THREAD_INFO_CLASS UMS_THREAD_INFO_CLASS, *PUMS_THREAD_INFO_CLASS;
+
WINBASEAPI BOOL WINAPI ActivateActCtx(HANDLE,ULONG_PTR *);
WINADVAPI BOOL WINAPI AddAccessAllowedAce(PACL,DWORD,DWORD,PSID);
WINADVAPI BOOL WINAPI AddAccessAllowedAceEx(PACL,DWORD,DWORD,DWORD,PSID);
@@ -1789,6 +1804,7 @@ WINADVAPI BOOL WINAPI CreateProcessAsUserW(HANDLE,LPCWSTR,LPWSTR,LPSECUR
#define CreateProcessAsUser WINELIB_NAME_AW(CreateProcessAsUser)
WINADVAPI BOOL WINAPI CreateProcessWithLogonW(LPCWSTR,LPCWSTR,LPCWSTR,DWORD,LPCWSTR,LPWSTR,DWORD,LPVOID,LPCWSTR,LPSTARTUPINFOW,LPPROCESS_INFORMATION);
WINBASEAPI HANDLE WINAPI CreateRemoteThread(HANDLE,LPSECURITY_ATTRIBUTES,SIZE_T,LPTHREAD_START_ROUTINE,LPVOID,DWORD,LPDWORD);
+WINBASEAPI HANDLE WINAPI CreateRemoteThreadEx(HANDLE,LPSECURITY_ATTRIBUTES,SIZE_T,LPTHREAD_START_ROUTINE,LPVOID,DWORD,LPPROC_THREAD_ATTRIBUTE_LIST,LPDWORD);
WINADVAPI BOOL WINAPI CreateRestrictedToken(HANDLE,DWORD,DWORD,PSID_AND_ATTRIBUTES,DWORD,PLUID_AND_ATTRIBUTES,DWORD,PSID_AND_ATTRIBUTES,PHANDLE);
WINBASEAPI HANDLE WINAPI CreateSemaphoreA(LPSECURITY_ATTRIBUTES,LONG,LONG,LPCSTR);
WINBASEAPI HANDLE WINAPI CreateSemaphoreW(LPSECURITY_ATTRIBUTES,LONG,LONG,LPCWSTR);
@@ -1806,6 +1822,8 @@ WINBASEAPI DWORD WINAPI CreateTapePartition(HANDLE,DWORD,DWORD,DWORD);
WINBASEAPI HANDLE WINAPI CreateThread(LPSECURITY_ATTRIBUTES,SIZE_T,LPTHREAD_START_ROUTINE,LPVOID,DWORD,LPDWORD);
WINBASEAPI HANDLE WINAPI CreateTimerQueue(void);
WINBASEAPI BOOL WINAPI CreateTimerQueueTimer(PHANDLE,HANDLE,WAITORTIMERCALLBACK,PVOID,DWORD,DWORD,ULONG);
+WINBASEAPI BOOL WINAPI CreateUmsCompletionList(PUMS_COMPLETION_LIST*);
+WINBASEAPI BOOL WINAPI CreateUmsThreadContext(PUMS_CONTEXT*);
WINBASEAPI HANDLE WINAPI CreateWaitableTimerA(LPSECURITY_ATTRIBUTES,BOOL,LPCSTR);
WINBASEAPI HANDLE WINAPI CreateWaitableTimerW(LPSECURITY_ATTRIBUTES,BOOL,LPCWSTR);
#define CreateWaitableTimer WINELIB_NAME_AW(CreateWaitableTimer)
@@ -1861,6 +1879,7 @@ WINBASEAPI BOOL WINAPI EndUpdateResourceA(HANDLE,BOOL);
WINBASEAPI BOOL WINAPI EndUpdateResourceW(HANDLE,BOOL);
#define EndUpdateResource WINELIB_NAME_AW(EndUpdateResource)
WINBASEAPI void WINAPI EnterCriticalSection(CRITICAL_SECTION *lpCrit);
+WINBASEAPI BOOL WINAPI EnterUmsSchedulingMode(PUMS_SCHEDULER_STARTUP_INFO);
WINBASEAPI BOOL WINAPI EnumResourceLanguagesA(HMODULE,LPCSTR,LPCSTR,ENUMRESLANGPROCA,LONG_PTR);
WINBASEAPI BOOL WINAPI EnumResourceLanguagesW(HMODULE,LPCWSTR,LPCWSTR,ENUMRESLANGPROCW,LONG_PTR);
#define EnumResourceLanguages WINELIB_NAME_AW(EnumResourceLanguages)
diff --git a/include/winnt.h b/include/winnt.h
index 72c399b..5f7f7fe 100644
--- a/include/winnt.h
+++ b/include/winnt.h
@@ -6008,9 +6008,29 @@ typedef VOID (CALLBACK *PTP_TIMER_CALLBACK)(PTP_CALLBACK_INSTANCE,PVOID,PTP_TIME
typedef VOID (CALLBACK *PTP_WAIT_CALLBACK)(PTP_CALLBACK_INSTANCE,PVOID,PTP_WAIT,TP_WAIT_RESULT);
typedef VOID (CALLBACK *PTP_WIN32_IO_CALLBACK)(PTP_CALLBACK_INSTANCE,PVOID,PVOID,ULONG,ULONG_PTR,PTP_IO);
-
NTSYSAPI BOOLEAN NTAPI RtlGetProductInfo(DWORD,DWORD,DWORD,DWORD,PDWORD);
+typedef enum _RTL_UMS_THREAD_INFO_CLASS
+{
+ UmsThreadInvalidInfoClass,
+ UmsThreadUserContext,
+ UmsThreadPriority,
+ UmsThreadAffinity,
+ UmsThreadTeb,
+ UmsThreadIsSuspended,
+ UmsThreadIsTerminated,
+ UmsThreadMaxInfoClass
+} RTL_UMS_THREAD_INFO_CLASS, *PRTL_UMS_THREAD_INFO_CLASS;
+
+typedef enum _RTL_UMS_SCHEDULER_REASON
+{
+ UmsSchedulerStartup,
+ UmsSchedulerThreadBlocked,
+ UmsSchedulerThreadYield,
+} RTL_UMS_SCHEDULER_REASON, *PRTL_UMS_SCHEDULER_REASON;
+
+typedef void (CALLBACK *PRTL_UMS_SCHEDULER_ENTRY_POINT)(RTL_UMS_SCHEDULER_REASON,ULONG_PTR,PVOID);
+
#ifdef __cplusplus
}
#endif
--
2.9.0