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

reldevno Device Configuration Subroutine


Releases the minor or major number, or both, for a device instance.


#include <cf.h>
#include <sys/cfgodm.h>
#include <sys/cfgdb.h>

int reldevno (device_instance_name, release)
char *device_instance_name;
int release;


device_instance_name Points to the character string containing the device instance name.
release Specifies whether the major number should be released. A value of True releases the major number; a value of False does not.


The reldevno device configuration subroutine is one of the designated access routines to the Customized Device Driver (CuDvDr) object class. This object class is locked exclusively by this routine until its completion. All minor numbers associated with the device instance name are deleted from the CuDvDr object class. That is, each object is deleted from the class. This releases the minor numbers for reuse.

The major number is released for reuse if the following two conditions exist:

If you prefer to release the major number yourself, then the relmajor device configuration subroutine can be called. In this case, you should also set the release parameter to False. All special files, including symbolically linked special files, corresponding to the deleted objects are deleted from the file system.

Return Values

0 Indicates successful completion.
-1 Indicates a failure to release the minor number or major number, or both.


/usr/lib/libcfg.a Archive of device configuration subroutines.

Related Information

The genmajor device configuration subroutine, genminor device configuration subroutine, relmajor device configuration subroutine.

Customized Device Driver (CuDvDr) object class.

List of Device Configuration Subroutines.

[ Previous | Next | Contents | Home | Search ]