[ Previous | Next | Contents | Home | Search ]
AIX Version 4.3 Kernel and Subsystems Technical Reference, Volume 2

CIO_HALT (Halt Device) mpioctl MPQP Device Handler Operation


Ends a session with the Multiprotocol Quad Port (MPQP) device handler and terminates the connection to the MPQP link.


The CIO_HALT operation terminates a session with the MPQP device handler. The caller specifies which network ID to halt. The CIO_HALT operation removes the network ID from the network ID table and disconnects the physical link. A CIO_HALT operation must be issued for each CIO_START operation that completed successfully.

Data received for the specified network ID before the CIO_HALT operation is called can be retrieved by the caller using the mpselect and mpread entry points.

If the CIO_HALT operation terminates abnormally, the status is returned either asynchronously or as part of the CIO_HALT_DONE. Whatever the case, the CIO_GET_STAT operation is used to get information about the error. When a halt is terminated abnormally (for example, due to network failure), the following occurs:

No recovery procedure is required by the caller; however, logging the error is required.

Errors are reported on halt operations because the user could continue to be charged for connect time if the network does not recognize the halt. This error status permits a network application to be notified about an abnormal link disconnection and then take corrective action, if necessary.

Parameter Block

For the MPQP CIO_HALT operation, the extptr parameter points to a session_blk structure. This structure is defined in the /usr/include/sys/comio.h file and contains the following fields:

status Specifies the status of the port. This field is set for immediately detectable errors. Possible values for the status filed are:
  • CIO_OK

If the calling process does not wish to sleep while the halt is in progress, the DNDELAY option can be used. In either case, the status of the halt is retrieved using the CIO_GET_STATUS operation and a CIO_HALT_DONE status block is returned. The CIO_HALT_DONE status block should be used as an indication of completion.

netid Contains the network ID the caller wishes to halt. The network ID is placed in the least significant byte of the netid field.

Execution Environment

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

Return Values

The CIO_HALT operation returns common communications return values. In addition, the following MPQP specific errors may be returned:

EBUSY Indicates the device is not started or is not in a data transfer state.
ENOMEM Indicates there are no mbufs or mbuf clusters available.
ENXIO Indicates the adapter number is out of range.

Implementation Specifics

The CIO_HALT operation functions with a 4-Port Multiprotocol Interface adapter that has been correctly configured for use on a qualified network. Consult the adapter specifications for more information on configuring the adapter and network qualifications.


/usr/include/sys/comio.h Contains the session_blk structure definition.

Related Information

The mpread entry point, mpselect entry point.

The CIO_GET_STAT mpioctl MPQP Device Handler Operation, CIO_QUERY mpioctl MPQP Device Handler Operation, CIO_START mpioctl MPQP Device Handler Operation, MP_CHG_PARMS mpioctl MPQP Device Handler Operation, MP_START_AR and MP_STOP_AR mpioctl MPQP Device Handler Operations.

Status Blocks for the Multiprotocol Device Handler.

[ Previous | Next | Contents | Home | Search ]