1 <h2>device_set_status
</h2>
4 <strong>Function
</strong> - Set device status.
7 <strong>#include< device/device.h>
</strong>
9 <strong>kern_return_t device_set_status
</strong>
10 <strong>(mach_port_t
</strong> <var>device
</var>,
11 <strong>dev_flavor_t
</strong> <var>flavor
</var>,
12 <strong>dev_status_t
</strong> <var>status
</var>,
13 <strong>mach_msg_type_number_t
</strong> <var>status_count
</var><strong>);
</strong>
18 <dt> <var>device
</var>
20 [in device send right]
21 A device port to the device to be manipulated.
23 <dt> <var>flavor
</var>
26 The type of status information to set.
28 <dt> <var>status
</var>
30 [pointer to in array of natural-sized units]
31 The status information to set.
33 <dt> <var>status_count
</var>
36 The size of the status information (in natural-sized units).
40 The
<strong>device_set_status
</strong> function sets device status.
41 The possible values of
<var>flavor
</var>
42 as well as the corresponding meanings are device dependent.
43 <h3>RETURN VALUES
</h3>
46 <dt> <strong>D_DEVICE_DOWN
</strong>
48 Device has been shut down
50 <dt> <strong>D_IO_ERROR
</strong>
54 <dt> <strong>D_NO_SUCH_DEVICE
</strong>
56 No device with that name, or the device is not operational.
58 <dt> <strong>D_OUT_OF_BAND
</strong>
60 Out-of-band condition occurred on device (such as typing
61 <strong><Ctrl>-C
</strong>).
63 <dt> <strong>D_READ_ONLY
</strong>
65 Data cannot be written to this device.
67 <h3>RELATED INFORMATION
</h3>
70 <a href=
"device_get_status.html"><strong>device_get_status
</strong></a>.