Socket_Ioctl - ioctl()
In: R0 = Socket descriptor
R1 = Operation
R2 = Pointer to argument
Out: R0 corrupted
This call is used to perform miscellaneous control operations on individual sockets and on the TCP/IP stack as a whole. At the moment, these operations are supported:
FIOASYNC - Mark a socket for asynchronous operation. This means that a RISC OS event will be raised when important changes occur in the sockets status. See the section on events for more detail of the events that are raised. The argument is a single word acting as a boolean flag.
FIONBIO - Mark a socket non-blocking so that no attempted operations on the socket will block. They will instead fail with the error EWOULDBLOCK if they are unable to complete straight away. The argument is a single word acting as a boolean flag.
FIONREAD - Read the number of bytes available for reading from the socket. The argument is an integer which will be filled in with the number of bytes available.
SIOCATMARK - Read a boolean indicator that says whether we are at the OOB marker in the data stream.
This call also supports certain operations on the interface table, but details of this are outside the current scope of this document. Future extensions will implement the remaining operations on the routing table and also a set of operations on the routing tables.
|
|
|