Waits for a queue element to be placed on a device queue.
#include <sys/types.h>
#include <sys/errno.h>
#include <sys/deviceq.h>
struct req_qe *waitq ( queue_id)
cba_id queue_id;
Item | Description |
---|---|
queue_id | Specifies the device queue identifier. |
The waitq kernel service is not part of the base kernel but is provided by the device queue management kernel extension. This queue management kernel extension must be loaded into the kernel before loading any kernel extensions referencing these services.
The waitq kernel service waits for a queue element to be placed on the device queue specified by the queue_id parameter. This service performs these two actions:
Processes can only use the waitq kernel service to wait for a single device queue. Use the et_wait service to wait on the occurrence of more than one event, such as multiple device queues.
The waitq kernel service uses the EVENT_SHORT form of the et_wait kernel service. Therefore, a signal does not terminate the wait. Use the et _wait kernel service if you want a signal to terminate the wait.
The readq kernel service can be used to read the active queue element from a queue. It does not wait for a queue element if there are none in the queue.
Attention: The server must not alter any fields in the queue element or the system may halt.
The waitq kernel service can be called from the process environment only.
The waitq service returns the address of the active queue element in the device queue.