Index: drivers/storage/scsiport/scsiport.c =================================================================== --- drivers/storage/scsiport/scsiport.c (revision 56808) +++ drivers/storage/scsiport/scsiport.c (working copy) @@ -2346,15 +2346,10 @@ &PciConfig, sizeof(ULONG)); - /* If result of HalGetBusData is 0, then the bus is wrong */ - if (DataSize == 0) + /* If result of HalGetBusData is too small, then the bus is wrong */ + if (DataSize < RTL_SIZEOF_THROUGH_FIELD(PCI_COMMON_CONFIG, DeviceID)) return FALSE; - /* If result is PCI_INVALID_VENDORID, then this device has no more - "Functions" */ - if (PciConfig.VendorID == PCI_INVALID_VENDORID) - break; - sprintf (VendorIdString, "%04hx", PciConfig.VendorID); sprintf (DeviceIdString, "%04hx", PciConfig.DeviceID);