3 * Wine server protocol definition
5 * Copyright (C
) 2001 Alexandre Julliard
7 * This file is used by tools
/make_requests to build the
8 * protocol structures in include
/wine
/server_protocol.h
10 * This library is free software
; you can redistribute it and
/or
11 * modify it under the terms of the GNU Lesser General Public
12 * License as published by the Free Software Foundation
; either
13 * version
2.1 of the License
, or (at your option
) any later version.
15 * This library is distributed in the hope that it will be useful
,
16 * but WITHOUT ANY WARRANTY
; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS
FOR A PARTICULAR PURPOSE. See the GNU
18 * Lesser General Public License for more details.
20 * You should have received a copy of the GNU Lesser General Public
21 * License along with this library
; if not
, write to the Free Software
22 * Foundation
, Inc.
, 51 Franklin St
, Fifth Floor
, Boston
, MA
02110-1301, USA
25 @HEADER
/* start of C declarations
*/
34 typedef unsigned int obj_handle_t
;
35 typedef unsigned int user_handle_t
;
36 typedef unsigned int atom_t
;
37 typedef unsigned int process_id_t
;
38 typedef unsigned int thread_id_t
;
39 typedef unsigned int data_size_t
;
40 typedef unsigned int ioctl_code_t
;
41 typedef unsigned __int64 lparam_t
;
42 typedef unsigned __int64 apc_param_t
;
43 typedef unsigned __int64 mem_size_t
;
44 typedef unsigned __int64 file_pos_t
;
45 typedef unsigned __int64 client_ptr_t
;
46 typedef unsigned __int64 affinity_t
;
47 typedef client_ptr_t mod_handle_t
;
51 int req
; /* request code
*/
52 data_size_t request_size
; /* request variable part size
*/
53 data_size_t reply_size
; /* reply variable part maximum size
*/
58 unsigned int error
; /* error result
*/
59 data_size_t reply_size
; /* reply variable part size
*/
62 /* placeholder structure for the maximum allowed request size
*/
63 /* this is used to construct the generic_request union
*/
64 struct request_max_size
66 int pad
[16]; /* the max request size is
16 ints
*/
69 #define FIRST_USER_HANDLE
0x0020 /* first possible value for low word of user handle
*/
70 #define LAST_USER_HANDLE
0xffef /* last possible value for low word of user handle
*/
73 /* debug event data
*/
76 int code
; /* event code
*/
79 int code
; /* EXCEPTION_DEBUG_EVENT
*/
80 int first
; /* first chance exception?
*/
81 unsigned int exc_code
; /* exception code
*/
82 unsigned int flags
; /* exception flags
*/
83 client_ptr_t record
; /* exception record
*/
84 client_ptr_t address
; /* exception address
*/
85 int nb_params
; /* number of parameters
*/
87 client_ptr_t params
[15]; /* parameters
*/
91 int code
; /* CREATE_THREAD_DEBUG_EVENT
*/
92 obj_handle_t handle
; /* handle to the new thread
*/
93 client_ptr_t teb
; /* thread
teb (in debugged process address space
) */
94 client_ptr_t start
; /* thread startup routine
*/
98 int code
; /* CREATE_PROCESS_DEBUG_EVENT
*/
99 obj_handle_t file
; /* handle to the process exe file
*/
100 obj_handle_t process
; /* handle to the new process
*/
101 obj_handle_t thread
; /* handle to the new thread
*/
102 mod_handle_t base
; /* base of executable image
*/
103 int dbg_offset
; /* offset of debug info in file
*/
104 int dbg_size
; /* size of debug info
*/
105 client_ptr_t teb
; /* thread
teb (in debugged process address space
) */
106 client_ptr_t start
; /* thread startup routine
*/
107 client_ptr_t name
; /* image
name (optional
) */
108 int unicode
; /* is it Unicode?
*/
112 int code
; /* EXIT_THREAD_DEBUG_EVENT
/EXIT_PROCESS_DEBUG_EVENT
*/
113 int exit_code
; /* thread or process exit code
*/
117 int code
; /* LOAD_DLL_DEBUG_EVENT
*/
118 obj_handle_t handle
; /* file handle for the dll
*/
119 mod_handle_t base
; /* base address of the dll
*/
120 int dbg_offset
; /* offset of debug info in file
*/
121 int dbg_size
; /* size of debug info
*/
122 client_ptr_t name
; /* image
name (optional
) */
123 int unicode
; /* is it Unicode?
*/
127 int code
; /* UNLOAD_DLL_DEBUG_EVENT
*/
129 mod_handle_t base
; /* base address of the dll
*/
133 int code
; /* OUTPUT_DEBUG_STRING_EVENT
*/
134 int unicode
; /* is it Unicode?
*/
135 client_ptr_t string
; /* string to
display (in debugged process address space
) */
136 data_size_t length
; /* string length
*/
140 int code
; /* RIP_EVENT
*/
146 /* supported CPU types
*/
149 CPU_x86
, CPU_x86_64
, CPU_ALPHA
, CPU_POWERPC
, CPU_SPARC
151 typedef int cpu_type_t
;
156 cpu_type_t cpu
; /* cpu type
*/
157 unsigned int flags
; /* SERVER_CTX_
* flags
*/
160 struct
{ unsigned int eip
, ebp
, esp
, eflags
, cs
, ss
; } i386_regs
;
161 struct
{ unsigned __int64 rip
, rbp
, rsp
;
162 unsigned int cs
, ss
, flags
; } x86_64_regs
;
163 struct
{ unsigned __int64 fir
;
164 unsigned int psr
; } alpha_regs
;
165 struct
{ unsigned int iar
, msr
, ctr
, lr
, dar
, dsisr
, trap
; } powerpc_regs
;
166 struct
{ unsigned int psr
, pc
, npc
, y
, wim
, tbr
; } sparc_regs
;
167 } ctl
; /* selected by SERVER_CTX_CONTROL
*/
170 struct
{ unsigned int eax
, ebx
, ecx
, edx
, esi
, edi
; } i386_regs
;
171 struct
{ unsigned __int64 rax
,rbx
, rcx
, rdx
, rsi
, rdi
,
172 r8
, r9
, r10
, r11
, r12
, r13
, r14
, r15
; } x86_64_regs
;
173 struct
{ unsigned __int64 v0
, t0
, t1
, t2
, t3
, t4
, t5
, t6
, t7
, t8
, t9
, t10
, t11
, t12
,
174 s0
, s1
, s2
, s3
, s4
, s5
, s6
, a0
, a1
, a2
, a3
, a4
, a5
, at
; } alpha_regs
;
175 struct
{ unsigned int gpr
[32], cr
, xer
; } powerpc_regs
;
176 struct
{ unsigned int g
[8], o
[8], l
[8], i
[8]; } sparc_regs
;
177 } integer
; /* selected by SERVER_CTX_INTEGER
*/
180 struct
{ unsigned int ds
, es
, fs
, gs
; } i386_regs
;
181 struct
{ unsigned int ds
, es
, fs
, gs
; } x86_64_regs
;
182 } seg
; /* selected by SERVER_CTX_SEGMENTS
*/
185 struct
{ unsigned int ctrl
, status
, tag
, err_off
, err_sel
, data_off
, data_sel
, cr0npx
;
186 unsigned char regs
[80]; } i386_regs
;
187 struct
{ struct
{ unsigned __int64 low
, high
; } fpregs
[32]; } x86_64_regs
;
188 struct
{ unsigned __int64 f
[32], fpcr
, softfpcr
; } alpha_regs
;
189 struct
{ double fpr
[32], fpscr
; } powerpc_regs
;
190 } fp
; /* selected by SERVER_CTX_FLOATING_POINT
*/
193 struct
{ unsigned int dr0
, dr1
, dr2
, dr3
, dr6
, dr7
; } i386_regs
;
194 struct
{ unsigned __int64 dr0
, dr1
, dr2
, dr3
, dr6
, dr7
; } x86_64_regs
;
195 struct
{ unsigned int dr
[8]; } powerpc_regs
;
196 } debug
; /* selected by SERVER_CTX_DEBUG_REGISTERS
*/
199 unsigned char i386_regs
[512];
200 } ext
; /* selected by SERVER_CTX_EXTENDED_REGISTERS
*/
203 #define SERVER_CTX_CONTROL
0x01
204 #define SERVER_CTX_INTEGER
0x02
205 #define SERVER_CTX_SEGMENTS
0x04
206 #define SERVER_CTX_FLOATING_POINT
0x08
207 #define SERVER_CTX_DEBUG_REGISTERS
0x10
208 #define SERVER_CTX_EXTENDED_REGISTERS
0x20
210 /* structure used in sending an fd from client to server
*/
213 thread_id_t tid
; /* thread id
*/
214 int fd
; /* file descriptor on client
-side
*/
217 /* structure sent by the server on the wait fifo
*/
220 client_ptr_t cookie
; /* magic cookie that was passed in select_request
*/
221 int signaled
; /* wait result
*/
225 /* NT
-style timeout
, in
100ns units
, negative means relative timeout
*/
226 typedef __int64 timeout_t
;
227 #define
TIMEOUT_INFINITE (((timeout_t
)0x7fffffff) << 32 |
0xffffffff)
229 /* structure for process startup info
*/
232 unsigned int debug_flags
;
233 unsigned int console_flags
;
234 obj_handle_t console
;
236 obj_handle_t hstdout
;
237 obj_handle_t hstderr
;
244 unsigned int attribute
;
247 data_size_t curdir_len
;
248 data_size_t dllpath_len
;
249 data_size_t imagepath_len
;
250 data_size_t cmdline_len
;
251 data_size_t title_len
;
252 data_size_t desktop_len
;
253 data_size_t shellinfo_len
;
254 data_size_t runtime_len
;
255 /* VARARG(curdir
,unicode_str
,curdir_len
); */
256 /* VARARG(dllpath
,unicode_str
,dllpath_len
); */
257 /* VARARG(imagepath
,unicode_str
,imagepath_len
); */
258 /* VARARG(cmdline
,unicode_str
,cmdline_len
); */
259 /* VARARG(title
,unicode_str
,title_len
); */
260 /* VARARG(desktop
,unicode_str
,desktop_len
); */
261 /* VARARG(shellinfo
,unicode_str
,shellinfo_len
); */
262 /* VARARG(runtime
,unicode_str
,runtime_len
); */
265 /* structure returned in the list of window properties
*/
268 atom_t atom
; /* property atom
*/
269 int string
; /* was atom a string originally?
*/
270 lparam_t data
; /* data stored in property
*/
273 /* structure to specify window rectangles
*/
282 /* structure for parameters of async I
/O calls
*/
285 obj_handle_t handle
; /* object to perform I
/O on
*/
286 obj_handle_t event
; /* event to signal when done
*/
287 client_ptr_t callback
; /* client
-side callback to call upon end of async
*/
288 client_ptr_t iosb
; /* I
/O status block in client addr space
*/
289 client_ptr_t arg
; /* opaque user data to pass to callback
*/
290 apc_param_t cvalue
; /* completion value to use for completion events
*/
293 /* structures for extra message data
*/
295 struct hardware_msg_data
297 lparam_t info
; /* extra info
*/
298 int x
; /* x position
*/
299 int y
; /* y position
*/
300 unsigned int hw_id
; /* unique id
*/
304 struct callback_msg_data
306 client_ptr_t callback
; /* callback function
*/
307 lparam_t data
; /* user data for callback
*/
308 lparam_t result
; /* message result
*/
311 struct winevent_msg_data
313 user_handle_t hook
; /* hook handle
*/
314 thread_id_t tid
; /* thread id
*/
315 client_ptr_t hook_proc
; /* hook proc address
*/
316 /* followed by module name if any
*/
321 unsigned char bytes
[1]; /* raw data for sent messages
*/
322 struct hardware_msg_data hardware
;
323 struct callback_msg_data callback
;
324 struct winevent_msg_data winevent
;
327 /* structure for console char
/attribute info
*/
336 unsigned int low_part
;
340 #define MAX_ACL_LEN
65535
342 struct security_descriptor
344 unsigned int control
; /* SE_ flags
*/
345 data_size_t owner_len
;
346 data_size_t group_len
;
347 data_size_t sacl_len
;
348 data_size_t dacl_len
;
349 /* VARARG(owner
,SID
); */
350 /* VARARG(group
,SID
); */
351 /* VARARG(sacl
,ACL
); */
352 /* VARARG(dacl
,ACL
); */
355 struct object_attributes
357 obj_handle_t rootdir
; /* root directory
*/
358 data_size_t sd_len
; /* length of security_descriptor data. may be
0 */
359 data_size_t name_len
; /* length of the name string. may be
0 */
360 /* VARARG(sd
,security_descriptor
); */
361 /* VARARG(name
,unicode_str
); */
367 /* unsigned int attributes
[count
]; */
368 /* VARARG(sids
,SID
); */
394 enum apc_type type
; /* APC_USER
*/
396 client_ptr_t func
; /* void (__stdcall
*func
)(ULONG_PTR
,ULONG_PTR
,ULONG_PTR
); */
397 apc_param_t args
[3]; /* arguments for user function
*/
401 enum apc_type type
; /* APC_TIMER
*/
403 client_ptr_t func
; /* void (__stdcall
*func
)(void
*, unsigned int
, unsigned int
); */
404 timeout_t time
; /* absolute time of expiration
*/
405 client_ptr_t arg
; /* user argument
*/
409 enum apc_type type
; /* APC_ASYNC_IO
*/
410 unsigned int status
; /* I
/O status
*/
411 client_ptr_t func
; /* unsigned
int (*func)(void*, void*, unsigned int, void **); */
412 client_ptr_t user
; /* user pointer
*/
413 client_ptr_t sb
; /* status block
*/
417 enum apc_type type
; /* APC_VIRTUAL_ALLOC
*/
418 unsigned int op_type
; /* type of operation
*/
419 client_ptr_t addr
; /* requested address
*/
420 mem_size_t size
; /* allocation size
*/
421 unsigned int zero_bits
; /* allocation alignment
*/
422 unsigned int prot
; /* memory protection flags
*/
426 enum apc_type type
; /* APC_VIRTUAL_FREE
*/
427 unsigned int op_type
; /* type of operation
*/
428 client_ptr_t addr
; /* requested address
*/
429 mem_size_t size
; /* allocation size
*/
433 enum apc_type type
; /* APC_VIRTUAL_QUERY
*/
435 client_ptr_t addr
; /* requested address
*/
439 enum apc_type type
; /* APC_VIRTUAL_PROTECT
*/
440 unsigned int prot
; /* new protection flags
*/
441 client_ptr_t addr
; /* requested address
*/
442 mem_size_t size
; /* requested size
*/
446 enum apc_type type
; /* APC_VIRTUAL_FLUSH
*/
448 client_ptr_t addr
; /* requested address
*/
449 mem_size_t size
; /* requested size
*/
453 enum apc_type type
; /* APC_VIRTUAL_LOCK
*/
455 client_ptr_t addr
; /* requested address
*/
456 mem_size_t size
; /* requested size
*/
460 enum apc_type type
; /* APC_VIRTUAL_UNLOCK
*/
462 client_ptr_t addr
; /* requested address
*/
463 mem_size_t size
; /* requested size
*/
467 enum apc_type type
; /* APC_MAP_VIEW
*/
468 obj_handle_t handle
; /* mapping handle
*/
469 client_ptr_t addr
; /* requested address
*/
470 mem_size_t size
; /* allocation size
*/
471 file_pos_t offset
; /* file offset
*/
472 unsigned int alloc_type
;/* allocation type
*/
473 unsigned short zero_bits
; /* allocation alignment
*/
474 unsigned short prot
; /* memory protection flags
*/
478 enum apc_type type
; /* APC_UNMAP_VIEW
*/
480 client_ptr_t addr
; /* view address
*/
484 enum apc_type type
; /* APC_CREATE_THREAD
*/
485 int suspend
; /* suspended thread?
*/
486 client_ptr_t func
; /* void (__stdcall
*func
)(void*)
; start function
*/
487 client_ptr_t arg
; /* argument for start function
*/
488 mem_size_t reserve
; /* reserve size for thread stack
*/
489 mem_size_t commit
; /* commit size for thread stack
*/
498 enum apc_type type
; /* APC_ASYNC_IO
*/
499 unsigned int status
; /* new status of async operation
*/
500 client_ptr_t apc
; /* user APC to call
*/
501 unsigned int total
; /* bytes transferred
*/
505 enum apc_type type
; /* APC_VIRTUAL_ALLOC
*/
506 unsigned int status
; /* status returned by call
*/
507 client_ptr_t addr
; /* resulting address
*/
508 mem_size_t size
; /* resulting size
*/
512 enum apc_type type
; /* APC_VIRTUAL_FREE
*/
513 unsigned int status
; /* status returned by call
*/
514 client_ptr_t addr
; /* resulting address
*/
515 mem_size_t size
; /* resulting size
*/
519 enum apc_type type
; /* APC_VIRTUAL_QUERY
*/
520 unsigned int status
; /* status returned by call
*/
521 client_ptr_t base
; /* resulting base address
*/
522 client_ptr_t alloc_base
;/* resulting allocation base
*/
523 mem_size_t size
; /* resulting region size
*/
524 unsigned short state
; /* resulting region state
*/
525 unsigned short prot
; /* resulting region protection
*/
526 unsigned short alloc_prot
;/* resulting allocation protection
*/
527 unsigned short alloc_type
;/* resulting region allocation type
*/
531 enum apc_type type
; /* APC_VIRTUAL_PROTECT
*/
532 unsigned int status
; /* status returned by call
*/
533 client_ptr_t addr
; /* resulting address
*/
534 mem_size_t size
; /* resulting size
*/
535 unsigned int prot
; /* old protection flags
*/
539 enum apc_type type
; /* APC_VIRTUAL_FLUSH
*/
540 unsigned int status
; /* status returned by call
*/
541 client_ptr_t addr
; /* resulting address
*/
542 mem_size_t size
; /* resulting size
*/
546 enum apc_type type
; /* APC_VIRTUAL_LOCK
*/
547 unsigned int status
; /* status returned by call
*/
548 client_ptr_t addr
; /* resulting address
*/
549 mem_size_t size
; /* resulting size
*/
553 enum apc_type type
; /* APC_VIRTUAL_UNLOCK
*/
554 unsigned int status
; /* status returned by call
*/
555 client_ptr_t addr
; /* resulting address
*/
556 mem_size_t size
; /* resulting size
*/
560 enum apc_type type
; /* APC_MAP_VIEW
*/
561 unsigned int status
; /* status returned by call
*/
562 client_ptr_t addr
; /* resulting address
*/
563 mem_size_t size
; /* resulting size
*/
567 enum apc_type type
; /* APC_MAP_VIEW
*/
568 unsigned int status
; /* status returned by call
*/
572 enum apc_type type
; /* APC_CREATE_THREAD
*/
573 unsigned int status
; /* status returned by call
*/
574 thread_id_t tid
; /* thread id
*/
575 obj_handle_t handle
; /* handle to new thread
*/
579 /****************************************************************/
580 /* Request declarations
*/
582 /* Create a new process from the context of the parent
*/
584 int inherit_all
; /* inherit all handles from parent
*/
585 unsigned int create_flags
; /* creation flags
*/
586 int socket_fd
; /* file descriptor for process socket
*/
587 obj_handle_t exe_file
; /* file handle for main exe
*/
588 unsigned int process_access
; /* access rights for process object
*/
589 unsigned int process_attr
; /* attributes for process object
*/
590 unsigned int thread_access
; /* access rights for thread object
*/
591 unsigned int thread_attr
; /* attributes for thread object
*/
592 data_size_t info_size
; /* size of startup info
*/
593 VARARG(info
,startup_info
,info_size
); /* startup information
*/
594 VARARG(env
,unicode_str
); /* environment for new process
*/
596 obj_handle_t info
; /* new process info handle
*/
597 process_id_t pid
; /* process id
*/
598 obj_handle_t phandle
; /* process
handle (in the current process
) */
599 thread_id_t tid
; /* thread id
*/
600 obj_handle_t thandle
; /* thread
handle (in the current process
) */
604 /* Retrieve information about a newly started process
*/
605 @
REQ(get_new_process_info
)
606 obj_handle_t info
; /* info handle returned from new_process_request
*/
608 int success
; /* did the process start successfully?
*/
609 int exit_code
; /* process exit code if failed
*/
613 /* Create a new thread from the context of the parent
*/
615 unsigned int access
; /* wanted access rights
*/
616 unsigned int attributes
; /* object attributes
*/
617 int suspend
; /* new thread should be suspended on creation
*/
618 int request_fd
; /* fd for request pipe
*/
620 thread_id_t tid
; /* thread id
*/
621 obj_handle_t handle
; /* thread
handle (in the current process
) */
625 /* Retrieve the new process startup info
*/
626 @
REQ(get_startup_info
)
628 obj_handle_t exe_file
; /* file handle for main exe
*/
629 data_size_t info_size
; /* size of startup info
*/
630 VARARG(info
,startup_info
,info_size
); /* startup information
*/
631 VARARG(env
,unicode_str
); /* environment
*/
635 /* Signal the end of the process initialization
*/
636 @
REQ(init_process_done
)
637 int gui
; /* is it a GUI process?
*/
638 mod_handle_t module
; /* main module base address
*/
639 client_ptr_t ldt_copy
; /* address of LDT
copy (in thread address space
) */
640 client_ptr_t entry
; /* process entry point
*/
644 /* Initialize a thread
; called from the child after
fork()/clone() */
646 int unix_pid
; /* Unix pid of new thread
*/
647 int unix_tid
; /* Unix tid of new thread
*/
648 int debug_level
; /* new debug level
*/
649 client_ptr_t teb
; /* TEB of new
thread (in thread address space
) */
650 client_ptr_t entry
; /* entry point or PEB if initial
thread (in thread address space
) */
651 int reply_fd
; /* fd for reply pipe
*/
652 int wait_fd
; /* fd for blocking calls pipe
*/
653 cpu_type_t cpu
; /* CPU that this thread is running on
*/
655 process_id_t pid
; /* process id of the new thread
's process */
656 thread_id_t tid; /* thread id of the new thread */
657 timeout_t server_start; /* server start time */
658 data_size_t info_size; /* total size of startup info */
659 int version; /* protocol version */
660 unsigned int all_cpus; /* bitset of supported CPUs */
664 /* Terminate a process */
665 @REQ(terminate_process)
666 obj_handle_t handle; /* process handle to terminate */
667 int exit_code; /* process exit code */
669 int self; /* suicide? */
673 /* Terminate a thread */
674 @REQ(terminate_thread)
675 obj_handle_t handle; /* thread handle to terminate */
676 int exit_code; /* thread exit code */
678 int self; /* suicide? */
679 int last; /* last thread in this process? */
683 /* Retrieve information about a process */
684 @REQ(get_process_info)
685 obj_handle_t handle; /* process handle */
687 process_id_t pid; /* server process id */
688 process_id_t ppid; /* server process id of parent */
689 affinity_t affinity; /* process affinity mask */
690 client_ptr_t peb; /* PEB address in process address space */
691 timeout_t start_time; /* process start time */
692 timeout_t end_time; /* process end time */
693 int exit_code; /* process exit code */
694 int priority; /* priority class */
695 cpu_type_t cpu; /* CPU that this process is running on */
699 /* Set a process informations */
700 @REQ(set_process_info)
701 obj_handle_t handle; /* process handle */
702 int mask; /* setting mask (see below) */
703 int priority; /* priority class */
704 affinity_t affinity; /* affinity mask */
706 #define SET_PROCESS_INFO_PRIORITY 0x01
707 #define SET_PROCESS_INFO_AFFINITY 0x02
710 /* Retrieve information about a thread */
711 @REQ(get_thread_info)
712 obj_handle_t handle; /* thread handle */
713 thread_id_t tid_in; /* thread id (optional) */
715 process_id_t pid; /* server process id */
716 thread_id_t tid; /* server thread id */
717 client_ptr_t teb; /* thread teb pointer */
718 affinity_t affinity; /* thread affinity mask */
719 timeout_t creation_time; /* thread creation time */
720 timeout_t exit_time; /* thread exit time */
721 int exit_code; /* thread exit code */
722 int priority; /* thread priority level */
723 int last; /* last thread in process */
727 /* Set a thread informations */
728 @REQ(set_thread_info)
729 obj_handle_t handle; /* thread handle */
730 int mask; /* setting mask (see below) */
731 int priority; /* priority class */
732 affinity_t affinity; /* affinity mask */
733 obj_handle_t token; /* impersonation token */
735 #define SET_THREAD_INFO_PRIORITY 0x01
736 #define SET_THREAD_INFO_AFFINITY 0x02
737 #define SET_THREAD_INFO_TOKEN 0x04
740 /* Retrieve information about a module */
742 obj_handle_t handle; /* process handle */
743 mod_handle_t base_address; /* base address of module */
745 client_ptr_t entry_point;
746 data_size_t size; /* module size */
747 data_size_t filename_len; /* buffer len in bytes required to store filename */
748 VARARG(filename,unicode_str); /* file name of module */
752 /* Suspend a thread */
754 obj_handle_t handle; /* thread handle */
756 int count; /* new suspend count */
760 /* Resume a thread */
762 obj_handle_t handle; /* thread handle */
764 int count; /* new suspend count */
768 /* Notify the server that a dll has been loaded */
770 obj_handle_t handle; /* file handle */
771 mod_handle_t base; /* base address */
772 client_ptr_t name; /* ptr to ptr to name (in process addr space) */
773 data_size_t size; /* dll size */
774 int dbg_offset; /* debug info offset */
775 int dbg_size; /* debug info size */
776 VARARG(filename,unicode_str); /* file name of dll */
780 /* Notify the server that a dll is being unloaded */
782 mod_handle_t base; /* base address */
786 /* Queue an APC for a thread or process */
788 obj_handle_t handle; /* thread or process handle */
789 apc_call_t call; /* call arguments */
791 obj_handle_t handle; /* APC handle */
792 int self; /* run APC in caller itself? */
796 /* Get the result of an APC call */
798 obj_handle_t handle; /* handle to the APC */
800 apc_result_t result; /* result of the APC */
804 /* Close a handle for the current process */
806 obj_handle_t handle; /* handle to close */
810 /* Set a handle information */
811 @REQ(set_handle_info)
812 obj_handle_t handle; /* handle we are interested in */
813 int flags; /* new handle flags */
814 int mask; /* mask for flags to set */
816 int old_flags; /* old flag value */
820 /* Duplicate a handle */
822 obj_handle_t src_process; /* src process handle */
823 obj_handle_t src_handle; /* src handle to duplicate */
824 obj_handle_t dst_process; /* dst process handle */
825 unsigned int access; /* wanted access rights */
826 unsigned int attributes; /* object attributes */
827 unsigned int options; /* duplicate options (see below) */
829 obj_handle_t handle; /* duplicated handle in dst process */
830 int self; /* is the source the current process? */
831 int closed; /* whether the source handle has been closed */
833 #define DUP_HANDLE_CLOSE_SOURCE DUPLICATE_CLOSE_SOURCE
834 #define DUP_HANDLE_SAME_ACCESS DUPLICATE_SAME_ACCESS
835 #define DUP_HANDLE_MAKE_GLOBAL 0x80000000 /* Not a Windows flag */
838 /* Open a handle to a process */
840 process_id_t pid; /* process id to open */
841 unsigned int access; /* wanted access rights */
842 unsigned int attributes; /* object attributes */
844 obj_handle_t handle; /* handle to the process */
848 /* Open a handle to a thread */
850 thread_id_t tid; /* thread id to open */
851 unsigned int access; /* wanted access rights */
852 unsigned int attributes; /* object attributes */
854 obj_handle_t handle; /* handle to the thread */
858 /* Wait for handles */
860 int flags; /* wait flags (see below) */
861 client_ptr_t cookie; /* magic cookie to return to client */
862 obj_handle_t signal; /* object to signal (0 if none) */
863 obj_handle_t prev_apc; /* handle to previous APC */
864 timeout_t timeout; /* timeout */
865 VARARG(result,apc_result); /* result of previous APC */
866 VARARG(handles,handles); /* handles to select on */
868 timeout_t timeout; /* timeout converted to absolute */
869 apc_call_t call; /* APC call arguments */
870 obj_handle_t apc_handle; /* handle to next APC */
873 #define SELECT_ALERTABLE 2
874 #define SELECT_INTERRUPTIBLE 4
877 /* Create an event */
879 unsigned int access; /* wanted access rights */
880 unsigned int attributes; /* object attributes */
881 int manual_reset; /* manual reset event */
882 int initial_state; /* initial state of the event */
883 VARARG(objattr,object_attributes); /* object attributes */
885 obj_handle_t handle; /* handle to the event */
888 /* Event operation */
890 obj_handle_t handle; /* handle to event */
891 int op; /* event operation (see below) */
893 enum event_op { PULSE_EVENT, SET_EVENT, RESET_EVENT };
898 unsigned int access; /* wanted access rights */
899 unsigned int attributes; /* object attributes */
900 obj_handle_t rootdir; /* root directory */
901 VARARG(name,unicode_str); /* object name */
903 obj_handle_t handle; /* handle to the event */
909 unsigned int access; /* wanted access rights */
910 unsigned int attributes; /* object attributes */
911 int owned; /* initially owned? */
912 VARARG(objattr,object_attributes); /* object attributes */
914 obj_handle_t handle; /* handle to the mutex */
918 /* Release a mutex */
920 obj_handle_t handle; /* handle to the mutex */
922 unsigned int prev_count; /* value of internal counter, before release */
928 unsigned int access; /* wanted access rights */
929 unsigned int attributes; /* object attributes */
930 obj_handle_t rootdir; /* root directory */
931 VARARG(name,unicode_str); /* object name */
933 obj_handle_t handle; /* handle to the mutex */
937 /* Create a semaphore */
938 @REQ(create_semaphore)
939 unsigned int access; /* wanted access rights */
940 unsigned int attributes; /* object attributes */
941 unsigned int initial; /* initial count */
942 unsigned int max; /* maximum count */
943 VARARG(objattr,object_attributes); /* object attributes */
945 obj_handle_t handle; /* handle to the semaphore */
949 /* Release a semaphore */
950 @REQ(release_semaphore)
951 obj_handle_t handle; /* handle to the semaphore */
952 unsigned int count; /* count to add to semaphore */
954 unsigned int prev_count; /* previous semaphore count */
958 /* Open a semaphore */
960 unsigned int access; /* wanted access rights */
961 unsigned int attributes; /* object attributes */
962 obj_handle_t rootdir; /* root directory */
963 VARARG(name,unicode_str); /* object name */
965 obj_handle_t handle; /* handle to the semaphore */
971 unsigned int access; /* wanted access rights */
972 unsigned int attributes; /* object attributes */
973 unsigned int sharing; /* sharing flags */
974 int create; /* file create action */
975 unsigned int options; /* file options */
976 unsigned int attrs; /* file attributes for creation */
977 VARARG(objattr,object_attributes); /* object attributes */
978 VARARG(filename,string); /* file name */
980 obj_handle_t handle; /* handle to the file */
984 /* Open a file object */
985 @REQ(open_file_object)
986 unsigned int access; /* wanted access rights */
987 unsigned int attributes; /* open attributes */
988 obj_handle_t rootdir; /* root directory */
989 unsigned int sharing; /* sharing flags */
990 unsigned int options; /* file options */
991 VARARG(filename,unicode_str); /* file name */
993 obj_handle_t handle; /* handle to the file */
997 /* Allocate a file handle for a Unix fd */
998 @REQ(alloc_file_handle)
999 unsigned int access; /* wanted access rights */
1000 unsigned int attributes; /* object attributes */
1001 int fd; /* file descriptor on the client side */
1003 obj_handle_t handle; /* handle to the file */
1007 /* Get a Unix fd to access a file */
1009 obj_handle_t handle; /* handle to the file */
1011 int type; /* file type (see below) */
1012 int removable; /* is file removable? */
1013 unsigned int access; /* file access rights */
1014 unsigned int options; /* file open options */
1018 FD_TYPE_INVALID, /* invalid file (no associated fd) */
1019 FD_TYPE_FILE, /* regular file */
1020 FD_TYPE_DIR, /* directory */
1021 FD_TYPE_SOCKET, /* socket */
1022 FD_TYPE_SERIAL, /* serial port */
1023 FD_TYPE_PIPE, /* named pipe */
1024 FD_TYPE_MAILSLOT, /* mailslot */
1025 FD_TYPE_CHAR, /* unspecified char device */
1026 FD_TYPE_DEVICE, /* Windows device file */
1031 /* Flush a file buffers */
1033 obj_handle_t handle; /* handle to the file */
1035 obj_handle_t event; /* event set when finished */
1039 /* Lock a region of a file */
1041 obj_handle_t handle; /* handle to the file */
1042 file_pos_t offset; /* offset of start of lock */
1043 file_pos_t count; /* count of bytes to lock */
1044 int shared; /* shared or exclusive lock? */
1045 int wait; /* do we want to wait? */
1047 obj_handle_t handle; /* handle to wait on */
1048 int overlapped; /* is it an overlapped I/O handle? */
1052 /* Unlock a region of a file */
1054 obj_handle_t handle; /* handle to the file */
1055 file_pos_t offset; /* offset of start of unlock */
1056 file_pos_t count; /* count of bytes to unlock */
1060 /* Create a socket */
1062 unsigned int access; /* wanted access rights */
1063 unsigned int attributes; /* object attributes */
1064 int family; /* family, see socket manpage */
1065 int type; /* type, see socket manpage */
1066 int protocol; /* protocol, see socket manpage */
1067 unsigned int flags; /* socket flags */
1069 obj_handle_t handle; /* handle to the new socket */
1073 /* Accept a socket */
1075 obj_handle_t lhandle; /* handle to the listening socket */
1076 unsigned int access; /* wanted access rights */
1077 unsigned int attributes; /* object attributes */
1079 obj_handle_t handle; /* handle to the new socket */
1083 /* Set socket event parameters */
1084 @REQ(set_socket_event)
1085 obj_handle_t handle; /* handle to the socket */
1086 unsigned int mask; /* event mask */
1087 obj_handle_t event; /* event object */
1088 user_handle_t window; /* window to send the message to */
1089 unsigned int msg; /* message to send */
1093 /* Get socket event parameters */
1094 @REQ(get_socket_event)
1095 obj_handle_t handle; /* handle to the socket */
1096 int service; /* clear pending? */
1097 obj_handle_t c_event; /* event to clear */
1099 unsigned int mask; /* event mask */
1100 unsigned int pmask; /* pending events */
1101 unsigned int state; /* status bits */
1102 VARARG(errors,ints); /* event errors */
1106 /* Reenable pending socket events */
1107 @REQ(enable_socket_event)
1108 obj_handle_t handle; /* handle to the socket */
1109 unsigned int mask; /* events to re-enable */
1110 unsigned int sstate; /* status bits to set */
1111 unsigned int cstate; /* status bits to clear */
1114 @REQ(set_socket_deferred)
1115 obj_handle_t handle; /* handle to the socket */
1116 obj_handle_t deferred; /* handle to the socket for which accept() is deferred */
1119 /* Allocate a console (only used by a console renderer) */
1121 unsigned int access; /* wanted access rights */
1122 unsigned int attributes; /* object attributes */
1123 process_id_t pid; /* pid of process which shall be attached to the console */
1125 obj_handle_t handle_in; /* handle to console input */
1126 obj_handle_t event; /* handle to renderer events change notification */
1130 /* Free the console of the current process */
1135 #define CONSOLE_RENDERER_NONE_EVENT 0x00
1136 #define CONSOLE_RENDERER_TITLE_EVENT 0x01
1137 #define CONSOLE_RENDERER_ACTIVE_SB_EVENT 0x02
1138 #define CONSOLE_RENDERER_SB_RESIZE_EVENT 0x03
1139 #define CONSOLE_RENDERER_UPDATE_EVENT 0x04
1140 #define CONSOLE_RENDERER_CURSOR_POS_EVENT 0x05
1141 #define CONSOLE_RENDERER_CURSOR_GEOM_EVENT 0x06
1142 #define CONSOLE_RENDERER_DISPLAY_EVENT 0x07
1143 #define CONSOLE_RENDERER_EXIT_EVENT 0x08
1144 struct console_renderer_event
1179 /* retrieve console events for the renderer */
1180 @REQ(get_console_renderer_events)
1181 obj_handle_t handle; /* handle to console input events */
1183 VARARG(data,bytes); /* the various console_renderer_events */
1187 /* Open a handle to the process console */
1189 obj_handle_t from; /* 0 (resp 1) input (resp output) of current process console */
1190 /* otherwise console_in handle to get active screen buffer? */
1191 unsigned int access; /* wanted access rights */
1192 unsigned int attributes; /* object attributes */
1193 int share; /* share mask (only for output handles) */
1195 obj_handle_t handle; /* handle to the console */
1199 /* Get the input queue wait event */
1200 @REQ(get_console_wait_event)
1202 obj_handle_t handle;
1205 /* Get a console mode (input or output) */
1206 @REQ(get_console_mode)
1207 obj_handle_t handle; /* handle to the console */
1209 int mode; /* console mode */
1213 /* Set a console mode (input or output) */
1214 @REQ(set_console_mode)
1215 obj_handle_t handle; /* handle to the console */
1216 int mode; /* console mode */
1220 /* Set info about a console (input only) */
1221 @REQ(set_console_input_info)
1222 obj_handle_t handle; /* handle to console input, or 0 for process' console
*/
1223 int mask
; /* setting
mask (see below
) */
1224 obj_handle_t active_sb
; /* active screen buffer
*/
1225 int history_mode
; /* whether we duplicate lines in history
*/
1226 int history_size
; /* number of lines in history
*/
1227 int edition_mode
; /* index to the edition mode flavors
*/
1228 int input_cp
; /* console input codepage
*/
1229 int output_cp
; /* console output codepage
*/
1230 user_handle_t win
; /* console window if backend supports it
*/
1231 VARARG(title
,unicode_str
); /* console title
*/
1233 #define SET_CONSOLE_INPUT_INFO_ACTIVE_SB
0x01
1234 #define SET_CONSOLE_INPUT_INFO_TITLE
0x02
1235 #define SET_CONSOLE_INPUT_INFO_HISTORY_MODE
0x04
1236 #define SET_CONSOLE_INPUT_INFO_HISTORY_SIZE
0x08
1237 #define SET_CONSOLE_INPUT_INFO_EDITION_MODE
0x10
1238 #define SET_CONSOLE_INPUT_INFO_INPUT_CODEPAGE
0x20
1239 #define SET_CONSOLE_INPUT_INFO_OUTPUT_CODEPAGE
0x40
1240 #define SET_CONSOLE_INPUT_INFO_WIN
0x80
1243 /* Get info about a
console (input only
) */
1244 @
REQ(get_console_input_info
)
1245 obj_handle_t handle
; /* handle to console input
, or
0 for process
' console */
1247 int history_mode; /* whether we duplicate lines in history */
1248 int history_size; /* number of lines in history */
1249 int history_index; /* number of used lines in history */
1250 int edition_mode; /* index to the edition mode flavors */
1251 int input_cp; /* console input codepage */
1252 int output_cp; /* console output codepage */
1253 user_handle_t win; /* console window if backend supports it */
1254 VARARG(title,unicode_str); /* console title */
1258 /* appends a string to console's history
*/
1259 @
REQ(append_console_input_history
)
1260 obj_handle_t handle
; /* handle to console input
, or
0 for process
' console */
1261 VARARG(line,unicode_str); /* line to add */
1265 /* appends a string to console's history
*/
1266 @
REQ(get_console_input_history
)
1267 obj_handle_t handle
; /* handle to console input
, or
0 for process
' console */
1268 int index; /* index to get line from */
1270 int total; /* total length of line in Unicode chars */
1271 VARARG(line,unicode_str); /* line to add */
1275 /* creates a new screen buffer on process' console
*/
1276 @
REQ(create_console_output
)
1277 obj_handle_t handle_in
; /* handle to console input
, or
0 for process
' console */
1278 unsigned int access; /* wanted access rights */
1279 unsigned int attributes; /* object attributes */
1280 unsigned int share; /* sharing credentials */
1282 obj_handle_t handle_out; /* handle to the screen buffer */
1286 /* Set info about a console (output only) */
1287 @REQ(set_console_output_info)
1288 obj_handle_t handle; /* handle to the console */
1289 int mask; /* setting mask (see below) */
1290 short int cursor_size; /* size of cursor (percentage filled) */
1291 short int cursor_visible;/* cursor visibility flag */
1292 short int cursor_x; /* position of cursor (x, y) */
1294 short int width; /* width of the screen buffer */
1295 short int height; /* height of the screen buffer */
1296 short int attr; /* default attribute */
1297 short int win_left; /* window actually displayed by renderer */
1298 short int win_top; /* the rect area is expressed withing the */
1299 short int win_right; /* boundaries of the screen buffer */
1300 short int win_bottom;
1301 short int max_width; /* maximum size (width x height) for the window */
1302 short int max_height;
1304 #define SET_CONSOLE_OUTPUT_INFO_CURSOR_GEOM 0x01
1305 #define SET_CONSOLE_OUTPUT_INFO_CURSOR_POS 0x02
1306 #define SET_CONSOLE_OUTPUT_INFO_SIZE 0x04
1307 #define SET_CONSOLE_OUTPUT_INFO_ATTR 0x08
1308 #define SET_CONSOLE_OUTPUT_INFO_DISPLAY_WINDOW 0x10
1309 #define SET_CONSOLE_OUTPUT_INFO_MAX_SIZE 0x20
1312 /* Get info about a console (output only) */
1313 @REQ(get_console_output_info)
1314 obj_handle_t handle; /* handle to the console */
1316 short int cursor_size; /* size of cursor (percentage filled) */
1317 short int cursor_visible;/* cursor visibility flag */
1318 short int cursor_x; /* position of cursor (x, y) */
1320 short int width; /* width of the screen buffer */
1321 short int height; /* height of the screen buffer */
1322 short int attr; /* default attribute */
1323 short int win_left; /* window actually displayed by renderer */
1324 short int win_top; /* the rect area is expressed withing the */
1325 short int win_right; /* boundaries of the screen buffer */
1326 short int win_bottom;
1327 short int max_width; /* maximum size (width x height) for the window */
1328 short int max_height;
1331 /* Add input records to a console input queue */
1332 @REQ(write_console_input)
1333 obj_handle_t handle; /* handle to the console input */
1334 VARARG(rec,input_records); /* input records */
1336 int written; /* number of records written */
1340 /* Fetch input records from a console input queue */
1341 @REQ(read_console_input)
1342 obj_handle_t handle; /* handle to the console input */
1343 int flush; /* flush the retrieved records from the queue? */
1345 int read; /* number of records read */
1346 VARARG(rec,input_records); /* input records */
1350 /* write data (chars and/or attributes) in a screen buffer */
1351 @REQ(write_console_output)
1352 obj_handle_t handle; /* handle to the console output */
1353 int x; /* position where to start writing */
1355 int mode; /* char info (see below) */
1356 int wrap; /* wrap around at end of line? */
1357 VARARG(data,bytes); /* info to write */
1359 int written; /* number of char infos actually written */
1360 int width; /* width of screen buffer */
1361 int height; /* height of screen buffer */
1365 CHAR_INFO_MODE_TEXT, /* characters only */
1366 CHAR_INFO_MODE_ATTR, /* attributes only */
1367 CHAR_INFO_MODE_TEXTATTR, /* both characters and attributes */
1368 CHAR_INFO_MODE_TEXTSTDATTR /* characters but use standard attributes */
1372 /* fill a screen buffer with constant data (chars and/or attributes) */
1373 @REQ(fill_console_output)
1374 obj_handle_t handle; /* handle to the console output */
1375 int x; /* position where to start writing */
1377 int mode; /* char info mode */
1378 int count; /* number to write */
1379 int wrap; /* wrap around at end of line? */
1380 char_info_t data; /* data to write */
1382 int written; /* number of char infos actually written */
1386 /* read data (chars and/or attributes) from a screen buffer */
1387 @REQ(read_console_output)
1388 obj_handle_t handle; /* handle to the console output */
1389 int x; /* position (x,y) where to start reading */
1391 int mode; /* char info mode */
1392 int wrap; /* wrap around at end of line? */
1394 int width; /* width of screen buffer */
1395 int height; /* height of screen buffer */
1400 /* move a rect (of data) in screen buffer content */
1401 @REQ(move_console_output)
1402 obj_handle_t handle; /* handle to the console output */
1403 short int x_src; /* position (x, y) of rect to start moving from */
1405 short int x_dst; /* position (x, y) of rect to move to */
1407 short int w; /* size of the rect (width, height) to move */
1412 /* Sends a signal to a process group */
1413 @REQ(send_console_signal)
1414 int signal; /* the signal to send */
1415 process_id_t group_id; /* the group to send the signal to */
1419 /* enable directory change notifications */
1420 @REQ(read_directory_changes)
1421 unsigned int filter; /* notification filter */
1422 int subtree; /* watch the subtree? */
1423 int want_data; /* flag indicating whether change data should be collected */
1424 async_data_t async; /* async I/O parameters */
1429 obj_handle_t handle;
1431 int action; /* type of change */
1432 VARARG(name,string); /* name of directory entry that changed */
1436 /* Create a file mapping */
1437 @REQ(create_mapping)
1438 unsigned int access; /* wanted access rights */
1439 unsigned int attributes; /* object attributes */
1440 unsigned int protect; /* protection flags (see below) */
1441 mem_size_t size; /* mapping size */
1442 obj_handle_t file_handle; /* file handle */
1443 VARARG(objattr,object_attributes); /* object attributes */
1445 obj_handle_t handle; /* handle to the mapping */
1447 /* per-page protection flags */
1448 #define VPROT_READ 0x01
1449 #define VPROT_WRITE 0x02
1450 #define VPROT_EXEC 0x04
1451 #define VPROT_WRITECOPY 0x08
1452 #define VPROT_GUARD 0x10
1453 #define VPROT_NOCACHE 0x20
1454 #define VPROT_COMMITTED 0x40
1455 #define VPROT_WRITEWATCH 0x80
1456 /* per-mapping protection flags */
1457 #define VPROT_IMAGE 0x0100 /* mapping for an exe image */
1458 #define VPROT_SYSTEM 0x0200 /* system view (underlying mmap not under our control) */
1459 #define VPROT_VALLOC 0x0400 /* allocated by VirtualAlloc */
1460 #define VPROT_NOEXEC 0x0800 /* don't force exec permission
*/
1463 /* Open a mapping
*/
1465 unsigned int access
; /* wanted access rights
*/
1466 unsigned int attributes
; /* object attributes
*/
1467 obj_handle_t rootdir
; /* root directory
*/
1468 VARARG(name
,unicode_str
); /* object name
*/
1470 obj_handle_t handle
; /* handle to the mapping
*/
1474 /* Get information about a file mapping
*/
1475 @
REQ(get_mapping_info
)
1476 obj_handle_t handle
; /* handle to the mapping
*/
1477 unsigned int access
; /* wanted access rights
*/
1479 mem_size_t size
; /* mapping size
*/
1480 int protect
; /* protection flags
*/
1481 int header_size
; /* header
size (for VPROT_IMAGE mapping
) */
1482 client_ptr_t base
; /* default base
addr (for VPROT_IMAGE mapping
) */
1483 obj_handle_t mapping
; /* duplicate mapping handle unless removable
*/
1484 obj_handle_t shared_file
; /* shared mapping file handle
*/
1488 /* Get a range of committed pages in a file mapping
*/
1489 @
REQ(get_mapping_committed_range
)
1490 obj_handle_t handle
; /* handle to the mapping
*/
1491 file_pos_t offset
; /* starting
offset (page
-aligned
, in bytes
) */
1493 mem_size_t size
; /* size of range starting at
offset (page
-aligned
, in bytes
) */
1494 int committed
; /* whether it is a committed range
*/
1498 /* Add a range to the committed pages in a file mapping
*/
1499 @
REQ(add_mapping_committed_range
)
1500 obj_handle_t handle
; /* handle to the mapping
*/
1501 file_pos_t offset
; /* starting
offset (page
-aligned
, in bytes
) */
1502 mem_size_t size
; /* size to
set (page
-aligned
, in bytes
) or
0 if only retrieving
*/
1506 #define SNAP_PROCESS
0x00000001
1507 #define SNAP_THREAD
0x00000002
1508 /* Create a snapshot
*/
1509 @
REQ(create_snapshot
)
1510 unsigned int attributes
; /* object attributes
*/
1511 unsigned int flags
; /* snapshot
flags (SNAP_*)
*/
1513 obj_handle_t handle
; /* handle to the snapshot
*/
1517 /* Get the next process from a snapshot
*/
1519 obj_handle_t handle
; /* handle to the snapshot
*/
1520 int reset
; /* reset snapshot position?
*/
1522 int count
; /* process usage count
*/
1523 process_id_t pid
; /* process id
*/
1524 process_id_t ppid
; /* parent process id
*/
1525 int threads
; /* number of threads
*/
1526 int priority
; /* process priority
*/
1527 int handles
; /* number of handles
*/
1528 VARARG(filename
,unicode_str
); /* file name of main exe
*/
1532 /* Get the next thread from a snapshot
*/
1534 obj_handle_t handle
; /* handle to the snapshot
*/
1535 int reset
; /* reset snapshot position?
*/
1537 int count
; /* thread usage count
*/
1538 process_id_t pid
; /* process id
*/
1539 thread_id_t tid
; /* thread id
*/
1540 int base_pri
; /* base priority
*/
1541 int delta_pri
; /* delta priority
*/
1545 /* Wait for a debug event
*/
1546 @
REQ(wait_debug_event
)
1547 int get_handle
; /* should we alloc a handle for waiting?
*/
1549 process_id_t pid
; /* process id
*/
1550 thread_id_t tid
; /* thread id
*/
1551 obj_handle_t wait
; /* wait handle if no event ready
*/
1552 VARARG(event
,debug_event
); /* debug event data
*/
1556 /* Queue an exception event
*/
1557 @
REQ(queue_exception_event
)
1558 int first
; /* first chance exception?
*/
1559 unsigned int code
; /* exception code
*/
1560 unsigned int flags
; /* exception flags
*/
1561 client_ptr_t record
; /* exception record
*/
1562 client_ptr_t address
; /* exception address
*/
1563 data_size_t len
; /* size of parameters
*/
1564 VARARG(params
,uints64
,len
);/* exception parameters
*/
1565 VARARG(context
,context
); /* thread context
*/
1567 obj_handle_t handle
; /* handle to the queued event
*/
1571 /* Retrieve the status of an exception event
*/
1572 @
REQ(get_exception_status
)
1573 obj_handle_t handle
; /* handle to the queued event
*/
1575 VARARG(context
,context
); /* modified thread context
*/
1579 /* Send an output string to the debugger
*/
1580 @
REQ(output_debug_string
)
1581 data_size_t length
; /* string length
*/
1582 client_ptr_t string
; /* string to
display (in debugged process address space
) */
1583 int unicode
; /* is it Unicode?
*/
1587 /* Continue a debug event
*/
1588 @
REQ(continue_debug_event
)
1589 process_id_t pid
; /* process id to continue
*/
1590 thread_id_t tid
; /* thread id to continue
*/
1591 int status
; /* continuation status
*/
1595 /* Start
/stop debugging an existing process
*/
1597 process_id_t pid
; /* id of the process to debug
*/
1598 int attach
; /* 1=attaching
/ 0=detaching from the process
*/
1602 /* Simulate a breakpoint in a process
*/
1604 obj_handle_t handle
; /* process handle
*/
1606 int self
; /* was it the caller itself?
*/
1610 /* Set debugger kill on exit flag
*/
1611 @
REQ(set_debugger_kill_on_exit
)
1612 int kill_on_exit
; /* 0=detach
/1=kill debuggee when debugger dies
*/
1616 /* Read data from a process address space
*/
1617 @
REQ(read_process_memory
)
1618 obj_handle_t handle
; /* process handle
*/
1619 client_ptr_t addr
; /* addr to read from
*/
1621 VARARG(data
,bytes
); /* result data
*/
1625 /* Write data to a process address space
*/
1626 @
REQ(write_process_memory
)
1627 obj_handle_t handle
; /* process handle
*/
1628 client_ptr_t addr
; /* addr to write to
*/
1629 VARARG(data
,bytes
); /* data to write
*/
1633 /* Create a registry key
*/
1635 obj_handle_t parent
; /* handle to the parent key
*/
1636 unsigned int access
; /* desired access rights
*/
1637 unsigned int attributes
; /* object attributes
*/
1638 unsigned int options
; /* creation options
*/
1639 data_size_t namelen
; /* length of key name in bytes
*/
1640 VARARG(name
,unicode_str
,namelen
); /* key name
*/
1641 VARARG(class
,unicode_str
); /* class name
*/
1643 obj_handle_t hkey
; /* handle to the created key
*/
1644 int created
; /* has it been newly created?
*/
1647 /* Open a registry key
*/
1649 obj_handle_t parent
; /* handle to the parent key
*/
1650 unsigned int access
; /* desired access rights
*/
1651 unsigned int attributes
; /* object attributes
*/
1652 VARARG(name
,unicode_str
); /* key name
*/
1654 obj_handle_t hkey
; /* handle to the open key
*/
1658 /* Delete a registry key
*/
1660 obj_handle_t hkey
; /* handle to the key
*/
1664 /* Flush a registry key
*/
1666 obj_handle_t hkey
; /* handle to the key
*/
1670 /* Enumerate registry subkeys
*/
1672 obj_handle_t hkey
; /* handle to registry key
*/
1673 int index
; /* index of
subkey (or
-1 for current key
) */
1674 int info_class
; /* requested information class
*/
1676 int subkeys
; /* number of subkeys
*/
1677 int max_subkey
; /* longest subkey name
*/
1678 int max_class
; /* longest class name
*/
1679 int values
; /* number of values
*/
1680 int max_value
; /* longest value name
*/
1681 int max_data
; /* longest value data
*/
1682 timeout_t modif
; /* last modification time
*/
1683 data_size_t total
; /* total length needed for full name and class
*/
1684 data_size_t namelen
; /* length of key name in bytes
*/
1685 VARARG(name
,unicode_str
,namelen
); /* key name
*/
1686 VARARG(class
,unicode_str
); /* class name
*/
1690 /* Set a value of a registry key
*/
1692 obj_handle_t hkey
; /* handle to registry key
*/
1693 int type
; /* value type
*/
1694 data_size_t namelen
; /* length of value name in bytes
*/
1695 VARARG(name
,unicode_str
,namelen
); /* value name
*/
1696 VARARG(data
,bytes
); /* value data
*/
1700 /* Retrieve the value of a registry key
*/
1702 obj_handle_t hkey
; /* handle to registry key
*/
1703 VARARG(name
,unicode_str
); /* value name
*/
1705 int type
; /* value type
*/
1706 data_size_t total
; /* total length needed for data
*/
1707 VARARG(data
,bytes
); /* value data
*/
1711 /* Enumerate a value of a registry key
*/
1712 @
REQ(enum_key_value
)
1713 obj_handle_t hkey
; /* handle to registry key
*/
1714 int index
; /* value index
*/
1715 int info_class
; /* requested information class
*/
1717 int type
; /* value type
*/
1718 data_size_t total
; /* total length needed for full name and data
*/
1719 data_size_t namelen
; /* length of value name in bytes
*/
1720 VARARG(name
,unicode_str
,namelen
); /* value name
*/
1721 VARARG(data
,bytes
); /* value data
*/
1725 /* Delete a value of a registry key
*/
1726 @
REQ(delete_key_value
)
1727 obj_handle_t hkey
; /* handle to registry key
*/
1728 VARARG(name
,unicode_str
); /* value name
*/
1732 /* Load a registry branch from a file
*/
1734 obj_handle_t hkey
; /* root key to load to
*/
1735 obj_handle_t file
; /* file to load from
*/
1736 VARARG(name
,unicode_str
); /* subkey name
*/
1740 /* UnLoad a registry branch from a file
*/
1741 @
REQ(unload_registry
)
1742 obj_handle_t hkey
; /* root key to unload to
*/
1746 /* Save a registry branch to a file
*/
1748 obj_handle_t hkey
; /* key to save
*/
1749 obj_handle_t file
; /* file to save to
*/
1753 /* Add a registry key change notification
*/
1754 @
REQ(set_registry_notification
)
1755 obj_handle_t hkey
; /* key to watch for changes
*/
1756 obj_handle_t event
; /* event to set
*/
1757 int subtree
; /* should we watch the whole subtree?
*/
1758 unsigned int filter
; /* things to watch
*/
1762 /* Create a waitable timer
*/
1764 unsigned int access
; /* wanted access rights
*/
1765 unsigned int attributes
; /* object attributes
*/
1766 obj_handle_t rootdir
; /* root directory
*/
1767 int manual
; /* manual reset
*/
1768 VARARG(name
,unicode_str
); /* object name
*/
1770 obj_handle_t handle
; /* handle to the timer
*/
1774 /* Open a waitable timer
*/
1776 unsigned int access
; /* wanted access rights
*/
1777 unsigned int attributes
; /* object attributes
*/
1778 obj_handle_t rootdir
; /* root directory
*/
1779 VARARG(name
,unicode_str
); /* object name
*/
1781 obj_handle_t handle
; /* handle to the timer
*/
1784 /* Set a waitable timer
*/
1786 obj_handle_t handle
; /* handle to the timer
*/
1787 timeout_t expire
; /* next expiration absolute time
*/
1788 client_ptr_t callback
; /* callback function
*/
1789 client_ptr_t arg
; /* callback argument
*/
1790 int period
; /* timer period in ms
*/
1792 int signaled
; /* was the timer signaled before this call ?
*/
1795 /* Cancel a waitable timer
*/
1797 obj_handle_t handle
; /* handle to the timer
*/
1799 int signaled
; /* was the timer signaled before this calltime ?
*/
1802 /* Get information on a waitable timer
*/
1803 @
REQ(get_timer_info
)
1804 obj_handle_t handle
; /* handle to the timer
*/
1806 timeout_t when
; /* absolute time when the timer next expires
*/
1807 int signaled
; /* is the timer signaled?
*/
1811 /* Retrieve the current context of a thread
*/
1812 @
REQ(get_thread_context
)
1813 obj_handle_t handle
; /* thread handle
*/
1814 unsigned int flags
; /* context flags
*/
1815 int suspend
; /* if getting context during suspend
*/
1817 int self
; /* was it a handle to the current thread?
*/
1818 VARARG(context
,context
); /* thread context
*/
1822 /* Set the current context of a thread
*/
1823 @
REQ(set_thread_context
)
1824 obj_handle_t handle
; /* thread handle
*/
1825 int suspend
; /* if setting context during suspend
*/
1826 VARARG(context
,context
); /* thread context
*/
1828 int self
; /* was it a handle to the current thread?
*/
1832 /* Fetch a selector entry for a thread
*/
1833 @
REQ(get_selector_entry
)
1834 obj_handle_t handle
; /* thread handle
*/
1835 int entry
; /* LDT entry
*/
1837 unsigned int base
; /* selector base
*/
1838 unsigned int limit
; /* selector limit
*/
1839 unsigned char flags
; /* selector flags
*/
1845 obj_handle_t table
; /* which table to add atom to
*/
1846 VARARG(name
,unicode_str
); /* atom name
*/
1848 atom_t atom
; /* resulting atom
*/
1852 /* Delete an atom
*/
1854 obj_handle_t table
; /* which table to delete atom from
*/
1855 atom_t atom
; /* atom handle
*/
1861 obj_handle_t table
; /* which table to find atom from
*/
1862 VARARG(name
,unicode_str
); /* atom name
*/
1864 atom_t atom
; /* atom handle
*/
1868 /* Get information about an atom
*/
1869 @
REQ(get_atom_information
)
1870 obj_handle_t table
; /* which table to find atom from
*/
1871 atom_t atom
; /* atom handle
*/
1873 int count
; /* atom lock count
*/
1874 int pinned
; /* whether the atom has been pinned
*/
1875 data_size_t total
; /* actual length of atom name
*/
1876 VARARG(name
,unicode_str
); /* atom name
*/
1880 /* Set information about an atom
*/
1881 @
REQ(set_atom_information
)
1882 obj_handle_t table
; /* which table to find atom from
*/
1883 atom_t atom
; /* atom handle
*/
1884 int pinned
; /* whether to bump atom information
*/
1888 /* Empty an atom table
*/
1889 @
REQ(empty_atom_table
)
1890 obj_handle_t table
; /* which table to find atom from
*/
1891 int if_pinned
; /* whether to delete pinned atoms
*/
1895 /* Init an atom table
*/
1896 @
REQ(init_atom_table
)
1897 int entries
; /* number of
entries (only for local
) */
1899 obj_handle_t table
; /* handle to the atom table
*/
1903 /* Get the message queue of the current thread
*/
1906 obj_handle_t handle
; /* handle to the queue
*/
1910 /* Set the file descriptor associated to the current thread queue
*/
1912 obj_handle_t handle
; /* handle to the file descriptor
*/
1916 /* Set the current message queue wakeup mask
*/
1917 @
REQ(set_queue_mask
)
1918 unsigned int wake_mask
; /* wakeup bits mask
*/
1919 unsigned int changed_mask
; /* changed bits mask
*/
1920 int skip_wait
; /* will we skip waiting if signaled?
*/
1922 unsigned int wake_bits
; /* current wake bits
*/
1923 unsigned int changed_bits
; /* current changed bits
*/
1927 /* Get the current message queue status
*/
1928 @
REQ(get_queue_status
)
1929 int clear
; /* should we clear the change bits?
*/
1931 unsigned int wake_bits
; /* wake bits
*/
1932 unsigned int changed_bits
; /* changed bits since last time
*/
1936 /* Retrieve the process idle event
*/
1937 @
REQ(get_process_idle_event
)
1938 obj_handle_t handle
; /* process handle
*/
1940 obj_handle_t event
; /* handle to idle event
*/
1944 /* Send a message to a thread queue
*/
1946 thread_id_t id
; /* thread id
*/
1947 int type
; /* message
type (see below
) */
1948 int flags
; /* message
flags (see below
) */
1949 user_handle_t win
; /* window handle
*/
1950 unsigned int msg
; /* message code
*/
1951 lparam_t wparam
; /* parameters
*/
1952 lparam_t lparam
; /* parameters
*/
1953 timeout_t timeout
; /* timeout for reply
*/
1954 VARARG(data
,message_data
); /* message data for sent messages
*/
1957 @
REQ(post_quit_message
)
1958 int exit_code
; /* exit code to return
*/
1963 MSG_ASCII
, /* Ascii
message (from SendMessageA
) */
1964 MSG_UNICODE
, /* Unicode
message (from SendMessageW
) */
1965 MSG_NOTIFY
, /* notify
message (from SendNotifyMessageW
), always Unicode
*/
1966 MSG_CALLBACK
, /* callback
message (from SendMessageCallbackW
), always Unicode
*/
1967 MSG_CALLBACK_RESULT
,/* result of a callback message
*/
1968 MSG_OTHER_PROCESS
, /* sent from other process
, may include vararg data
, always Unicode
*/
1969 MSG_POSTED
, /* posted
message (from PostMessageW
), always Unicode
*/
1970 MSG_HARDWARE
, /* hardware message
*/
1971 MSG_WINEVENT
/* winevent message
*/
1973 #define SEND_MSG_ABORT_IF_HUNG
0x01
1976 /* Send a hardware message to a thread queue
*/
1977 @
REQ(send_hardware_message
)
1978 thread_id_t id
; /* thread id
*/
1979 user_handle_t win
; /* window handle
*/
1980 unsigned int msg
; /* message code
*/
1981 lparam_t wparam
; /* parameters
*/
1982 lparam_t lparam
; /* parameters
*/
1983 lparam_t info
; /* extra info
*/
1984 int x
; /* x position
*/
1985 int y
; /* y position
*/
1986 unsigned int time
; /* message time
*/
1990 /* Get a message from the current queue
*/
1992 unsigned int flags
; /* PM_
* flags
*/
1993 user_handle_t get_win
; /* window handle to get
*/
1994 unsigned int get_first
; /* first message code to get
*/
1995 unsigned int get_last
; /* last message code to get
*/
1996 unsigned int hw_id
; /* id of the previous hardware
message (or
0) */
1997 unsigned int wake_mask
; /* wakeup bits mask
*/
1998 unsigned int changed_mask
; /* changed bits mask
*/
2000 user_handle_t win
; /* window handle
*/
2001 unsigned int msg
; /* message code
*/
2002 lparam_t wparam
; /* parameters
*/
2003 lparam_t lparam
; /* parameters
*/
2004 int type
; /* message type
*/
2005 unsigned int time
; /* message time
*/
2006 unsigned int active_hooks
; /* active hooks bitmap
*/
2007 data_size_t total
; /* total size of extra data
*/
2008 VARARG(data
,message_data
); /* message data for sent messages
*/
2012 /* Reply to a sent message
*/
2014 int remove
; /* should we remove the message?
*/
2015 lparam_t result
; /* message result
*/
2016 VARARG(data
,bytes
); /* message data for sent messages
*/
2020 /* Accept the current hardware message
*/
2021 @
REQ(accept_hardware_message
)
2022 unsigned int hw_id
; /* id of the hardware message
*/
2023 int remove
; /* should we remove the message?
*/
2024 user_handle_t new_win
; /* new destination window for current message
*/
2028 /* Retrieve the reply for the last message sent
*/
2029 @
REQ(get_message_reply
)
2030 int cancel
; /* cancel message if not ready?
*/
2032 lparam_t result
; /* message result
*/
2033 VARARG(data
,bytes
); /* message data for sent messages
*/
2037 /* Set a window timer
*/
2039 user_handle_t win
; /* window handle
*/
2040 unsigned int msg
; /* message to post
*/
2041 unsigned int rate
; /* timer rate in ms
*/
2042 lparam_t id
; /* timer id
*/
2043 lparam_t lparam
; /* message
lparam (callback proc
) */
2045 lparam_t id
; /* timer id
*/
2049 /* Kill a window timer
*/
2050 @
REQ(kill_win_timer
)
2051 user_handle_t win
; /* window handle
*/
2052 lparam_t id
; /* timer id
*/
2053 unsigned int msg
; /* message to post
*/
2057 /* check if the thread owning the window is hung
*/
2058 @
REQ(is_window_hung
)
2059 user_handle_t win
; /* window handle
*/
2065 /* Retrieve info about a serial port
*/
2066 @
REQ(get_serial_info
)
2067 obj_handle_t handle
; /* handle to comm port
*/
2069 unsigned int readinterval
;
2070 unsigned int readconst
;
2071 unsigned int readmult
;
2072 unsigned int writeconst
;
2073 unsigned int writemult
;
2074 unsigned int eventmask
;
2078 /* Set info about a serial port
*/
2079 @
REQ(set_serial_info
)
2080 obj_handle_t handle
; /* handle to comm port
*/
2081 int flags
; /* bitmask to set
values (see below
) */
2082 unsigned int readinterval
;
2083 unsigned int readconst
;
2084 unsigned int readmult
;
2085 unsigned int writeconst
;
2086 unsigned int writemult
;
2087 unsigned int eventmask
;
2089 #define SERIALINFO_SET_TIMEOUTS
0x01
2090 #define SERIALINFO_SET_MASK
0x02
2093 /* Create an async I
/O
*/
2094 @
REQ(register_async
)
2095 int type
; /* type of queue to look after
*/
2096 async_data_t async
; /* async I
/O parameters
*/
2097 int count
; /* count
- usually # of bytes to be read
/written
*/
2099 #define ASYNC_TYPE_READ
0x01
2100 #define ASYNC_TYPE_WRITE
0x02
2101 #define ASYNC_TYPE_WAIT
0x03
2104 /* Cancel all async op on a fd
*/
2106 obj_handle_t handle
; /* handle to comm port
, socket or file
*/
2107 client_ptr_t iosb
; /* I
/O status
block (NULL
=all
) */
2108 int only_thread
; /* cancel matching this thread
*/
2112 /* Perform an ioctl on a file
*/
2114 ioctl_code_t code
; /* ioctl code
*/
2115 async_data_t async
; /* async I
/O parameters
*/
2116 int blocking
; /* whether it
's a blocking ioctl */
2117 VARARG(in_data,bytes); /* ioctl input data */
2119 obj_handle_t wait; /* handle to wait on for blocking ioctl */
2120 unsigned int options; /* device open options */
2121 VARARG(out_data,bytes); /* ioctl output data */
2125 /* Retrieve results of an async ioctl */
2126 @REQ(get_ioctl_result)
2127 obj_handle_t handle; /* handle to the device */
2128 client_ptr_t user_arg; /* user arg used to identify the request */
2130 VARARG(out_data,bytes); /* ioctl output data */
2134 /* Create a named pipe */
2135 @REQ(create_named_pipe)
2136 unsigned int access;
2137 unsigned int attributes; /* object attributes */
2138 obj_handle_t rootdir; /* root directory */
2139 unsigned int options;
2140 unsigned int maxinstances;
2141 unsigned int outsize;
2142 unsigned int insize;
2145 VARARG(name,unicode_str); /* pipe name */
2147 obj_handle_t handle; /* handle to the pipe */
2150 /* flags in create_named_pipe and get_named_pipe_info */
2151 #define NAMED_PIPE_MESSAGE_STREAM_WRITE 0x0001
2152 #define NAMED_PIPE_MESSAGE_STREAM_READ 0x0002
2153 #define NAMED_PIPE_NONBLOCKING_MODE 0x0004
2154 #define NAMED_PIPE_SERVER_END 0x8000
2157 @REQ(get_named_pipe_info)
2158 obj_handle_t handle;
2161 unsigned int maxinstances;
2162 unsigned int instances;
2163 unsigned int outsize;
2164 unsigned int insize;
2168 /* Create a window */
2170 user_handle_t parent; /* parent window */
2171 user_handle_t owner; /* owner window */
2172 atom_t atom; /* class atom */
2173 mod_handle_t instance; /* module instance */
2174 VARARG(class,unicode_str); /* class name */
2176 user_handle_t handle; /* created window */
2177 user_handle_t parent; /* full handle of parent */
2178 user_handle_t owner; /* full handle of owner */
2179 int extra; /* number of extra bytes */
2180 client_ptr_t class_ptr; /* pointer to class in client address space */
2184 /* Destroy a window */
2185 @REQ(destroy_window)
2186 user_handle_t handle; /* handle to the window */
2190 /* Retrieve the desktop window for the current thread */
2191 @REQ(get_desktop_window)
2192 int force; /* force creation if it doesn't exist
*/
2194 user_handle_t top_window
; /* handle to the desktop window
*/
2195 user_handle_t msg_window
; /* handle to the top
-level HWND_MESSAGE parent
*/
2199 /* Set a window owner
*/
2200 @
REQ(set_window_owner
)
2201 user_handle_t handle
; /* handle to the window
*/
2202 user_handle_t owner
; /* new owner
*/
2204 user_handle_t full_owner
; /* full handle of new owner
*/
2205 user_handle_t prev_owner
; /* full handle of previous owner
*/
2209 /* Get information from a window handle
*/
2210 @
REQ(get_window_info
)
2211 user_handle_t handle
; /* handle to the window
*/
2213 user_handle_t full_handle
; /* full
32-bit handle
*/
2214 user_handle_t last_active
; /* last active popup
*/
2215 process_id_t pid
; /* process owning the window
*/
2216 thread_id_t tid
; /* thread owning the window
*/
2217 atom_t atom
; /* class atom
*/
2218 int is_unicode
; /* ANSI or unicode
*/
2222 /* Set some information in a window
*/
2223 @
REQ(set_window_info
)
2224 unsigned short flags
; /* flags for fields to
set (see below
) */
2225 short int is_unicode
; /* ANSI or unicode
*/
2226 user_handle_t handle
; /* handle to the window
*/
2227 unsigned int style
; /* window style
*/
2228 unsigned int ex_style
; /* window extended style
*/
2229 unsigned int id
; /* window id
*/
2230 mod_handle_t instance
; /* creator instance
*/
2231 lparam_t user_data
; /* user
-specific data
*/
2232 int extra_offset
; /* offset to set in extra bytes
*/
2233 data_size_t extra_size
; /* size to set in extra bytes
*/
2234 lparam_t extra_value
; /* value to set in extra bytes
*/
2236 unsigned int old_style
; /* old window style
*/
2237 unsigned int old_ex_style
; /* old window extended style
*/
2238 mod_handle_t old_instance
; /* old creator instance
*/
2239 lparam_t old_user_data
; /* old user
-specific data
*/
2240 lparam_t old_extra_value
; /* old value in extra bytes
*/
2241 unsigned int old_id
; /* old window id
*/
2243 #define SET_WIN_STYLE
0x01
2244 #define SET_WIN_EXSTYLE
0x02
2245 #define SET_WIN_ID
0x04
2246 #define SET_WIN_INSTANCE
0x08
2247 #define SET_WIN_USERDATA
0x10
2248 #define SET_WIN_EXTRA
0x20
2249 #define SET_WIN_UNICODE
0x40
2252 /* Set the parent of a window
*/
2254 user_handle_t handle
; /* handle to the window
*/
2255 user_handle_t parent
; /* handle to the parent
*/
2257 user_handle_t old_parent
; /* old parent window
*/
2258 user_handle_t full_parent
; /* full handle of new parent
*/
2262 /* Get a list of the window parents
, up to the root of the tree
*/
2263 @
REQ(get_window_parents
)
2264 user_handle_t handle
; /* handle to the window
*/
2266 int count
; /* total count of parents
*/
2267 VARARG(parents
,user_handles
); /* parent handles
*/
2271 /* Get a list of the window children
*/
2272 @
REQ(get_window_children
)
2273 obj_handle_t desktop
; /* handle to desktop
*/
2274 user_handle_t parent
; /* parent window
*/
2275 atom_t atom
; /* class atom for the listed children
*/
2276 thread_id_t tid
; /* thread owning the listed children
*/
2277 VARARG(class
,unicode_str
); /* class name
*/
2279 int count
; /* total count of children
*/
2280 VARARG(children
,user_handles
); /* children handles
*/
2284 /* Get a list of the window children that contain a given point
*/
2285 @
REQ(get_window_children_from_point
)
2286 user_handle_t parent
; /* parent window
*/
2287 int x
; /* point in parent coordinates
*/
2290 int count
; /* total count of children
*/
2291 VARARG(children
,user_handles
); /* children handles
*/
2295 /* Get window tree information from a window handle
*/
2296 @
REQ(get_window_tree
)
2297 user_handle_t handle
; /* handle to the window
*/
2299 user_handle_t parent
; /* parent window
*/
2300 user_handle_t owner
; /* owner window
*/
2301 user_handle_t next_sibling
; /* next sibling in Z
-order
*/
2302 user_handle_t prev_sibling
; /* prev sibling in Z
-order
*/
2303 user_handle_t first_sibling
; /* first sibling in Z
-order
*/
2304 user_handle_t last_sibling
; /* last sibling in Z
-order
*/
2305 user_handle_t first_child
; /* first child
*/
2306 user_handle_t last_child
; /* last child
*/
2309 /* Set the position and Z order of a window
*/
2310 @
REQ(set_window_pos
)
2311 unsigned int flags
; /* SWP_
* flags
*/
2312 user_handle_t handle
; /* handle to the window
*/
2313 user_handle_t previous
; /* previous window in Z order
*/
2314 rectangle_t window
; /* window rectangle
*/
2315 rectangle_t client
; /* client rectangle
*/
2316 VARARG(valid
,rectangles
); /* valid rectangles from WM_NCCALCSIZE
*/
2318 unsigned int new_style
; /* new window style
*/
2319 unsigned int new_ex_style
; /* new window extended style
*/
2323 /* Get the window and client rectangles of a window
*/
2324 @
REQ(get_window_rectangles
)
2325 user_handle_t handle
; /* handle to the window
*/
2327 rectangle_t window
; /* window rectangle
*/
2328 rectangle_t visible
; /* visible part of the window rectangle
*/
2329 rectangle_t client
; /* client rectangle
*/
2333 /* Get the window text
*/
2334 @
REQ(get_window_text
)
2335 user_handle_t handle
; /* handle to the window
*/
2337 VARARG(text
,unicode_str
); /* window text
*/
2341 /* Set the window text
*/
2342 @
REQ(set_window_text
)
2343 user_handle_t handle
; /* handle to the window
*/
2344 VARARG(text
,unicode_str
); /* window text
*/
2348 /* Get the coordinates offset between two windows
*/
2349 @
REQ(get_windows_offset
)
2350 user_handle_t from
; /* handle to the first window
*/
2351 user_handle_t to
; /* handle to the second window
*/
2353 int x
; /* x coordinate offset
*/
2354 int y
; /* y coordinate offset
*/
2358 /* Get the visible region of a window
*/
2359 @
REQ(get_visible_region
)
2360 user_handle_t window
; /* handle to the window
*/
2361 unsigned int flags
; /* DCX flags
*/
2363 user_handle_t top_win
; /* top window to clip against
*/
2364 rectangle_t top_rect
; /* top window visible rect with screen coords
*/
2365 rectangle_t win_rect
; /* window rect in screen coords
*/
2366 data_size_t total_size
; /* total size of the resulting region
*/
2367 VARARG(region
,rectangles
); /* list of rectangles for the
region (in screen coords
) */
2371 /* Get the window region
*/
2372 @
REQ(get_window_region
)
2373 user_handle_t window
; /* handle to the window
*/
2375 data_size_t total_size
; /* total size of the resulting region
*/
2376 VARARG(region
,rectangles
); /* list of rectangles for the region
*/
2380 /* Set the window region
*/
2381 @
REQ(set_window_region
)
2382 user_handle_t window
; /* handle to the window
*/
2383 int redraw
; /* redraw the window?
*/
2384 VARARG(region
,rectangles
); /* list of rectangles for the region
*/
2388 /* Get the window update region
*/
2389 @
REQ(get_update_region
)
2390 user_handle_t window
; /* handle to the window
*/
2391 user_handle_t from_child
; /* child to start searching from
*/
2392 unsigned int flags
; /* update
flags (see below
) */
2394 user_handle_t child
; /* child to
repaint (or window itself
) */
2395 unsigned int flags
; /* resulting update
flags (see below
) */
2396 data_size_t total_size
; /* total size of the resulting region
*/
2397 VARARG(region
,rectangles
); /* list of rectangles for the region
*/
2399 #define UPDATE_NONCLIENT
0x01 /* get region for repainting non
-client area
*/
2400 #define UPDATE_ERASE
0x02 /* get region for erasing client area
*/
2401 #define UPDATE_PAINT
0x04 /* get region for painting client area
*/
2402 #define UPDATE_INTERNALPAINT
0x08 /* get region if internal paint is pending
*/
2403 #define UPDATE_ALLCHILDREN
0x10 /* force repaint of all children
*/
2404 #define UPDATE_NOCHILDREN
0x20 /* don
't try to repaint any children */
2405 #define UPDATE_NOREGION 0x40 /* don't return a region
, only the flags
*/
2406 #define UPDATE_DELAYED_ERASE
0x80 /* still needs erase after BeginPaint
*/
2409 /* Update the z order of a window so that a given rectangle is fully visible
*/
2410 @
REQ(update_window_zorder
)
2411 user_handle_t window
; /* handle to the window
*/
2412 rectangle_t rect
; /* rectangle that must be visible
*/
2416 /* Mark parts of a window as needing a redraw
*/
2418 user_handle_t window
; /* handle to the window
*/
2419 unsigned int flags
; /* RDW_
* flags
*/
2420 VARARG(region
,rectangles
); /* list of rectangles for the region
*/
2424 /* Set a window property
*/
2425 @
REQ(set_window_property
)
2426 user_handle_t window
; /* handle to the window
*/
2427 lparam_t data
; /* data to store
*/
2428 atom_t atom
; /* property
atom (if no name specified
) */
2429 VARARG(name
,unicode_str
); /* property name
*/
2433 /* Remove a window property
*/
2434 @
REQ(remove_window_property
)
2435 user_handle_t window
; /* handle to the window
*/
2436 atom_t atom
; /* property
atom (if no name specified
) */
2437 VARARG(name
,unicode_str
); /* property name
*/
2439 lparam_t data
; /* data stored in property
*/
2443 /* Get a window property
*/
2444 @
REQ(get_window_property
)
2445 user_handle_t window
; /* handle to the window
*/
2446 atom_t atom
; /* property
atom (if no name specified
) */
2447 VARARG(name
,unicode_str
); /* property name
*/
2449 lparam_t data
; /* data stored in property
*/
2453 /* Get the list of properties of a window
*/
2454 @
REQ(get_window_properties
)
2455 user_handle_t window
; /* handle to the window
*/
2457 int total
; /* total number of properties
*/
2458 VARARG(props
,properties
); /* list of properties
*/
2462 /* Create a window station
*/
2463 @
REQ(create_winstation
)
2464 unsigned int flags
; /* window station flags
*/
2465 unsigned int access
; /* wanted access rights
*/
2466 unsigned int attributes
; /* object attributes
*/
2467 VARARG(name
,unicode_str
); /* object name
*/
2469 obj_handle_t handle
; /* handle to the window station
*/
2473 /* Open a handle to a window station
*/
2474 @
REQ(open_winstation
)
2475 unsigned int access
; /* wanted access rights
*/
2476 unsigned int attributes
; /* object attributes
*/
2477 VARARG(name
,unicode_str
); /* object name
*/
2479 obj_handle_t handle
; /* handle to the window station
*/
2483 /* Close a window station
*/
2484 @
REQ(close_winstation
)
2485 obj_handle_t handle
; /* handle to the window station
*/
2489 /* Get the process current window station
*/
2490 @
REQ(get_process_winstation
)
2492 obj_handle_t handle
; /* handle to the window station
*/
2496 /* Set the process current window station
*/
2497 @
REQ(set_process_winstation
)
2498 obj_handle_t handle
; /* handle to the window station
*/
2502 /* Enumerate window stations
*/
2503 @
REQ(enum_winstation
)
2504 unsigned int index
; /* current index
*/
2506 unsigned int next
; /* next index
*/
2507 VARARG(name
,unicode_str
); /* window station name
*/
2511 /* Create a desktop
*/
2512 @
REQ(create_desktop
)
2513 unsigned int flags
; /* desktop flags
*/
2514 unsigned int access
; /* wanted access rights
*/
2515 unsigned int attributes
; /* object attributes
*/
2516 VARARG(name
,unicode_str
); /* object name
*/
2518 obj_handle_t handle
; /* handle to the desktop
*/
2522 /* Open a handle to a desktop
*/
2524 obj_handle_t winsta
; /* window station to
open (null allowed
) */
2525 unsigned int flags
; /* desktop flags
*/
2526 unsigned int access
; /* wanted access rights
*/
2527 unsigned int attributes
; /* object attributes
*/
2528 VARARG(name
,unicode_str
); /* object name
*/
2530 obj_handle_t handle
; /* handle to the desktop
*/
2534 /* Close a desktop
*/
2536 obj_handle_t handle
; /* handle to the desktop
*/
2540 /* Get the thread current desktop
*/
2541 @
REQ(get_thread_desktop
)
2542 thread_id_t tid
; /* thread id
*/
2544 obj_handle_t handle
; /* handle to the desktop
*/
2548 /* Set the thread current desktop
*/
2549 @
REQ(set_thread_desktop
)
2550 obj_handle_t handle
; /* handle to the desktop
*/
2554 /* Enumerate desktops
*/
2556 obj_handle_t winstation
; /* handle to the window station
*/
2557 unsigned int index
; /* current index
*/
2559 unsigned int next
; /* next index
*/
2560 VARARG(name
,unicode_str
); /* window station name
*/
2564 /* Get
/set information about a user
object (window station or desktop
) */
2565 @
REQ(set_user_object_info
)
2566 obj_handle_t handle
; /* handle to the object
*/
2567 unsigned int flags
; /* information to set
*/
2568 unsigned int obj_flags
; /* new object flags
*/
2570 int is_desktop
; /* is object a desktop?
*/
2571 unsigned int old_obj_flags
; /* old object flags
*/
2572 VARARG(name
,unicode_str
); /* object name
*/
2574 #define SET_USER_OBJECT_FLAGS
1
2577 /* Attach (or detach
) thread inputs
*/
2578 @
REQ(attach_thread_input
)
2579 thread_id_t tid_from
; /* thread to be attached
*/
2580 thread_id_t tid_to
; /* thread to which tid_from should be attached
*/
2581 int attach
; /* is it an attach?
*/
2585 /* Get input data for a given thread
*/
2586 @
REQ(get_thread_input
)
2587 thread_id_t tid
; /* id of thread
*/
2589 user_handle_t focus
; /* handle to the focus window
*/
2590 user_handle_t capture
; /* handle to the capture window
*/
2591 user_handle_t active
; /* handle to the active window
*/
2592 user_handle_t foreground
; /* handle to the global foreground window
*/
2593 user_handle_t menu_owner
; /* handle to the menu owner
*/
2594 user_handle_t move_size
; /* handle to the moving
/resizing window
*/
2595 user_handle_t caret
; /* handle to the caret window
*/
2596 rectangle_t rect
; /* caret rectangle
*/
2600 /* Get the time of the last input event
*/
2601 @
REQ(get_last_input_time
)
2607 /* Retrieve queue keyboard state for a given thread
*/
2609 thread_id_t tid
; /* id of thread
*/
2610 int key
; /* optional key code or
-1 */
2612 unsigned char state
; /* state of specified key
*/
2613 VARARG(keystate
,bytes
); /* state array for all the keys
*/
2616 /* Set queue keyboard state for a given thread
*/
2618 thread_id_t tid
; /* id of thread
*/
2619 VARARG(keystate
,bytes
); /* state array for all the keys
*/
2622 /* Set the system foreground window
*/
2623 @
REQ(set_foreground_window
)
2624 user_handle_t handle
; /* handle to the foreground window
*/
2626 user_handle_t previous
; /* handle to the previous foreground window
*/
2627 int send_msg_old
; /* whether we have to send a msg to the old window
*/
2628 int send_msg_new
; /* whether we have to send a msg to the new window
*/
2631 /* Set the current thread focus window
*/
2632 @
REQ(set_focus_window
)
2633 user_handle_t handle
; /* handle to the focus window
*/
2635 user_handle_t previous
; /* handle to the previous focus window
*/
2638 /* Set the current thread active window
*/
2639 @
REQ(set_active_window
)
2640 user_handle_t handle
; /* handle to the active window
*/
2642 user_handle_t previous
; /* handle to the previous active window
*/
2645 /* Set the current thread capture window
*/
2646 @
REQ(set_capture_window
)
2647 user_handle_t handle
; /* handle to the capture window
*/
2648 unsigned int flags
; /* capture
flags (see below
) */
2650 user_handle_t previous
; /* handle to the previous capture window
*/
2651 user_handle_t full_handle
; /* full
32-bit handle of new capture window
*/
2653 #define CAPTURE_MENU
0x01 /* capture is for a menu
*/
2654 #define CAPTURE_MOVESIZE
0x02 /* capture is for moving
/resizing
*/
2657 /* Set the current thread caret window
*/
2658 @
REQ(set_caret_window
)
2659 user_handle_t handle
; /* handle to the caret window
*/
2660 int width
; /* caret width
*/
2661 int height
; /* caret height
*/
2663 user_handle_t previous
; /* handle to the previous caret window
*/
2664 rectangle_t old_rect
; /* previous caret rectangle
*/
2665 int old_hide
; /* previous hide count
*/
2666 int old_state
; /* previous caret
state (1=on
, 0=off
) */
2670 /* Set the current thread caret information
*/
2671 @
REQ(set_caret_info
)
2672 unsigned int flags
; /* caret
flags (see below
) */
2673 user_handle_t handle
; /* handle to the caret window
*/
2674 int x
; /* caret x position
*/
2675 int y
; /* caret y position
*/
2676 int hide
; /* increment for hide
count (can be negative to show it
) */
2677 int state
; /* caret
state (1=on
, 0=off
, -1=toggle current state
) */
2679 user_handle_t full_handle
; /* handle to the current caret window
*/
2680 rectangle_t old_rect
; /* previous caret rectangle
*/
2681 int old_hide
; /* previous hide count
*/
2682 int old_state
; /* previous caret
state (1=on
, 0=off
) */
2684 #define SET_CARET_POS
0x01 /* set the caret position from x
,y
*/
2685 #define SET_CARET_HIDE
0x02 /* increment the caret hide count
*/
2686 #define SET_CARET_STATE
0x04 /* set the caret on
/off state
*/
2689 /* Set a window hook
*/
2691 int id
; /* id of the hook
*/
2692 process_id_t pid
; /* id of process to set the hook into
*/
2693 thread_id_t tid
; /* id of thread to set the hook into
*/
2696 client_ptr_t proc
; /* hook procedure
*/
2698 int unicode
; /* is it a unicode hook?
*/
2699 VARARG(module
,unicode_str
); /* module name
*/
2701 user_handle_t handle
; /* handle to the hook
*/
2702 unsigned int active_hooks
; /* active hooks bitmap
*/
2706 /* Remove a window hook
*/
2708 user_handle_t handle
; /* handle to the hook
*/
2709 client_ptr_t proc
; /* hook procedure if handle is
0 */
2710 int id
; /* id of the hook if handle is
0 */
2712 unsigned int active_hooks
; /* active hooks bitmap
*/
2716 /* Start calling a hook chain
*/
2717 @
REQ(start_hook_chain
)
2718 int id
; /* id of the hook
*/
2719 int event
; /* signalled event
*/
2720 user_handle_t window
; /* handle to the event window
*/
2721 int object_id
; /* object id for out of context winevent
*/
2722 int child_id
; /* child id for out of context winevent
*/
2724 user_handle_t handle
; /* handle to the next hook
*/
2725 process_id_t pid
; /* process id for low
-level keyboard
/mouse hooks
*/
2726 thread_id_t tid
; /* thread id for low
-level keyboard
/mouse hooks
*/
2727 int unicode
; /* is it a unicode hook?
*/
2728 client_ptr_t proc
; /* hook procedure
*/
2729 unsigned int active_hooks
; /* active hooks bitmap
*/
2730 VARARG(module
,unicode_str
); /* module name
*/
2734 /* Finished calling a hook chain
*/
2735 @
REQ(finish_hook_chain
)
2736 int id
; /* id of the hook
*/
2740 /* Get the hook information
*/
2742 user_handle_t handle
; /* handle to the current hook
*/
2743 int get_next
; /* do we want info about current or next hook?
*/
2744 int event
; /* signalled event
*/
2745 user_handle_t window
; /* handle to the event window
*/
2746 int object_id
; /* object id for out of context winevent
*/
2747 int child_id
; /* child id for out of context winevent
*/
2749 user_handle_t handle
; /* handle to the hook
*/
2750 int id
; /* id of the hook
*/
2751 process_id_t pid
; /* process id for low
-level keyboard
/mouse hooks
*/
2752 thread_id_t tid
; /* thread id for low
-level keyboard
/mouse hooks
*/
2753 client_ptr_t proc
; /* hook procedure
*/
2754 int unicode
; /* is it a unicode hook?
*/
2755 VARARG(module
,unicode_str
); /* module name
*/
2759 /* Create a window class
*/
2761 int local
; /* is it a local class?
*/
2762 atom_t atom
; /* class atom
*/
2763 unsigned int style
; /* class style
*/
2764 mod_handle_t instance
; /* module instance
*/
2765 int extra
; /* number of extra class bytes
*/
2766 int win_extra
; /* number of window extra bytes
*/
2767 client_ptr_t client_ptr
; /* pointer to class in client address space
*/
2768 VARARG(name
,unicode_str
); /* class name
*/
2770 atom_t atom
; /* resulting class atom
*/
2774 /* Destroy a window class
*/
2776 atom_t atom
; /* class atom
*/
2777 mod_handle_t instance
; /* module instance
*/
2778 VARARG(name
,unicode_str
); /* class name
*/
2780 client_ptr_t client_ptr
; /* pointer to class in client address space
*/
2784 /* Set some information in a class
*/
2785 @
REQ(set_class_info
)
2786 user_handle_t window
; /* handle to the window
*/
2787 unsigned int flags
; /* flags for info to
set (see below
) */
2788 atom_t atom
; /* class atom
*/
2789 unsigned int style
; /* class style
*/
2790 int win_extra
; /* number of window extra bytes
*/
2791 mod_handle_t instance
; /* module instance
*/
2792 int extra_offset
; /* offset to set in extra bytes
*/
2793 data_size_t extra_size
; /* size to set in extra bytes
*/
2794 lparam_t extra_value
; /* value to set in extra bytes
*/
2796 atom_t old_atom
; /* previous class atom
*/
2797 unsigned int old_style
; /* previous class style
*/
2798 int old_extra
; /* previous number of class extra bytes
*/
2799 int old_win_extra
; /* previous number of window extra bytes
*/
2800 mod_handle_t old_instance
; /* previous module instance
*/
2801 lparam_t old_extra_value
; /* old value in extra bytes
*/
2803 #define SET_CLASS_ATOM
0x0001
2804 #define SET_CLASS_STYLE
0x0002
2805 #define SET_CLASS_WINEXTRA
0x0004
2806 #define SET_CLASS_INSTANCE
0x0008
2807 #define SET_CLASS_EXTRA
0x0010
2810 /* Set
/get clipboard information
*/
2811 @
REQ(set_clipboard_info
)
2812 unsigned int flags
; /* flags for fields to
set (see below
) */
2813 user_handle_t clipboard
; /* clipboard window
*/
2814 user_handle_t owner
; /* clipboard owner
*/
2815 user_handle_t viewer
; /* first clipboard viewer
*/
2816 unsigned int seqno
; /* change sequence number
*/
2818 unsigned int flags
; /* status
flags (see below
) */
2819 user_handle_t old_clipboard
; /* old clipboard window
*/
2820 user_handle_t old_owner
; /* old clipboard owner
*/
2821 user_handle_t old_viewer
; /* old clipboard viewer
*/
2822 unsigned int seqno
; /* current sequence number
*/
2825 #define SET_CB_OPEN
0x001
2826 #define SET_CB_OWNER
0x002
2827 #define SET_CB_VIEWER
0x004
2828 #define SET_CB_SEQNO
0x008
2829 #define SET_CB_RELOWNER
0x010
2830 #define SET_CB_CLOSE
0x020
2831 #define CB_OPEN
0x040
2832 #define CB_OWNER
0x080
2833 #define CB_PROCESS
0x100
2836 /* Open a security token
*/
2838 obj_handle_t handle
; /* handle to the thread or process
*/
2839 unsigned int access
; /* access rights to the new token
*/
2840 unsigned int attributes
;/* object attributes
*/
2841 unsigned int flags
; /* flags (see below
) */
2843 obj_handle_t token
; /* handle to the token
*/
2845 #define OPEN_TOKEN_THREAD
1
2846 #define OPEN_TOKEN_AS_SELF
2
2849 /* Set
/get the global windows
*/
2850 @
REQ(set_global_windows
)
2851 unsigned int flags
; /* flags for fields to
set (see below
) */
2852 user_handle_t shell_window
; /* handle to the new shell window
*/
2853 user_handle_t shell_listview
; /* handle to the new shell listview window
*/
2854 user_handle_t progman_window
; /* handle to the new program manager window
*/
2855 user_handle_t taskman_window
; /* handle to the new task manager window
*/
2857 user_handle_t old_shell_window
; /* handle to the shell window
*/
2858 user_handle_t old_shell_listview
; /* handle to the shell listview window
*/
2859 user_handle_t old_progman_window
; /* handle to the new program manager window
*/
2860 user_handle_t old_taskman_window
; /* handle to the new task manager window
*/
2862 #define SET_GLOBAL_SHELL_WINDOWS
0x01 /* set both main shell and listview windows
*/
2863 #define SET_GLOBAL_PROGMAN_WINDOW
0x02
2864 #define SET_GLOBAL_TASKMAN_WINDOW
0x04
2866 /* Adjust the privileges held by a token
*/
2867 @
REQ(adjust_token_privileges
)
2868 obj_handle_t handle
; /* handle to the token
*/
2869 int disable_all
; /* disable all privileges?
*/
2870 int get_modified_state
; /* get modified privileges?
*/
2871 VARARG(privileges
,LUID_AND_ATTRIBUTES
); /* privileges to enable
/disable
/remove
*/
2873 unsigned int len
; /* total length in bytes required to store token privileges
*/
2874 VARARG(privileges
,LUID_AND_ATTRIBUTES
); /* modified privileges
*/
2877 /* Retrieves the set of privileges held by or available to a token
*/
2878 @
REQ(get_token_privileges
)
2879 obj_handle_t handle
; /* handle to the token
*/
2881 unsigned int len
; /* total length in bytes required to store token privileges
*/
2882 VARARG(privileges
,LUID_AND_ATTRIBUTES
); /* privileges held by or available to a token
*/
2885 /* Check the token has the required privileges
*/
2886 @
REQ(check_token_privileges
)
2887 obj_handle_t handle
; /* handle to the token
*/
2888 int all_required
; /* are all the privileges required for the check to succeed?
*/
2889 VARARG(privileges
,LUID_AND_ATTRIBUTES
); /* privileges to check
*/
2891 int has_privileges
; /* does the token have the required privileges?
*/
2892 VARARG(privileges
,LUID_AND_ATTRIBUTES
); /* privileges held by or available to a token
*/
2895 @
REQ(duplicate_token
)
2896 obj_handle_t handle
; /* handle to the token to duplicate
*/
2897 unsigned int access
; /* access rights to the new token
*/
2898 unsigned int attributes
; /* object attributes
*/
2899 int primary
; /* is the new token to be a primary one?
*/
2900 int impersonation_level
; /* impersonation level of the new token
*/
2902 obj_handle_t new_handle
; /* duplicated handle
*/
2906 obj_handle_t handle
; /* handle to the token
*/
2907 unsigned int desired_access
; /* desired access to the object
*/
2908 unsigned int mapping_read
; /* mapping from generic read to specific rights
*/
2909 unsigned int mapping_write
; /* mapping from generic write to specific rights
*/
2910 unsigned int mapping_execute
; /* mapping from generic execute to specific rights
*/
2911 unsigned int mapping_all
; /* mapping from generic all to specific rights
*/
2912 VARARG(sd
,security_descriptor
); /* security descriptor to check
*/
2914 unsigned int access_granted
; /* access rights actually granted
*/
2915 unsigned int access_status
; /* was access granted?
*/
2916 unsigned int privileges_len
; /* length needed to store privileges
*/
2917 VARARG(privileges
,LUID_AND_ATTRIBUTES
); /* privileges used during access check
*/
2920 @
REQ(get_token_user
)
2921 obj_handle_t handle
; /* handle to the token
*/
2923 data_size_t user_len
; /* length needed to store user
*/
2924 VARARG(user
,SID
); /* sid of the user the token represents
*/
2927 @
REQ(get_token_groups
)
2928 obj_handle_t handle
; /* handle to the token
*/
2930 data_size_t user_len
; /* length needed to store user
*/
2931 VARARG(user
,token_groups
); /* groups the token
's user belongs to */
2934 @REQ(get_token_default_dacl)
2935 obj_handle_t handle; /* handle to the token */
2937 data_size_t acl_len; /* length needed to store access control list */
2938 VARARG(acl,ACL); /* access control list */
2941 @REQ(set_token_default_dacl)
2942 obj_handle_t handle; /* handle to the token */
2943 VARARG(acl,ACL); /* default dacl to set */
2946 @REQ(set_security_object)
2947 obj_handle_t handle; /* handle to the object */
2948 unsigned int security_info; /* which parts of security descriptor to set */
2949 VARARG(sd,security_descriptor); /* security descriptor to set */
2952 @REQ(get_security_object)
2953 obj_handle_t handle; /* handle to the object */
2954 unsigned int security_info; /* which parts of security descriptor to get */
2956 unsigned int sd_len; /* buffer size needed for sd */
2957 VARARG(sd,security_descriptor); /* retrieved security descriptor */
2960 /* Create a mailslot */
2961 @REQ(create_mailslot)
2962 unsigned int access; /* wanted access rights */
2963 unsigned int attributes; /* object attributes */
2964 obj_handle_t rootdir; /* root directory */
2965 timeout_t read_timeout;
2966 unsigned int max_msgsize;
2967 VARARG(name,unicode_str); /* mailslot name */
2969 obj_handle_t handle; /* handle to the mailslot */
2973 /* Set mailslot information */
2974 @REQ(set_mailslot_info)
2975 obj_handle_t handle; /* handle to the mailslot */
2976 timeout_t read_timeout;
2979 timeout_t read_timeout;
2980 unsigned int max_msgsize;
2982 #define MAILSLOT_SET_READ_TIMEOUT 1
2985 /* Create a directory object */
2986 @REQ(create_directory)
2987 unsigned int access; /* access flags */
2988 unsigned int attributes; /* object attributes */
2989 obj_handle_t rootdir; /* root directory */
2990 VARARG(directory_name,unicode_str); /* Directory name */
2992 obj_handle_t handle; /* handle to the directory */
2996 /* Open a directory object */
2997 @REQ(open_directory)
2998 unsigned int access; /* access flags */
2999 unsigned int attributes; /* object attributes */
3000 obj_handle_t rootdir; /* root directory */
3001 VARARG(directory_name,unicode_str); /* Directory name */
3003 obj_handle_t handle; /* handle to the directory */
3007 /* Get a directory entry by index */
3008 @REQ(get_directory_entry)
3009 obj_handle_t handle; /* handle to the directory */
3010 unsigned int index; /* entry index */
3012 data_size_t name_len; /* length of the entry name in bytes */
3013 VARARG(name,unicode_str,name_len); /* entry name */
3014 VARARG(type,unicode_str); /* entry type */
3018 /* Create a symbolic link object */
3019 @REQ(create_symlink)
3020 unsigned int access; /* access flags */
3021 unsigned int attributes; /* object attributes */
3022 obj_handle_t rootdir; /* root directory */
3023 data_size_t name_len; /* length of the symlink name in bytes */
3024 VARARG(name,unicode_str,name_len); /* symlink name */
3025 VARARG(target_name,unicode_str); /* target name */
3027 obj_handle_t handle; /* handle to the symlink */
3031 /* Open a symbolic link object */
3033 unsigned int access; /* access flags */
3034 unsigned int attributes; /* object attributes */
3035 obj_handle_t rootdir; /* root directory */
3036 VARARG(name,unicode_str); /* symlink name */
3038 obj_handle_t handle; /* handle to the symlink */
3042 /* Query a symbolic link object */
3044 obj_handle_t handle; /* handle to the symlink */
3046 VARARG(target_name,unicode_str); /* target name */
3050 /* Query basic object information */
3051 @REQ(get_object_info)
3052 obj_handle_t handle; /* handle to the object */
3054 unsigned int access; /* granted access mask */
3055 unsigned int ref_count; /* object ref count */
3059 /* Unlink a named object */
3061 obj_handle_t handle; /* handle to the object */
3065 /* Query the impersonation level of an impersonation token */
3066 @REQ(get_token_impersonation_level)
3067 obj_handle_t handle; /* handle to the object */
3069 int impersonation_level; /* impersonation level of the impersonation token */
3072 /* Allocate a locally-unique identifier */
3073 @REQ(allocate_locally_unique_id)
3079 /* Create a device manager */
3080 @REQ(create_device_manager)
3081 unsigned int access; /* wanted access rights */
3082 unsigned int attributes; /* object attributes */
3084 obj_handle_t handle; /* handle to the device */
3088 /* Create a device */
3090 unsigned int access; /* wanted access rights */
3091 unsigned int attributes; /* object attributes */
3092 obj_handle_t rootdir; /* root directory */
3093 client_ptr_t user_ptr; /* opaque ptr for use by client */
3094 obj_handle_t manager; /* device manager */
3095 VARARG(name,unicode_str); /* object name */
3097 obj_handle_t handle; /* handle to the device */
3101 /* Delete a device */
3103 obj_handle_t handle; /* handle to the device */
3107 /* Retrieve the next pending device ioctl request */
3108 @REQ(get_next_device_request)
3109 obj_handle_t manager; /* handle to the device manager */
3110 obj_handle_t prev; /* handle to the previous ioctl */
3111 unsigned int status; /* status of the previous ioctl */
3112 VARARG(prev_data,bytes); /* output data of the previous ioctl */
3114 obj_handle_t next; /* handle to the next ioctl */
3115 ioctl_code_t code; /* ioctl code */
3116 client_ptr_t user_ptr; /* opaque ptr for the device */
3117 data_size_t in_size; /* total needed input size */
3118 data_size_t out_size; /* needed output size */
3119 VARARG(next_data,bytes); /* input data of the next ioctl */
3123 /* Make the current process a system process */
3124 @REQ(make_process_system)
3126 obj_handle_t event; /* event signaled when all user processes have exited */
3130 /* Get detailed fixed-size information about a token */
3131 @REQ(get_token_statistics)
3132 obj_handle_t handle; /* handle to the object */
3134 luid_t token_id; /* locally-unique identifier of the token */
3135 luid_t modified_id; /* locally-unique identifier of the modified version of the token */
3136 int primary; /* is the token primary or impersonation? */
3137 int impersonation_level; /* level of impersonation */
3138 int group_count; /* the number of groups the token is a member of */
3139 int privilege_count; /* the number of privileges the token has */
3143 /* Create I/O completion port */
3144 @REQ(create_completion)
3145 unsigned int access; /* desired access to a port */
3146 unsigned int attributes; /* object attributes */
3147 unsigned int concurrent; /* max number of concurrent active threads */
3148 obj_handle_t rootdir; /* root directory */
3149 VARARG(filename,string); /* port name */
3151 obj_handle_t handle; /* port handle */
3155 /* Open I/O completion port */
3156 @REQ(open_completion)
3157 unsigned int access; /* desired access to a port */
3158 unsigned int attributes; /* object attributes */
3159 obj_handle_t rootdir; /* root directory */
3160 VARARG(filename,string); /* port name */
3162 obj_handle_t handle; /* port handle */
3166 /* add completion to completion port */
3167 @REQ(add_completion)
3168 obj_handle_t handle; /* port handle */
3169 apc_param_t ckey; /* completion key */
3170 apc_param_t cvalue; /* completion value */
3171 unsigned int information; /* IO_STATUS_BLOCK Information */
3172 unsigned int status; /* completion result */
3176 /* get completion from completion port queue */
3177 @REQ(remove_completion)
3178 obj_handle_t handle; /* port handle */
3180 apc_param_t ckey; /* completion key */
3181 apc_param_t cvalue; /* completion value */
3182 unsigned int information; /* IO_STATUS_BLOCK Information */
3183 unsigned int status; /* completion result */
3187 /* get completion queue depth */
3188 @REQ(query_completion)
3189 obj_handle_t handle; /* port handle */
3191 unsigned int depth; /* completion queue depth */
3195 /* associate object with completion port */
3196 @REQ(set_completion_info)
3197 obj_handle_t handle; /* object handle */
3198 apc_param_t ckey; /* completion key */
3199 obj_handle_t chandle; /* port handle */
3203 /* check for associated completion and push msg */
3204 @REQ(add_fd_completion)
3205 obj_handle_t handle; /* async' object
*/
3206 apc_param_t cvalue
; /* completion value
*/
3207 unsigned int status
; /* completion status
*/
3208 unsigned int information
; /* IO_STATUS_BLOCK Information
*/
3212 /* Retrieve layered info for a window
*/
3213 @
REQ(get_window_layered_info
)
3214 user_handle_t handle
; /* handle to the window
*/
3216 unsigned int color_key
; /* color key
*/
3217 unsigned int alpha
; /* alpha (0.
.255) */
3218 unsigned int flags
; /* LWA_
* flags
*/
3222 /* Set layered info for a window
*/
3223 @
REQ(set_window_layered_info
)
3224 user_handle_t handle
; /* handle to the window
*/
3225 unsigned int color_key
; /* color key
*/
3226 unsigned int alpha
; /* alpha (0.
.255) */
3227 unsigned int flags
; /* LWA_
* flags
*/