IDCHECK(1M) —
NAME
idcheck − returns selected information
SYNOPSIS
/etc/conf/bin/idcheck
DESCRIPTION
This command returns selected information about the system configuration. It is useful in add-on device Driver Software Package (DSP) installation scripts to determine if a particular device driver has already been installed, or to verify that a particular interrupt vector, I/O address or other selectable parameter is in fact available for use. The various forms are:
idcheck −p device-name [−i dir] [−r] idcheck −v vector [−i dir] [−r] idcheck −d dma-channel [−i dir] [−r] idcheck −a −l lower_address −u upper_address [−i dir] [−r] idcheck −c −l lower_address −u upper_address [−i dir] [−r]
This command scans the System and Master modules and returns:
100 if an error occurs.
0 if no conflict exists.
a positive number greater than 0 and less than 100 if a conflict exists.
The command line options are:
−r Report device name of any conflicting device on stdout.
−p device-name This option checks for the existence of four different components of the DSP. The exit code is the addition of the return codes from the four checks. Add 1 to the exit code if the DSP directory under /etc/conf/pack.d exists. Add 2 to the exit code if the Master module has been installed. Add 4 to the exit code if the System module has been installed. Add 8 to the exit code if the Kernel was built with the System module. Add 16 to the exit code if a Driver.o is part of the DSP (vs. a stubs.c file).
−v vector Returns ’type’ field of device that is using the vector specified (i.e., another DSP is already using the vector).
−d dma-channel Returns 1 if the dma channel specified is being used.
−a This option checks whether the IOA region bounded by "lower" and "upper" conflict with another DSP ("lower" and "upper" are specified with the −l and −u options). The exit code is the addition of two different return codes. Add 1 to the exit code if the IOA region overlaps with another device. Add 2 to the exit code if the IOA region overlaps with another device and that device has the ’O’ option specified in the type field of the Master module. The ’O’ option permits a driver to overlap the IOA region of another driver.
−c Returns 1 if the CMA region bounded by "lower" and "upper" conflict with another DSP ("lower" and "upper" are specified with the −l and −u options).
−l address Lower bound of address range specified in hex. The leading 0x is unnecessary.
−u address Upper bound of address range specified in hex. The leading 0x is unnecessary.
−i dir Specifies the directory in which the ID files sdevice and mdevice reside. The default directory is /etc/conf/cf.d.
ERROR MESSAGES
There are no error messages or checks for valid arguments to options. idcheck interprets these arguments using the rules of scanf(3) and queries the sdevice and mdevice files. For example, if a letter is used in the place of a digit, scanf(3) will translate the letter to 0. idcheck will then use this value in its query.
SEE ALSO
idinstall(1M). mdevice(4), sdevice(4) in the INTERACTIVE SDS Guide and Programmer’s Reference Manual.
\*U — Version 1.0