[ Bottom of Page | Previous Page | Next Page | Contents | Index | Library Home | Legal | Search ]

Technical Reference: Kernel and Subsystems, Volume 2

CIO_QUERY (Query Statistics) tokioctl Token-Ring Device Handler Operation

Purpose

Note: This function is supported in AIX 5.1 and earlier only.

Allows the caller to read the counter values accumulated by a token-ring device handler.

Description

The CIO_QUERY tokioctl operation is used by the caller to read the counter values accumulated by a token-ring device handler. The first call to the tokopen entry point initializes the counters to 0.

For the CIO_QUERY operation, the arg parameter points to the query_parms structure. This structure is defined in the /usr/include/sys/comio.h file and contains the following fields:

Field Description
status Indicates the status of the port. Returns one of the following status values:
  • CIO_OK
  • CIO_INV_CMD
buffptr Specifies the address of a buffer where the returned statistics are to be placed.
bufflen Specifies the length of the buffer.
clearall When this value equals CIO_QUERY_CLEAR, the counters are cleared upon completion of call. The CIO_QUERY_CLEAR label can be found in the /usr/include/sys/comio.h file.

The counters placed in the supplied buffer by the CIO_QUERY operation are the counters declared in the tok_query_stats_t structure defined in the /usr/include/sys/tokuser.h file.

The CIO_QUERY operation functions with a Token-Ring High Performance Network Adapter that has been correctly configured for use on a qualified network. Consult adapter specifications for more information on configuring the adapter and network qualifications.

Execution Environment

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

Return Values

EFAULT Indicates that the specified address is not valid.
EINVAL Indicates that a parameter is not valid.

Related Information

The ddioctl (CIO_QUERY) entry point.

The tokioctl entry point, tokopen entry point.

Common Communications Status and Exception Codes in AIX 5L Version 5.2 Kernel Extensions and Device Support Programming Concepts.

[ Top of Page | Previous Page | Next Page | Contents | Index | Library Home | Legal | Search ]