]> git.proxmox.com Git - qemu.git/blobdiff - hw/scsi-bus.c
scsi: Increase the number of possible devices
[qemu.git] / hw / scsi-bus.c
index 5a3fd4b7acd615895fede26b447bef5a5365be81..74a08b7da648efaa8e088ab6d2acce5d47b8f8fc 100644 (file)
@@ -108,7 +108,7 @@ int scsi_bus_legacy_handle_cmdline(SCSIBus *bus)
     int res = 0, unit;
 
     loc_push_none(&loc);
-    for (unit = 0; unit < MAX_SCSI_DEVS; unit++) {
+    for (unit = 0; unit < bus->ndev; unit++) {
         dinfo = drive_get(IF_SCSI, bus->busnr, unit);
         if (dinfo == NULL) {
             continue;