Returns device statistics.
#include <sys/device.h> #include <sys/comio.h>
int ddioctl
(devno, op, parmptr,
devflag, chan, ext)
dev_t devno;
int op;
struct query_parms * parmptr;
ulong devflag;
int chan, ext;
devno | Specifies major and minor device numbers. |
op | Indicates the entry point of the CIO_QUERY operation. |
parmptr | Points to a query_parms structure. This structure is defined in the /usr/include/sys/comio.h file. |
devflag | Specifies the DKERNEL flag. This flag is set by calling kernel-mode processes and cleared by calling user-mode processes. |
chan | Specifies channel number assigned by the device handler's ddmpx entry point. |
ext | Indicates device-dependent. |
The CIO_QUERY operation returns various statistics from the device. Counters are zeroed by the physical device handler when the device is configured. The data returned consists of two contiguous portions. The first portion contains counters to be collected and maintained by all device handlers in the communication I/O subsystem. The second portion consists of device-dependent counters and parameters.
For the CIO_QUERY operation, the paramptr parameter points to a query_parms structure. This structure is located in the /usr/include/sys/comio.h file and contains the following fields:
A CIO_QUERY operation can be called from the process environment only.
In general, communication device handlers use the common return codes defined for an entry point. However, device handlers for specific communication devices may return device-specific codes. The common return codes for the CIO_QUERY operation are the following:
The ddioctl device driver entry point, ddmpx entry point in BkSym.TRKernel5;.