The I_SRDOPT operation sets the read mode using the value of the arg parameter. Legal values for the arg parameter are:
| RNORM | Byte-stream mode. This is the default mode. |
| RMSGD | Message-discard mode. |
| RMSGN | Message-nondiscard mode. |
| RFILL | Read mode. This mode prevents completion of any read request until one of three conditions occurs:
Several control messages support the RFILL mode. They are used by modules to manipulate data being placed in user buffers at the stream head. These messages are multiplexed under a single M_MI message type. The message subtype, pointed to by the b_rptr parameter, is one of the following: |
In addition, treatment of control messages by the stream head can be changed by setting the following flags in the arg parameter:
| RPROTNORM | Causes the read routine to be unsuccessful if a control message is at the front of the stream-head read queue. |
| RPROTDAT | Delivers the control portion of a message as data. |
| RPROTDIS | Discards the control portion of a message, delivering any data portion. |
If unsuccessful, the errno global variable is set to the following value:
| EINVAL | The value of the arg parameter is not one of the above legal values. |
This operation is part of STREAMS Kernel Extensions.
The streamio operations.
The I_GRDOPT streamio operation.