[ Previous | Next | Contents | Home | Search ]
AIX Version 4.3 Understanding the Diagnostic Subsystem for AIX

configure_device, initial_state

Purpose

Puts a device and parentage into the available state.

Restores a device and parentage to their initial state before configuration.

Syntax

#include   <diag/diagodm.h>
#include   <sys/cfgodm.h>
#include   <sys/cfgdb.h>

int  configure_device ( name )
char *name;

int  initial_state ( state, name )
int    state;
char *name;

Description

The configure_device subroutine is used to put a device into the AVAILABLE state (for testing) if the device is presently DEFINED or STOPPED. Also the parentage of the device is checked, and their states also put into AVAILABLE state if necessary.

The initial_state subroutine is used to restore the device and parentage back to their initial state (after testing).

Parameters

name Identifies the device.
state Indicates the previous state of the device.

Return Value

The following values are returned:

DEFINED Device was previously in the DEFINED state.
AVAILABLE Device is already in the AVAILABLE state.
STOPPED Device was previously in the STOPPED state.
-1 Error configuring the device.

[ Previous | Next | Contents | Home | Search ]