- Reorder some more driver exports to alphabetical order.
- Remove NtGdiFlushUserBatch and NtUserQueryUserCounters from syscall list (unused, and not compatible).
- Move and add some debug-only syscalls to the end of the syscall list.
- Fix parameter count of UserValidateTimerCallback, UserValidateHandleSecure, and UserChangeDisplaySettings to match what is compatible, by removing unused or ignored parameters. NtGdiOpenDCW, NtUserEnumDisplayMonitors and NtUserSetCursorIconData still have the wrong numbers.
- Add "stray" NtGdiMakeObjectXferable and "NtDxEngGetRedirectionBitmap" syscall stubs.
- The syscalls should now be compatible with 2K3 SP2 in their order, but not in their argument count (or, most likely, their actual parameters). This means a Windows 2k3 gdi32 or user32 should crash somewhat later now that half of the syscalls' order is not in disarray.

svn path=/trunk/; revision=69147
This commit is contained in:
Stefan Ginsberg 2015-09-09 13:49:39 +00:00
parent c30c8ddb99
commit edd85f8e32
13 changed files with 134 additions and 62 deletions

View file

@ -1764,14 +1764,6 @@ APIENTRY
NtGdiFlattenPath(
_In_ HDC hdc);
/* Not in MS ntgdi.h */
__kernel_entry
W32KAPI
NTSTATUS
APIENTRY
NtGdiFlushUserBatch(
VOID);
__kernel_entry
W32KAPI
HRGN

View file

@ -94,6 +94,16 @@ IntGetSysColor(INT nIndex);
/* Other Stuff */
NTSTATUS
APIENTRY
NtGdiFlushUserBatch(
VOID);
DWORD
APIENTRY
NtDxEngGetRedirectionBitmap(
DWORD Unknown0);
HBITMAP
FASTCALL
IntCreateCompatibleBitmap(

View file

@ -1218,6 +1218,18 @@ NtUserCtxDisplayIOCtl(
DWORD dwUnknown1,
DWORD dwUnknown2,
DWORD dwUnknown3);
DWORD
APIENTRY
NtUserDbgWin32HeapFail(
DWORD Unknown0,
DWORD Unknown1);
DWORD
APIENTRY
NtUserDbgWin32HeapStat(
DWORD Unknown0,
DWORD Unknown1);
BOOL
NTAPI
@ -1685,8 +1697,7 @@ NtUserChangeDisplaySettings(
PUNICODE_STRING lpszDeviceName,
LPDEVMODEW lpDevMode,
HWND hwnd,
DWORD dwflags,
LPVOID lParam);
DWORD dwflags);
BOOL
NTAPI
@ -3026,6 +3037,11 @@ NTAPI
NtUserSetDbgTag(
DWORD Unknown0,
DWORD Unknown1);
DWORD
APIENTRY
NtUserSetDbgTagCount(
DWORD Unknown0);
HWND
NTAPI
@ -3123,8 +3139,7 @@ NtUserSetProp(
DWORD
NTAPI
NtUserSetRipFlags(
DWORD Unknown0,
DWORD Unknown1);
DWORD Unknown0);
DWORD
NTAPI
@ -3430,8 +3445,7 @@ NtUserUserHandleGrantAccess(
BOOL
NTAPI
NtUserValidateHandleSecure(
HANDLE hHdl,
BOOL Restricted);
HANDLE hHdl);
BOOL
NTAPI
@ -3442,8 +3456,6 @@ NtUserValidateRect(
BOOL
APIENTRY
NtUserValidateTimerCallback(
HWND hWnd,
WPARAM wParam,
LPARAM lParam);
DWORD

View file

@ -816,8 +816,7 @@ NtUserChangeDisplaySettings(
PUNICODE_STRING pustrDevice,
LPDEVMODEW lpDevMode,
HWND hwnd,
DWORD dwflags,
LPVOID lParam)
DWORD dwflags)
{
WCHAR awcDevice[CCHDEVICENAME];
UNICODE_STRING ustrDevice;
@ -825,7 +824,7 @@ NtUserChangeDisplaySettings(
LONG lRet;
/* Check arguments */
if ((dwflags != CDS_VIDEOPARAMETERS && lParam != NULL) ||
if ((dwflags != CDS_VIDEOPARAMETERS) ||
(hwnd != NULL))
{
EngSetLastError(ERROR_INVALID_PARAMETER);

View file

@ -888,7 +888,7 @@ DriverUnload(IN PDRIVER_OBJECT DriverObject)
/*
* This definition doesn't work
*/
INIT_FUNCTION
INIT_SECTION
NTSTATUS
APIENTRY
DriverEntry(
@ -942,7 +942,7 @@ DriverEntry(
PsEstablishWin32Callouts(&CalloutData);
/* Register service hook callbacks */
#if DBG
#if DBG && defined(KDBG)
KdSystemDebugControl('CsoR', DbgPreServiceHook, ID_Win32PreServiceHook, 0, 0, 0, 0);
KdSystemDebugControl('CsoR', DbgPostServiceHook, ID_Win32PostServiceHook, 0, 0, 0, 0);
#endif

View file

@ -269,6 +269,37 @@ APIENTRY
NtUserSetDbgTag(
DWORD Unknown0,
DWORD Unknown1)
{
STUB;
return 0;
}
DWORD
APIENTRY
NtUserSetDbgTagCount(
DWORD Unknown0)
{
STUB;
return 0;
}
DWORD
APIENTRY
NtUserSetRipFlags(
DWORD Unknown0)
{
STUB;
return 0;
}
DWORD
APIENTRY
NtUserDbgWin32HeapFail(
DWORD Unknown0,
DWORD Unknown1)
{
STUB
@ -277,9 +308,9 @@ NtUserSetDbgTag(
DWORD
APIENTRY
NtUserSetRipFlags(
DWORD Unknown0,
DWORD Unknown1)
NtUserDbgWin32HeapStat(
DWORD Unknown0,
DWORD Unknown1)
{
STUB
@ -1030,4 +1061,25 @@ BOOL APIENTRY NtUserGetUpdatedClipboardFormats(
return FALSE;
}
// Yes, I know, these do not belong here, just tell me where to put them
BOOL
APIENTRY
NtGdiMakeObjectXferable(
_In_ HANDLE hHandle,
_In_ DWORD dwProcessId)
{
STUB;
return 0;
}
DWORD
APIENTRY
NtDxEngGetRedirectionBitmap(
DWORD Unknown0)
{
STUB;
return 0;
}
/* EOF */

View file

@ -726,7 +726,6 @@ UserDestroyObjectsForOwner(PUSER_HANDLE_TABLE Table, PVOID Owner)
}
/*
* NtUserValidateHandleSecure W2k3 has one argument.
*
* Status
* @implemented
@ -735,8 +734,7 @@ UserDestroyObjectsForOwner(PUSER_HANDLE_TABLE Table, PVOID Owner)
BOOL
APIENTRY
NtUserValidateHandleSecure(
HANDLE handle,
BOOL Restricted)
HANDLE handle)
{
UINT uType;
PPROCESSINFO ppi;

View file

@ -696,8 +696,6 @@ CLEANUP:
BOOL
APIENTRY
NtUserValidateTimerCallback(
HWND hWnd,
WPARAM wParam,
LPARAM lParam)
{
BOOL Ret = FALSE;

View file

@ -457,14 +457,14 @@ ChangeDisplaySettingsExA(
pDevModeW = GdiConvertToDevmodeW(lpDevMode);
if(pDevModeW)
{
rc = NtUserChangeDisplaySettings(pDeviceName, pDevModeW, hwnd, dwflags, lParam);
rc = NtUserChangeDisplaySettings(pDeviceName, pDevModeW, hwnd, dwflags);
RtlFreeHeap(GetProcessHeap(), 0, pDevModeW);
}
else
rc = DISP_CHANGE_SUCCESSFUL;
}
else
rc = NtUserChangeDisplaySettings(pDeviceName, NULL, hwnd, dwflags, lParam);
rc = NtUserChangeDisplaySettings(pDeviceName, NULL, hwnd, dwflags);
if (lpszDeviceName != NULL)
RtlFreeUnicodeString(&DeviceName);
@ -509,7 +509,7 @@ ChangeDisplaySettingsExW(
else
pDeviceName = NULL;
rc = NtUserChangeDisplaySettings(pDeviceName, lpDevMode, hwnd, dwflags, lParam);
rc = NtUserChangeDisplaySettings(pDeviceName, lpDevMode, hwnd, dwflags);
return rc;
}

View file

@ -1876,7 +1876,7 @@ DispatchMessageA(CONST MSG *lpmsg)
if ( lpmsg->message == WM_SYSTIMER )
return NtUserDispatchMessage( (PMSG)lpmsg );
if (!NtUserValidateTimerCallback(lpmsg->hwnd, lpmsg->wParam, lpmsg->lParam))
if (!NtUserValidateTimerCallback(lpmsg->lParam))
{
WARN("Validating Timer Callback failed!\n");
return 0;
@ -1969,7 +1969,7 @@ DispatchMessageW(CONST MSG *lpmsg)
if ( lpmsg->message == WM_SYSTIMER )
return NtUserDispatchMessage( (PMSG) lpmsg );
if (!NtUserValidateTimerCallback(lpmsg->hwnd, lpmsg->wParam, lpmsg->lParam))
if (!NtUserValidateTimerCallback(lpmsg->lParam))
{
WARN("Validating Timer Callback failed!\n");
return 0;

View file

@ -152,7 +152,6 @@ NtGdiExtTextOutW 9
NtGdiFillPath 1
NtGdiFillRgn 3
NtGdiFlattenPath 1
NtGdiFlushUserBatch 0
NtGdiFlush 0
NtGdiForceUFIMapping 2
NtGdiFrameRgn 5
@ -235,7 +234,7 @@ NtGdiMonoBitmap 1
NtGdiMoveTo 4
NtGdiOffsetClipRgn 3
NtGdiOffsetRgn 3
NtGdiOpenDCW 8
NtGdiOpenDCW 8 #7
NtGdiPatBlt 6
NtGdiPolyPatBlt 5
NtGdiPathToRegion 1
@ -328,7 +327,7 @@ NtUserCallNoParam 1
NtUserCallOneParam 2
NtUserCallTwoParam 3
NtUserChangeClipboardChain 2
NtUserChangeDisplaySettings 5
NtUserChangeDisplaySettings 5 #4
NtUserCheckImeHotKey 2
NtUserCheckMenuItem 3
NtUserChildWindowFromPointEx 4
@ -374,14 +373,12 @@ NtUserEndDeferWindowPosEx 2
NtUserEndMenu 0
NtUserEndPaint 2
NtUserEnumDisplayDevices 4
# NtUserEnumDisplayMonitors 4 Wrong number of param ?
NtUserEnumDisplayMonitors 5
NtUserEnumDisplayMonitors 5 #4
NtUserEnumDisplaySettings 4
NtUserEvent 1
NtUserExcludeUpdateRgn 2
NtUserFillWindow 4
# NtUserFindExistingCursorIcon 3 Wrong number of param ?
NtUserFindExistingCursorIcon 4
NtUserFindExistingCursorIcon 3
NtUserFindWindowEx 5
NtUserFlashWindowEx 1
NtUserGetAltTabInfo 6
@ -391,7 +388,7 @@ NtUserGetAsyncKeyState 1
NtUserGetAtomName 2
NtUserGetCaretBlinkTime 0
NtUserGetCaretPos 1
NtUserGetClassInfo 5
NtUserGetClassInfo 5 #Ex?
NtUserGetClassName 3
NtUserGetClipboardData 2
NtUserGetClipboardFormatName 3
@ -486,7 +483,6 @@ NtUserProcessConnect 3
NtUserQueryInformationThread 4
NtUserQueryInputContext 2
NtUserQuerySendMessage 1
NtUserQueryUserCounters 5
NtUserQueryWindow 2
NtUserRealChildWindowFromPoint 3
NtUserRealInternalGetMessage 6
@ -518,7 +514,6 @@ NtUserSetConsoleReserveKeys 2
NtUserSetCursor 1
NtUserSetCursorContents 2
NtUserSetCursorIconData 6 #4
NtUserSetDbgTag 2
NtUserSetFocus 1
NtUserSetImeHotKey 5
NtUserSetImeInfoEx 1
@ -536,7 +531,6 @@ NtUserSetObjectInformation 4
NtUserSetParent 2
NtUserSetProcessWindowStation 1
NtUserSetProp 3
NtUserSetRipFlags 2
NtUserSetScrollInfo 4
NtUserSetShellWindowEx 2
NtUserSetSysColors 4
@ -588,9 +582,9 @@ NtUserGetLayeredWindowAttributes 4
NtUserSetLayeredWindowAttributes 4
NtUserUpdatePerUserSystemParameters 2
NtUserUserHandleGrantAccess 3
NtUserValidateHandleSecure 2
NtUserValidateHandleSecure 1
NtUserValidateRect 2
NtUserValidateTimerCallback 3
NtUserValidateTimerCallback 1
NtUserVkKeyScanEx 3
NtUserWaitForInputIdle 3
NtUserWaitForMsgAndEvent 1
@ -671,8 +665,18 @@ NtGdiSetPUMPDOBJ 4
NtGdiBRUSHOBJ_DeleteRbrush 2
NtGdiUMPDEngFreeUserMem 1
NtGdiDrawStream 3
#
#
# Checked build only
NtUserDbgWin32HeapFail 2
NtUserDbgWin32HeapStat 2
NtUserSetDbgTag 2
NtUserSetDbgTagCount 1
NtUserSetRipFlags 2
# Stray Syscalls
NtGdiMakeObjectXferable 2
DxEngGetRedirectionBitmap 1
#ReactOS specific syscalls
NtGdiSetViewportOrgEx 4
NtGdiSetWindowOrgEx 4
@ -685,3 +689,4 @@ NtUserMonitorFromPoint 3
NtUserMonitorFromRect 2
NtUserMonitorFromWindow 2
NtUserSetScrollBarInfo 3
#

View file

@ -153,7 +153,6 @@
SVC_(GdiFillPath, 1)
SVC_(GdiFillRgn, 3)
SVC_(GdiFlattenPath, 1)
SVC_(GdiFlushUserBatch, 0)
SVC_(GdiFlush, 0)
SVC_(GdiForceUFIMapping, 2)
SVC_(GdiFrameRgn, 5)
@ -329,7 +328,7 @@
SVC_(UserCallOneParam, 2)
SVC_(UserCallTwoParam, 3)
SVC_(UserChangeClipboardChain, 2)
SVC_(UserChangeDisplaySettings, 5)
SVC_(UserChangeDisplaySettings, 4)
SVC_(UserCheckImeHotKey, 2)
SVC_(UserCheckMenuItem, 3)
SVC_(UserChildWindowFromPointEx, 4)
@ -485,7 +484,6 @@
SVC_(UserQueryInformationThread, 4)
SVC_(UserQueryInputContext, 2)
SVC_(UserQuerySendMessage, 1)
SVC_(UserQueryUserCounters, 5)
SVC_(UserQueryWindow, 2)
SVC_(UserRealChildWindowFromPoint, 3)
SVC_(UserRealInternalGetMessage, 6)
@ -517,7 +515,6 @@
SVC_(UserSetCursor, 1)
SVC_(UserSetCursorContents, 2)
SVC_(UserSetCursorIconData, 4)
SVC_(UserSetDbgTag, 2)
SVC_(UserSetFocus, 1)
SVC_(UserSetImeHotKey, 5)
SVC_(UserSetImeInfoEx, 1)
@ -535,7 +532,6 @@
SVC_(UserSetParent, 2)
SVC_(UserSetProcessWindowStation, 1)
SVC_(UserSetProp, 3)
SVC_(UserSetRipFlags, 2)
SVC_(UserSetScrollInfo, 4)
SVC_(UserSetShellWindowEx, 2)
SVC_(UserSetSysColors, 4)
@ -587,9 +583,9 @@
SVC_(UserSetLayeredWindowAttributes, 4)
SVC_(UserUpdatePerUserSystemParameters, 2)
SVC_(UserUserHandleGrantAccess, 3)
SVC_(UserValidateHandleSecure, 2)
SVC_(UserValidateHandleSecure, 1)
SVC_(UserValidateRect, 2)
SVC_(UserValidateTimerCallback, 3)
SVC_(UserValidateTimerCallback, 1)
SVC_(UserVkKeyScanEx, 3)
SVC_(UserWaitForInputIdle, 3)
SVC_(UserWaitForMsgAndEvent, 1)
@ -670,9 +666,19 @@
SVC_(GdiBRUSHOBJ_DeleteRbrush, 2)
SVC_(GdiUMPDEngFreeUserMem, 1)
SVC_(GdiDrawStream, 3)
#if DBG
// Checked Build only
SVC_(UserDbgWin32HeapFail, 2)
SVC_(UserDbgWin32HeapStat, 2)
SVC_(UserSetDbgTag, 2)
SVC_(UserSetDbgTagCount, 1)
SVC_(UserSetRipFlags, 1)
#endif //DBG
//Stray syscalls
SVC_(GdiMakeObjectXferable, 2)
SVC_(DxEngGetRedirectionBitmap, 1)
// ReactOS, specific, syscalls)
// ReactOS-specific syscalls)
SVC_(GdiSetViewportOrgEx, 4)
SVC_(GdiSetWindowOrgEx, 4)
SVC_(GdiGetFontFamilyInfo, 4)

View file

@ -1,7 +1,3 @@
@ stdcall -arch=i386 FLOATOBJ_AddFloatObj(ptr ptr) FLOATOBJ_Add
@ stdcall -arch=i386 FLOATOBJ_DivFloatObj(ptr ptr) FLOATOBJ_Div
@ stdcall -arch=i386 FLOATOBJ_MulFloatObj(ptr ptr) FLOATOBJ_Mul
@ stdcall -arch=i386 FLOATOBJ_SubFloatObj(ptr ptr) FLOATOBJ_Sub
@ stdcall BRUSHOBJ_hGetColorTransform(ptr)
@ stdcall BRUSHOBJ_pvAllocRbrush(ptr long)
@ stdcall BRUSHOBJ_pvGetRbrush(ptr)
@ -147,9 +143,11 @@
@ stdcall EngWritePrinter(ptr ptr long ptr)
@ stdcall -arch=i386 FLOATOBJ_Add(ptr ptr)
@ stdcall -arch=i386 FLOATOBJ_AddFloat(ptr long)
@ stdcall -arch=i386 FLOATOBJ_AddFloatObj(ptr ptr) FLOATOBJ_Add
@ stdcall -arch=i386 FLOATOBJ_AddLong(ptr long)
@ stdcall -arch=i386 FLOATOBJ_Div(ptr ptr)
@ stdcall -arch=i386 FLOATOBJ_DivFloat(ptr long)
@ stdcall -arch=i386 FLOATOBJ_DivFloatObj(ptr ptr) FLOATOBJ_Div
@ stdcall -arch=i386 FLOATOBJ_DivLong(ptr long)
@ stdcall -arch=i386 FLOATOBJ_Equal(ptr ptr)
@ stdcall -arch=i386 FLOATOBJ_EqualLong(ptr long)
@ -161,12 +159,14 @@
@ stdcall -arch=i386 FLOATOBJ_LessThanLong(ptr long)
@ stdcall -arch=i386 FLOATOBJ_Mul(ptr ptr)
@ stdcall -arch=i386 FLOATOBJ_MulFloat(ptr long)
@ stdcall -arch=i386 FLOATOBJ_MulFloatObj(ptr ptr) FLOATOBJ_Mul
@ stdcall -arch=i386 FLOATOBJ_MulLong(ptr long)
@ stdcall -arch=i386 FLOATOBJ_Neg(ptr)
@ stdcall -arch=i386 FLOATOBJ_SetFloat(ptr long)
@ stdcall -arch=i386 FLOATOBJ_SetLong(ptr long)
@ stdcall -arch=i386 FLOATOBJ_Sub(ptr ptr)
@ stdcall -arch=i386 FLOATOBJ_SubFloat(ptr long)
@ stdcall -arch=i386 FLOATOBJ_SubFloatObj(ptr ptr) FLOATOBJ_Sub
@ stdcall -arch=i386 FLOATOBJ_SubLong(ptr long)
@ stdcall FONTOBJ_cGetAllGlyphHandles(ptr ptr)
@ stdcall FONTOBJ_cGetGlyphs(ptr long long ptr ptr)