IOCTL_SCSI_GET_INQUIRY_DATA problem

Hi
We develop drivers for W2K3.
We send IOCTL_SCSI_GET_INQUIRY_DATA
to an HBA to get a list of all the LUNs seen by this HBA.

However because the in the structure :
typedef struct _SCSI_BUS_DATA {
UCHAR NumberOfLogicalUnits;
UCHAR InitiatorBusId;
ULONG InquiryDataOffset;
}SCSI_BUS_DATA, *PSCSI_BUS_DATA;

The field of NumberOfLogicalUnits is limited to 255.
Whenever we introduce more thab 256 LUNs to the HBA the list returns that NumberOfLogicalUnits & InquiryDataOffset are 0.

What can i do to solve this?
Is there another IOCTL i can use?
I read that i can use IOCTL_STORAGE_QUERY_PROPERTY
but i did not find what parameters i can send there that will return the list of LUNs as in
IOCTL_SCSI_GET_INQUIRY_DATA .

Thanks,
Michael

Try to enumerate luns manually if nobody in the execution path does
limit the total number. In this way, SPTI is the only choice since
ASPI restricts the total number to 255.

On Sun, 22 Apr 2007 08:31:02 -0400 (EDT), xxxxx@storeage.com wrote:

Hi
We develop drivers for W2K3.
We send IOCTL_SCSI_GET_INQUIRY_DATA
to an HBA to get a list of all the LUNs seen by this HBA.

However because the in the structure :
typedef struct _SCSI_BUS_DATA {
UCHAR NumberOfLogicalUnits;
UCHAR InitiatorBusId;
ULONG InquiryDataOffset;
}SCSI_BUS_DATA, *PSCSI_BUS_DATA;

The field of NumberOfLogicalUnits is limited to 255.
Whenever we introduce more thab 256 LUNs to the HBA the list returns that NumberOfLogicalUnits & InquiryDataOffset are 0.

What can i do to solve this?
Is there another IOCTL i can use?
I read that i can use IOCTL_STORAGE_QUERY_PROPERTY
but i did not find what parameters i can send there that will return the list of LUNs as in
IOCTL_SCSI_GET_INQUIRY_DATA .

Thanks,
Michael

Cheers,
R. Yang

  • Windows Kernel Developer [Custom Dev and Consulting]