mirror of
https://github.com/xen-project/xen.git
synced 2026-10-29 18:50:05 +01:00
hvm ioemu: Do not initialise the LSI SCSI interface if no SCSI discs
are attached to the guest. Signed-off-by: Keir Fraser <keir@xensource.com>
This commit is contained in:
1 parent
369e63f97c
commit
135a488c83
1 file changed
+5
-4
+5
-4
@@ -923,11 +923,12 @@ static void pc_init1(uint64_t ram_size, int vga_ram_size, char *boot_device,
|
||||
#else
|
||||
if (pci_enabled) {
|
||||
void *scsi;
|
||||
|
||||
scsi = lsi_scsi_init(pci_bus, -1);
|
||||
for (i = 0; i < MAX_SCSI_DISKS ; i++) {
|
||||
if (bs_table[i + MAX_DISKS])
|
||||
lsi_scsi_attach(scsi, bs_table[i + MAX_DISKS], -1);
|
||||
if (!bs_table[i + MAX_DISKS])
|
||||
continue;
|
||||
if (!scsi)
|
||||
scsi = lsi_scsi_init(pci_bus, -1);
|
||||
lsi_scsi_attach(scsi, bs_table[i + MAX_DISKS], -1);
|
||||
}
|
||||
}
|
||||
#endif /* !CONFIG_DM */
|
||||
|
||||