[ Previous | Next | Contents | Search ]
AIXLink/X.25 1.1 for AIX: Guide and Reference

CIO_QUERY (Query Device) x25sioctl X.25 Device Handler Operation


Returns device statistics and device-dependent information.


Note: The counters and profile information can only be cleared by a system user.

The CIO_QUERY x25sioctl operation returns the ras_log field of the define device structure (DDS).

query_params Parameter Block

For the CIO_QUERY operation, the arg parameter returns a pointer to the query_params structure. This structure contains the following fields:

status Contains the returned value if the return code is EIO.
bufptr Points to an x25_query_data structure. This structure contains the following fields:
cc Contains a cio_stats structure as defined in the /usr/include/sys/comio.h file.
ds Contains an x25_stats structure identifying X.25-specific statistics. This structure is found in the /usr/include/sys/x25user.h file.
buflen Specifies the length of the buffer.
clearall Clears the statistics when set to CIO_QUERY_CLEAR. Any other setting leaves the statistics unchanged.

x25_stats Structure

The x25_stats structure identifies X.25-specific statistics. Information in this structure includes the transmit_profile field. This field provides a profile of the transmission packet sizes in use on a port and can be used for configuration of adapter buffers. The transmit_profile field contains a count of the number of packets sent since the device was last configured. The size of these packets must be in the range specified.

Index Size
0 Packet size not known
1 Reserved
2 Reserved
3 Reserved
4 0 - 15
5 16 - 31
6 32 - 63
7 64 - 127
8 128 - 255
9 256 - 511
10 512 - 1023
11 1024 - 2047
12 2048 - 4095
>12 Reserved

Execution Environment

The CIO_QUERY operation can be called from the process environment only.

Return Values

A return code of -1 indicates an unsuccessful operation and the kernel sets the errno global variable to one of the following values:

EFAULT Indicates an invalid address was specified.
EIO Indicates an error has occurred. The arg->status field contains one of the following exception codes:
EMSGSIZE Indicates the statistical data was greater than the length of the buffer specified by the buflen field. The data in the buffer is truncated.
ENOBUFS Indicates no buffers are available.
ENXIO Indicates the device has not been completely configured.

Implementation Specifics

The CIO_QUERY operation functions with an X.25 Interface Co-Processor/2 that has been correctly configured for use on a qualified network. Consult adapter specifications for more information on configuring the adapter and network qualifications.

Related Information

The x25sioctl device handler entry point.

[ Previous | Next | Contents | Search ]