|SCSI_ADDRESS(9S)||Data Structures for Drivers||SCSI_ADDRESS(9S)|
In the case where only the target component is used to address the device, the logical unit should be set to 0. If the SCSI target device supports logical units, then the HBA must interpret the logical units field of the data structure.
SCSI_HBA_ADDR_COMPLEXin the hba_flags argument to scsi_hba_attach_setup(9F). When the flag is set, this structure must be treated as opaque. Instead of storing a traditional target and LUN, the address is treated as the string form of a unit address. In addition, rather than storing a pointer to the scsi_hba_tran(9S) structure, the address structure can store any arbitrary pointer through the scsi_device_hba_private_get(9F) and scsi_device_hba_private_set(9F) functions.
scsi_hba_tran_t *a_hba_tran; /* Transport vectors for the SCSI bus */ ushort_t a_target; /* SCSI target id */ uchar_t a_lun; /* SCSI logical unit */
a_hba_tran is a pointer to the controlling HBA 's transport vector structure. The SCSA interface uses this field to pass any transport requests from the SCSI target device drivers to the HBA driver.
a_target is the target component of the SCSI address
a_lun is the logical unit component of the SCSI address. The logical unit is used to further distinguish a SCSI target device that supports multiple logical units from one that does not.
If the flag,
set, then the driver must not dereference any of these
fields, the structure contents will have changed and should be considered
Writing Device Drivers.
|April 23, 2017||OmniOS|