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

ddclose Communications PDH Entry Point

Purpose

Frees up system resources used by the specified communications device until they are needed.

Syntax

#include <sys/device.h>
int ddclose ( devno, chan) dev_t devno; int chan;

Parameters

devno Major and minor device numbers.
chan Channel number assigned by the device handler's ddmpx entry point.

Description

The ddclose entry point frees up system resources used by the specified communications device until they are needed again. Data retained in the receive queue, transmit queue, or status queue is purged. All buffers associated with this channel are freed. The ddclose entry point should be called once for each successfully issued ddopen entry point.

Before issuing a ddclose entry point, a CIO_HALT operation should be issued for each previously successful CIO_START operation on this channel.

Execution Environment

A ddclose entry point can be called from the process environment only.

Return Value

In general, communication device-handlers use the common return codes defined for entry points. However, device handlers for specific communication devices may return device-specific codes. The common return code for the ddclose entry point is the following:

ENXIO Indicates an attempt to close an unconfigured device.

Related Information

The ddmpx entry point, ddopen entry point.

The CIO_HALT ddioctl Communications PDH Operation, CIO_START ddioctl Communications PDH Operation.


[ Previous | Next | Contents | Home | Search ]