Resets the Multiprotocol Quad Port (MPQP) adapter to a known state and returns system resources back to the system on the last close for that adapter.
int mpclose (devno, chan, ext) dev_t devno; int chan, ext;
devno | Specifies major and minor device numbers. |
chan | Specifies the channel number assigned by the mpmpx entry point. |
ext | Ignored by the MPQP device handler. |
The mpclose entry point routine resets the MPQP adapter to a known state and returns system resources to the system on the last close for that adapter. The port no longer accepts mpread, mpwrite, or mpioctl operation requests. The mpclose entry point is called in user mode by issuing a close system call. The mpclose entry point is invoked in response to an fp_close kernel service.
On an mpclose entry point, the MPQP device handler does the following:
On the last mpclose entry point for a particular adapter, the MPQP device handler also does the following:
The mpclose entry point closes the device. For each mpopen entry point issued, there must be a corresponding mpclose entry point.
Before issuing the mpclose entry point, the caller should issue a CIO_HALT operation for each CIO_START operation issued during that particular instance of open. If a close request is received without a preceding CIO_HALT operation, the functions of the halt are performed. A close request without a preceding CIO_HALT operation occurs only during abnormal termination of the port.
The mpclose entry point can be called from the process environment only.
The common return codes for the mpclose entry point are:
The mpclose entry point 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.
The mpconfig entry point, mpioctl entry point, mpmpx entry point, mpopen entry point, mpread entry point, mpselect entry point, mpwrite entry point.
The CIO_HALT mpioctl MPQP Device Handler Operation, CIO_START mpioctl MPQP Device Handler Operation.
The close system call.
The fp_close kernel service.