ULONG
ScsiPortGetBusData(
IN PVOID DeviceExtension,
IN ULONG BusDataType,
IN ULONG SystemIoBusNumber,
IN ULONG SlotNumber,
IN PVOID Buffer,
IN ULONG Length
);
ScsiPortGetBusData returns bus-type-specific configuration information that a miniport’s HwScsiFindAdapter routine might use to determine whether it supports a particular adapter on a particular I/O bus and to configure the HBA if it does.
If PCIConfiguration is specified as the BusDataType, this
parameter must be specified as a PCI_SLOT_NUMBER-type value.
ScsiPortGetBusData returns the number of bytes of configuration information it stored in the buffer.
When the input BusDataType is PCIConfiguration, ScsiPortGetBusData can return either of the following values to indicate an error:
Value |
Meaning |
0 (zero) |
The PCI bus does not exist. |
2 |
The PCI bus exists, but there is no device at the given PCI SlotNumber. The Buffer contains the value PCI_INVALID_VENDOR_ID at the PCI_COMMON_CONFIG VendorId member. |
ScsiPortGetBusData can be called only from a miniport driver’s HwScsiFindAdapter routine. Calls from other miniport routines will result in system failure or incorrect operation for the caller.
Configuration data returned by ScsiPortGetBusData is valid only until the miniport calls ScsiPortGetBusData again. As soon as the caller’s HwScsiFindAdapter routine returns control, any returned configuration data becomes invalid.
PCI_COMMON_CONFIG, PCI_SLOT_NUMBER, PORT_CONFIGURATION_INFORMATION, HwScsiFindAdapter