man Pages(9S): DDI and DKI Data Structures
  Search only this book
Download this book in PDF

NAME

scsi_inquiry - SCSI device structure

SYNOPSIS

#include <sys/scsi/scsi.h>

INTERFACE LEVEL

Solaris DDI specific (Solaris DDI).

DESCRIPTION

The scsi_inquiry structure contains 36 required bytes, followed by a variable number of vendor-specific parameters. Bytes 59 through 95, if returned, are reserved for future standardization. This structure is part of scsi_device(9S) structure and typically filled in by scsi_probe(9F).

STRUCTURE ELEMENTS

u_char
inq_dtype;
/* peripheral qualifier, device type * /
u_char    inq_rmb            : 1,  /* removable media * /
          inq_qual           : 7;  /* device type qualifier * /
u_char    inq_iso            : 2,  /* ISO version * /
          inq_ecma           : 3,  /* ECMA version * /
          inq_ansi           : 3;  /* ANSI version * /
u_char    inq_aenc           : 1,  /* async event notification cap. * /
          inq_trmiop         : 1,  /* supports TERMINATE I/O PROC msg * /
          inq_rdf            : 4;  /* response data format * /
u_char    inq_len;                 /* additional length * /
u_char    inq_reladdr        : 1,  /* supports relative addressing * /
          inq_wbus32         : 1,  /* supports 32 bit wide data xfers * /
          inq_wbus16         : 1,  /* supports 16 bit wide data xfers * /
          inq_sync           : 1,  /* supports synchronous data xfers * /
          inq_linked         : 1,  /* supports linked commands * /
          inq_cmdque         : 1,  /* supports command queueing * /
          inq_sftre          : 1;  /* supports Soft Reset option * /
char      inq_vid[8];              /* vendor ID * /
char      inq_pid[16];             /* product ID * /
char      inq_revision[4];         /* revision level * /

inq_dtype identifies the type of device. Bits 0 - 4 represent the Peripheral Device Type and bits 5 - 7 represent the Peripheral Qualifier. The following values are appropriate for Peripheral Device Type field:
DTYPE_DIRECT
Direct-access device (e.g., magnetic disk).
DTYPE_SEQUENTIAL Sequential-access device (e.g., magnetic tape).
DTYPE_PRINTER
Printer device.
DTYPE_PROCESSOR
Processor device.
DTYPE_WORM
Write-once device (e.g., some optical disks).
DTYPE_RODIRECT
CD-ROM device.
DTYPE_SCANNER
Scanner device.
DTYPE_OPTICAL
Optical memory device (e.g., some optical disks).
DTYPE_CHANGER
Medium Changer device (e.g., jukeboxes).
DTYPE_COMM
Communications device.
The following values are appropriate for the Peripheral Qualifier field:
DPQ_POSSIBLE
The specified peripheral device type is currently connected
to this logical unit. If the target cannot determine whether or not a physical device is currently connected it shall also use
this peripheral qualifier when returning the INQUIRY data.
This peripheral qualifier does not imply that the device is
ready for access by the initiator.
DPQ_SUPPORTED
The target is capable of supporting the specified peripheral
device type on this logical unit. However, the physical device is not currently connected to this logical unit.
DPQ_NEVER
Reserved
DPQ_VUNIQ
This is a vendor-unique qualifier.
inq_rmb, if set, indicates that the medium is removable.
inq_qual is a device type qualifier.
inq_iso indicates ISO version.
inqi_ecma indicates ECMA version.
inq_ansi indicates ANSI version.
inq_aenc, if set, indicates that the device supports asynchronous event notification capability as defined in SCSI-2 specification.
inq_trmiop, if set, indicates that the device supports the TERMINATE I/O PROCESS message.
inq_rdf, if reset, indicates the INQUIRY data forma is as specified in SCSI-1.
inq_inq_len is the additional length field which specifies the length in bytes of the parameters.
inq_reladdr, if set, indicates that the device supports the relative addressing mode of this logical unit.
inq_wbus32, if set, indicates that the device supports 32 bit wide data transfers.
inq_wbus16, if set, indicates that the device supports 16-bit wide data transfers.
inq_sync, if set, indicates that the device supports synchronous data transfers.
inq_linked, if set, indicates that the device supports linked commands for this logical unit.
inq_cmdque, if set, indicates that the device supports tagged command queueing.
inq_sftre, if reset, indicates that the device responds to the RESET condition with the hard RESET alternative. If this bit is set, this indicates that the device responds with the soft RESET alternative.
inq_vid contains eight bytes of ASCII data identifying the vendor of the product.
inq_pid contains sixteen bytes of ASCII data as defined by the vendor.
inq_revision contains four bytes of ASCII data as defined by the vendor.

SEE ALSO

scsi_probe(9F), scsi_device(9S)
ANSI Small Computer System Interface-2 (SCSI-2)
Writing Device Drivers