]> git.saurik.com Git - apple/xnu.git/blame - osfmk/man/mach_rpc_trap.html
xnu-1504.3.12.tar.gz
[apple/xnu.git] / osfmk / man / mach_rpc_trap.html
CommitLineData
13fec989
A
1<h2>mach_rpc_trap</h2>
2<hr>
3<p>
4<strong>System Trap</strong> - Real-Time RPC trap.
5<h3>SYNOPSIS</h3>
6<pre>
7<strong>#include&ltmach/rpc.h&gt</strong>
8
9<strong>mach_rpc_return_t mach_rpc_trap</strong>
10 <strong>(mach_port_t</strong> <var>dest_port</var>,
11 <strong>mach_rpc_id_t</strong> <var>routine_num</var>,
12 <strong>mach_rpc_signature_t</strong> <var>signature_ptr</var>,
13 <strong>mach_rpc_size_t</strong> <var>signature_size</var><strong>);</strong>
14</pre>
15<h3>PARAMETERS</h3>
16<dl>
17<p>
18<dt> <var>dest_port</var>
19<dd>
20[in send right] The port representing the destination of the RPC
21 (usually a registered subsystem established by a call to
22 <strong>mach_port_allocate_subsystem</strong>).
23<p>
24<dt> <var>routine_num</var>
25<dd>
26[in scalar] Identifier of the server work function.
27<p>
28<dt> <var>signature_ptr</var>
29<dd>
30[in pointer] Pointer to the call's <strong>mach_rpc_signature</strong> structure.
31<p>
32<dt> <var>signature_size</var>
33<dd>
34[in scalar] Size, in bytes, of the call's <strong>mach_rpc_signature</strong> structure.
35</dl>
36<h3>DESCRIPTION</h3>
37<p>
38The <strong>mach_rpc_trap</strong> system trap is the entry point for the
39invoke side of the Mach RPC service used to transfer control to an RPC server.
40The trap is accessed via the MIG generated
41<strong>MACH_RPC</strong> macro
42which is invoked transparently when the <strong>mach_rpc</strong> feature is enabled.
43This function is not designed for use directly by the user. It is
44automatically generated by MIG to handle a function call.
45<p>
46For a
47complete description of this functionality, refer to: Burke, Edward,
48Michael Condict, David Mitchell, Franklin Reynolds, Peter Watkins,
49William Willcox, "RPC Design for Real-Time Mach," OSF Research
50Institute, Cambridge, MA.
51<h3>NOTES</h3>
52<p>
53This interface is experimental and therefore subject to change.
54<h3>RETURN VALUES</h3>
55<dl>
56<p>
57<dt> <strong>KERN_FAILURE</strong>
58<dd>
59Either the argument copyin failed, there were too many arguments, or
60the argument copyout failed.
61<p>
62<dt> <strong>KERN_INVALID_ARGUMENT</strong>
63<dd>
64The dest_port, signature_ptr, and/or the subsystem associated with the
65dest_port is invalid; the siganture_size is less than, or equal to, zero.
66<p>
67<dt> <strong>KERN_NO_ACCESS</strong>
68<dd>
69The kernel port associated with the dest_port name is a norma proxy
70port.
71<p>
72<dt> <strong>KERN_RESOURCE_SHORTAGE</strong>
73<dd>
74The kernel could not allocate storage for an internal rpc state
75structure.
76</dl>
77<h3>RELATED INFORMATION</h3>
78<p>
79Functions:
80<a href="mach_rpc_return_trap.html"><strong>mach_rpc_return_trap</strong></a>,
81<a href="thread_activation_create.html"><strong>thread_activation_create</strong></a>,
82<a href="MP_allocate_subsystem.html"><strong>mach_port_allocate_subsystem</strong></a>,
83<a href="mach_subsystem_create.html"><strong>mach_subsystem_create</strong></a>.