xref: /xnu-10002.61.3/osfmk/man/device_reply_server.html (revision 0f4c859e951fba394238ab619495c4e1d54d0f34)
1*0f4c859eSApple OSS Distributions<h2>device_reply_server</h2>
2*0f4c859eSApple OSS Distributions<hr>
3*0f4c859eSApple OSS Distributions<p>
4*0f4c859eSApple OSS Distributions<strong>Function</strong> - Handle incoming data from kernel device driver.
5*0f4c859eSApple OSS Distributions<h3>SYNOPSIS</h3>
6*0f4c859eSApple OSS Distributions<pre>
7*0f4c859eSApple OSS Distributions<strong>boolean_t	device_reply_server</strong>
8*0f4c859eSApple OSS Distributions		<strong>(mach_msg_header_t</strong>	<var>request_msg</var>,
9*0f4c859eSApple OSS Distributions		<strong>mach_msg_header_t</strong>	<var>reply_msg</var><strong>);</strong>
10*0f4c859eSApple OSS Distributions</pre>
11*0f4c859eSApple OSS Distributions<h3>PARAMETERS</h3>
12*0f4c859eSApple OSS Distributions<dl>
13*0f4c859eSApple OSS Distributions<p>
14*0f4c859eSApple OSS Distributions<dt> <var>request_msg</var>
15*0f4c859eSApple OSS Distributions<dd>
16*0f4c859eSApple OSS Distributions[pointer to in structure]
17*0f4c859eSApple OSS DistributionsThe device driver message received from the
18*0f4c859eSApple OSS Distributionskernel.
19*0f4c859eSApple OSS Distributions<p>
20*0f4c859eSApple OSS Distributions<dt> <var>reply_msg</var>
21*0f4c859eSApple OSS Distributions<dd>
22*0f4c859eSApple OSS Distributions[out structure]
23*0f4c859eSApple OSS DistributionsA reply message.  No messages from a device driver
24*0f4c859eSApple OSS Distributionsexpect a direct reply, so this field is not used.
25*0f4c859eSApple OSS Distributions</dl>
26*0f4c859eSApple OSS Distributions<h3>DESCRIPTION</h3>
27*0f4c859eSApple OSS Distributions<p>
28*0f4c859eSApple OSS DistributionsThe <strong>device_reply_server</strong> function is the MIG generated server handling
29*0f4c859eSApple OSS Distributionsfunction to handle messages from kernel device drivers.  Such
30*0f4c859eSApple OSS Distributionsmessages were sent in response to the various
31*0f4c859eSApple OSS Distributions<strong>device_</strong>...<strong>_request</strong>...
32*0f4c859eSApple OSS Distributionscalls.  It is assumed when using
33*0f4c859eSApple OSS Distributionsthose calls that some task is listening for reply messages on the port named as a
34*0f4c859eSApple OSS Distributionsreply port to those calls.  The <strong>device_reply_server</strong>
35*0f4c859eSApple OSS Distributionsfunction performs all
36*0f4c859eSApple OSS Distributionsnecessary argument handling for a kernel message and calls one
37*0f4c859eSApple OSS Distributionsof the device server functions to interpret the message.
38*0f4c859eSApple OSS Distributions<h3>RETURN VALUES</h3>
39*0f4c859eSApple OSS Distributions<dl>
40*0f4c859eSApple OSS Distributions<p>
41*0f4c859eSApple OSS Distributions<dt> <strong>TRUE</strong>
42*0f4c859eSApple OSS Distributions<dd>
43*0f4c859eSApple OSS DistributionsThe message was handled and the appropriate function was called.
44*0f4c859eSApple OSS Distributions<p>
45*0f4c859eSApple OSS Distributions<dt> <strong>FALSE</strong>
46*0f4c859eSApple OSS Distributions<dd>
47*0f4c859eSApple OSS DistributionsThe message did not apply to this device handler interface and no other
48*0f4c859eSApple OSS Distributionsaction was taken.
49*0f4c859eSApple OSS Distributions</dl>
50*0f4c859eSApple OSS Distributions<h3>RELATED INFORMATION</h3>
51*0f4c859eSApple OSS Distributions<p>
52*0f4c859eSApple OSS DistributionsFunctions:
53*0f4c859eSApple OSS Distributions<a href="device_open.html"><strong>ds_device_open_reply<strong></a>,
54*0f4c859eSApple OSS Distributions<a href="device_write.html"><strong>ds_device_write_reply<strong></a>,
55*0f4c859eSApple OSS Distributions<a href="device_write_inband.html"><strong>ds_device_write_reply_inband<strong></a>,
56*0f4c859eSApple OSS Distributions<a href="device_read.html"><strong>ds_device_read_reply<strong></a>,
57*0f4c859eSApple OSS Distributions<a href="device_read_inband.html"><strong>ds_device_read_reply_inband<strong></a>,
58*0f4c859eSApple OSS Distributions<a href="device_read_overwrite.html"><strong>ds_device_read_reply_overwrite<strong></a>.
59