Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
c5f66fc7
Commit
c5f66fc7
authored
Jul 16, 2020
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ntdll: Use syscall thunks for I/O completion functions.
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
eb45a75a
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
13 additions
and
91 deletions
+13
-91
ntdll.spec
dlls/ntdll/ntdll.spec
+12
-12
sync.c
dlls/ntdll/sync.c
+0
-59
loader.c
dlls/ntdll/unix/loader.c
+0
-6
unixlib.h
dlls/ntdll/unixlib.h
+1
-14
No files found.
dlls/ntdll/ntdll.spec
View file @
c5f66fc7
...
...
@@ -163,7 +163,7 @@
@ stdcall -syscall NtCreateEvent(ptr long ptr long long)
@ stub NtCreateEventPair
@ stdcall -syscall NtCreateFile(ptr long ptr ptr ptr long long long long ptr long)
@ stdcall NtCreateIoCompletion(ptr long ptr long)
@ stdcall
-syscall
NtCreateIoCompletion(ptr long ptr long)
@ stdcall -syscall NtCreateJobObject(ptr long ptr)
# @ stub NtCreateJobSet
@ stdcall NtCreateKey(ptr long ptr long ptr long ptr)
...
...
@@ -254,7 +254,7 @@
@ stdcall -syscall NtOpenEvent(ptr long ptr)
@ stub NtOpenEventPair
@ stdcall -syscall NtOpenFile(ptr long ptr ptr long long)
@ stdcall NtOpenIoCompletion(ptr long ptr)
@ stdcall
-syscall
NtOpenIoCompletion(ptr long ptr)
@ stdcall -syscall NtOpenJobObject(ptr long ptr)
@ stdcall NtOpenKey(ptr long ptr)
@ stdcall NtOpenKeyEx(ptr long ptr long)
...
...
@@ -300,7 +300,7 @@
@ stdcall NtQueryInformationToken(long long ptr long ptr)
@ stdcall NtQueryInstallUILanguage(ptr)
@ stub NtQueryIntervalProfile
@ stdcall NtQueryIoCompletion(long long ptr long ptr)
@ stdcall
-syscall
NtQueryIoCompletion(long long ptr long ptr)
@ stdcall NtQueryKey (long long ptr long ptr)
@ stdcall NtQueryLicenseValue(ptr ptr ptr long ptr)
@ stdcall NtQueryMultipleValueKey(long ptr long ptr long ptr)
...
...
@@ -337,8 +337,8 @@
@ stdcall -syscall NtReleaseMutant(long ptr)
@ stub NtReleaseProcessMutant
@ stdcall -syscall NtReleaseSemaphore(long long ptr)
@ stdcall NtRemoveIoCompletion(ptr ptr ptr ptr ptr)
@ stdcall NtRemoveIoCompletionEx(ptr ptr long ptr ptr long)
@ stdcall
-syscall
NtRemoveIoCompletion(ptr ptr ptr ptr ptr)
@ stdcall
-syscall
NtRemoveIoCompletionEx(ptr ptr long ptr ptr long)
# @ stub NtRemoveProcessDebug
@ stdcall NtRenameKey(long ptr)
@ stdcall NtReplaceKey(ptr long ptr)
...
...
@@ -381,7 +381,7 @@
@ stdcall NtSetInformationThread(long long ptr long)
@ stdcall NtSetInformationToken(long long ptr long)
@ stdcall NtSetIntervalProfile(long long)
@ stdcall NtSetIoCompletion(ptr long long long long)
@ stdcall
-syscall
NtSetIoCompletion(ptr long long long long)
@ stdcall NtSetLdtEntries(long int64 long int64)
@ stub NtSetLowEventPair
@ stub NtSetLowWaitHighEventPair
...
...
@@ -1152,7 +1152,7 @@
@ stdcall -private -syscall ZwCreateEvent(ptr long ptr long long) NtCreateEvent
@ stub ZwCreateEventPair
@ stdcall -private -syscall ZwCreateFile(ptr long ptr ptr ptr long long long long ptr long) NtCreateFile
@ stdcall -private ZwCreateIoCompletion(ptr long ptr long) NtCreateIoCompletion
@ stdcall -private
-syscall
ZwCreateIoCompletion(ptr long ptr long) NtCreateIoCompletion
@ stdcall -private -syscall ZwCreateJobObject(ptr long ptr) NtCreateJobObject
# @ stub ZwCreateJobSet
@ stdcall -private ZwCreateKey(ptr long ptr long ptr long ptr) NtCreateKey
...
...
@@ -1238,7 +1238,7 @@
@ stdcall -private -syscall ZwOpenEvent(ptr long ptr) NtOpenEvent
@ stub ZwOpenEventPair
@ stdcall -private -syscall ZwOpenFile(ptr long ptr ptr long long) NtOpenFile
@ stdcall -private ZwOpenIoCompletion(ptr long ptr) NtOpenIoCompletion
@ stdcall -private
-syscall
ZwOpenIoCompletion(ptr long ptr) NtOpenIoCompletion
@ stdcall -private -syscall ZwOpenJobObject(ptr long ptr) NtOpenJobObject
@ stdcall -private ZwOpenKey(ptr long ptr) NtOpenKey
@ stdcall -private ZwOpenKeyEx(ptr long ptr long) NtOpenKeyEx
...
...
@@ -1284,7 +1284,7 @@
@ stdcall -private ZwQueryInformationToken(long long ptr long ptr) NtQueryInformationToken
@ stdcall -private ZwQueryInstallUILanguage(ptr) NtQueryInstallUILanguage
@ stub ZwQueryIntervalProfile
@ stdcall -private ZwQueryIoCompletion(long long ptr long ptr) NtQueryIoCompletion
@ stdcall -private
-syscall
ZwQueryIoCompletion(long long ptr long ptr) NtQueryIoCompletion
@ stdcall -private ZwQueryKey(long long ptr long ptr) NtQueryKey
@ stdcall -private ZwQueryLicenseValue(ptr ptr ptr long ptr) NtQueryLicenseValue
@ stdcall -private ZwQueryMultipleValueKey(long ptr long ptr long ptr) NtQueryMultipleValueKey
...
...
@@ -1321,8 +1321,8 @@
@ stdcall -private -syscall ZwReleaseMutant(long ptr) NtReleaseMutant
@ stub ZwReleaseProcessMutant
@ stdcall -private -syscall ZwReleaseSemaphore(long long ptr) NtReleaseSemaphore
@ stdcall -private ZwRemoveIoCompletion(ptr ptr ptr ptr ptr) NtRemoveIoCompletion
@ stdcall -private ZwRemoveIoCompletionEx(ptr ptr long ptr ptr long) NtRemoveIoCompletionEx
@ stdcall -private
-syscall
ZwRemoveIoCompletion(ptr ptr ptr ptr ptr) NtRemoveIoCompletion
@ stdcall -private
-syscall
ZwRemoveIoCompletionEx(ptr ptr long ptr ptr long) NtRemoveIoCompletionEx
# @ stub ZwRemoveProcessDebug
@ stdcall -private ZwRenameKey(long ptr) NtRenameKey
@ stdcall -private ZwReplaceKey(ptr long ptr) NtReplaceKey
...
...
@@ -1365,7 +1365,7 @@
@ stdcall -private ZwSetInformationThread(long long ptr long) NtSetInformationThread
@ stdcall -private ZwSetInformationToken(long long ptr long) NtSetInformationToken
@ stdcall -private ZwSetIntervalProfile(long long) NtSetIntervalProfile
@ stdcall -private ZwSetIoCompletion(ptr long long long long) NtSetIoCompletion
@ stdcall -private
-syscall
ZwSetIoCompletion(ptr long long long long) NtSetIoCompletion
@ stdcall -private ZwSetLdtEntries(long int64 long int64) NtSetLdtEntries
@ stub ZwSetLowEventPair
@ stub ZwSetLowWaitHighEventPair
...
...
dlls/ntdll/sync.c
View file @
c5f66fc7
...
...
@@ -168,65 +168,6 @@ NTSTATUS WINAPI NtSetTimerResolution(IN ULONG resolution,
/******************************************************************
* NtCreateIoCompletion (NTDLL.@)
* ZwCreateIoCompletion (NTDLL.@)
*/
NTSTATUS
WINAPI
NtCreateIoCompletion
(
HANDLE
*
handle
,
ACCESS_MASK
access
,
OBJECT_ATTRIBUTES
*
attr
,
ULONG
threads
)
{
return
unix_funcs
->
NtCreateIoCompletion
(
handle
,
access
,
attr
,
threads
);
}
/******************************************************************
* NtSetIoCompletion (NTDLL.@)
* ZwSetIoCompletion (NTDLL.@)
*/
NTSTATUS
WINAPI
NtSetIoCompletion
(
HANDLE
handle
,
ULONG_PTR
key
,
ULONG_PTR
value
,
NTSTATUS
status
,
SIZE_T
count
)
{
return
unix_funcs
->
NtSetIoCompletion
(
handle
,
key
,
value
,
status
,
count
);
}
/******************************************************************
* NtRemoveIoCompletion (NTDLL.@)
* ZwRemoveIoCompletion (NTDLL.@)
*/
NTSTATUS
WINAPI
NtRemoveIoCompletion
(
HANDLE
handle
,
ULONG_PTR
*
key
,
ULONG_PTR
*
value
,
IO_STATUS_BLOCK
*
io
,
LARGE_INTEGER
*
timeout
)
{
return
unix_funcs
->
NtRemoveIoCompletion
(
handle
,
key
,
value
,
io
,
timeout
);
}
/******************************************************************
* NtRemoveIoCompletionEx (NTDLL.@)
* ZwRemoveIoCompletionEx (NTDLL.@)
*/
NTSTATUS
WINAPI
NtRemoveIoCompletionEx
(
HANDLE
port
,
FILE_IO_COMPLETION_INFORMATION
*
info
,
ULONG
count
,
ULONG
*
written
,
LARGE_INTEGER
*
timeout
,
BOOLEAN
alertable
)
{
return
unix_funcs
->
NtRemoveIoCompletionEx
(
port
,
info
,
count
,
written
,
timeout
,
alertable
);
}
/******************************************************************
* NtOpenIoCompletion (NTDLL.@)
* ZwOpenIoCompletion (NTDLL.@)
*/
NTSTATUS
WINAPI
NtOpenIoCompletion
(
HANDLE
*
handle
,
ACCESS_MASK
access
,
const
OBJECT_ATTRIBUTES
*
attr
)
{
return
unix_funcs
->
NtOpenIoCompletion
(
handle
,
access
,
attr
);
}
/******************************************************************
* NtQueryIoCompletion (NTDLL.@)
* ZwQueryIoCompletion (NTDLL.@)
*/
NTSTATUS
WINAPI
NtQueryIoCompletion
(
HANDLE
handle
,
IO_COMPLETION_INFORMATION_CLASS
class
,
void
*
buffer
,
ULONG
len
,
ULONG
*
ret_len
)
{
return
unix_funcs
->
NtQueryIoCompletion
(
handle
,
class
,
buffer
,
len
,
ret_len
);
}
/******************************************************************
* RtlRunOnceInitialize (NTDLL.@)
*/
void
WINAPI
RtlRunOnceInitialize
(
RTL_RUN_ONCE
*
once
)
...
...
dlls/ntdll/unix/loader.c
View file @
c5f66fc7
...
...
@@ -1364,7 +1364,6 @@ static struct unix_funcs unix_funcs =
NtAreMappedFilesTheSame
,
NtClose
,
NtContinue
,
NtCreateIoCompletion
,
NtCreateMailslotFile
,
NtCreateNamedPipeFile
,
NtCreateSection
,
...
...
@@ -1386,7 +1385,6 @@ static struct unix_funcs unix_funcs =
NtLockVirtualMemory
,
NtMapViewOfSection
,
NtNotifyChangeDirectoryFile
,
NtOpenIoCompletion
,
NtOpenProcess
,
NtOpenSection
,
NtOpenThread
,
...
...
@@ -1398,7 +1396,6 @@ static struct unix_funcs unix_funcs =
NtQueryInformationFile
,
NtQueryInformationProcess
,
NtQueryInformationThread
,
NtQueryIoCompletion
,
NtQueryObject
,
NtQueryPerformanceCounter
,
NtQuerySection
,
...
...
@@ -1412,8 +1409,6 @@ static struct unix_funcs unix_funcs =
NtReadFile
,
NtReadFileScatter
,
NtReadVirtualMemory
,
NtRemoveIoCompletion
,
NtRemoveIoCompletionEx
,
NtResetWriteWatch
,
NtResumeProcess
,
NtResumeThread
,
...
...
@@ -1422,7 +1417,6 @@ static struct unix_funcs unix_funcs =
NtSetInformationObject
,
NtSetInformationProcess
,
NtSetInformationThread
,
NtSetIoCompletion
,
NtSetLdtEntries
,
NtSetSystemTime
,
NtSetVolumeInformationFile
,
...
...
dlls/ntdll/unixlib.h
View file @
c5f66fc7
...
...
@@ -28,7 +28,7 @@ struct msghdr;
struct
_DISPATCHER_CONTEXT
;
/* increment this when you change the function table */
#define NTDLL_UNIXLIB_VERSION 8
1
#define NTDLL_UNIXLIB_VERSION 8
2
struct
unix_funcs
{
...
...
@@ -40,8 +40,6 @@ struct unix_funcs
NTSTATUS
(
WINAPI
*
NtAreMappedFilesTheSame
)(
PVOID
addr1
,
PVOID
addr2
);
NTSTATUS
(
WINAPI
*
NtClose
)(
HANDLE
handle
);
NTSTATUS
(
WINAPI
*
NtContinue
)(
CONTEXT
*
context
,
BOOLEAN
alertable
);
NTSTATUS
(
WINAPI
*
NtCreateIoCompletion
)(
HANDLE
*
handle
,
ACCESS_MASK
access
,
OBJECT_ATTRIBUTES
*
attr
,
ULONG
threads
);
NTSTATUS
(
WINAPI
*
NtCreateMailslotFile
)(
HANDLE
*
handle
,
ULONG
access
,
OBJECT_ATTRIBUTES
*
attr
,
IO_STATUS_BLOCK
*
io
,
ULONG
options
,
ULONG
quota
,
ULONG
msg_size
,
LARGE_INTEGER
*
timeout
);
...
...
@@ -97,8 +95,6 @@ struct unix_funcs
void
*
apc_context
,
IO_STATUS_BLOCK
*
iosb
,
void
*
buffer
,
ULONG
buffer_size
,
ULONG
filter
,
BOOLEAN
subtree
);
NTSTATUS
(
WINAPI
*
NtOpenIoCompletion
)(
HANDLE
*
handle
,
ACCESS_MASK
access
,
const
OBJECT_ATTRIBUTES
*
attr
);
NTSTATUS
(
WINAPI
*
NtOpenProcess
)(
HANDLE
*
handle
,
ACCESS_MASK
access
,
const
OBJECT_ATTRIBUTES
*
attr
,
const
CLIENT_ID
*
id
);
NTSTATUS
(
WINAPI
*
NtOpenSection
)(
HANDLE
*
handle
,
ACCESS_MASK
access
,
...
...
@@ -123,8 +119,6 @@ struct unix_funcs
ULONG
size
,
ULONG
*
ret_len
);
NTSTATUS
(
WINAPI
*
NtQueryInformationThread
)(
HANDLE
handle
,
THREADINFOCLASS
class
,
void
*
data
,
ULONG
length
,
ULONG
*
ret_len
);
NTSTATUS
(
WINAPI
*
NtQueryIoCompletion
)(
HANDLE
handle
,
IO_COMPLETION_INFORMATION_CLASS
class
,
void
*
buffer
,
ULONG
len
,
ULONG
*
ret_len
);
NTSTATUS
(
WINAPI
*
NtQueryObject
)(
HANDLE
handle
,
OBJECT_INFORMATION_CLASS
info_class
,
void
*
ptr
,
ULONG
len
,
ULONG
*
used_len
);
NTSTATUS
(
WINAPI
*
NtQueryPerformanceCounter
)(
LARGE_INTEGER
*
counter
,
LARGE_INTEGER
*
frequency
);
...
...
@@ -154,11 +148,6 @@ struct unix_funcs
LARGE_INTEGER
*
offset
,
ULONG
*
key
);
NTSTATUS
(
WINAPI
*
NtReadVirtualMemory
)(
HANDLE
process
,
const
void
*
addr
,
void
*
buffer
,
SIZE_T
size
,
SIZE_T
*
bytes_read
);
NTSTATUS
(
WINAPI
*
NtRemoveIoCompletion
)(
HANDLE
handle
,
ULONG_PTR
*
key
,
ULONG_PTR
*
value
,
IO_STATUS_BLOCK
*
io
,
LARGE_INTEGER
*
timeout
);
NTSTATUS
(
WINAPI
*
NtRemoveIoCompletionEx
)(
HANDLE
handle
,
FILE_IO_COMPLETION_INFORMATION
*
info
,
ULONG
count
,
ULONG
*
written
,
LARGE_INTEGER
*
timeout
,
BOOLEAN
alertable
);
NTSTATUS
(
WINAPI
*
NtResetWriteWatch
)(
HANDLE
process
,
PVOID
base
,
SIZE_T
size
);
NTSTATUS
(
WINAPI
*
NtResumeProcess
)(
HANDLE
handle
);
NTSTATUS
(
WINAPI
*
NtResumeThread
)(
HANDLE
handle
,
ULONG
*
count
);
...
...
@@ -171,8 +160,6 @@ struct unix_funcs
void
*
info
,
ULONG
size
);
NTSTATUS
(
WINAPI
*
NtSetInformationThread
)(
HANDLE
handle
,
THREADINFOCLASS
class
,
const
void
*
data
,
ULONG
length
);
NTSTATUS
(
WINAPI
*
NtSetIoCompletion
)(
HANDLE
handle
,
ULONG_PTR
key
,
ULONG_PTR
value
,
NTSTATUS
status
,
SIZE_T
count
);
NTSTATUS
(
WINAPI
*
NtSetLdtEntries
)(
ULONG
sel1
,
LDT_ENTRY
entry1
,
ULONG
sel2
,
LDT_ENTRY
entry2
);
NTSTATUS
(
WINAPI
*
NtSetSystemTime
)(
const
LARGE_INTEGER
*
new
,
LARGE_INTEGER
*
old
);
NTSTATUS
(
WINAPI
*
NtSetVolumeInformationFile
)(
HANDLE
handle
,
IO_STATUS_BLOCK
*
io
,
void
*
info
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment