# HG changeset patch # User Cole Robinson # Date 1252861553 14400 # Node ID 726dc69533961f5cf7865e35be2b851f5f686c52 # Parent 0d3cdc5ff5d091dd73d3ef0fe21123fb63b4d7a0 Don't erroneously limit the amount of virtio disks (bz 499654) Just let qemu error if we add too many. diff -r 0d3cdc5ff5d0 -r 726dc6953396 tests/clitest.py --- a/tests/clitest.py Wed Aug 05 14:37:02 2009 -0400 +++ b/tests/clitest.py Sun Sep 13 13:05:53 2009 -0400 @@ -128,6 +128,8 @@ "--disk vol=%(POOL)s/%(VOL)s", # 3 IDE and CD "--disk path=%(EXISTIMG1)s --disk path=%(EXISTIMG1)s --disk path=%(EXISTIMG1)s --disk path=%(EXISTIMG1)s,device=cdrom", + # > 16 scsi disks + " --disk path=%(EXISTIMG1)s,bus=scsi --disk path=%(EXISTIMG1)s,bus=scsi --disk path=%(EXISTIMG1)s,bus=scsi --disk path=%(EXISTIMG1)s,bus=scsi --disk path=%(EXISTIMG1)s,bus=scsi --disk path=%(EXISTIMG1)s,bus=scsi --disk path=%(EXISTIMG1)s,bus=scsi --disk path=%(EXISTIMG1)s,bus=scsi --disk path=%(EXISTIMG1)s,bus=scsi --disk path=%(EXISTIMG1)s,bus=scsi --disk path=%(EXISTIMG1)s,bus=scsi --disk path=%(EXISTIMG1)s,bus=scsi --disk path=%(EXISTIMG1)s,bus=scsi --disk path=%(EXISTIMG1)s,bus=scsi --disk path=%(EXISTIMG1)s,bus=scsi --disk path=%(EXISTIMG1)s,bus=scsi --disk path=%(EXISTIMG1)s,bus=scsi", ], "invalid": [ diff -r 0d3cdc5ff5d0 -r 726dc6953396 virtinst/VirtualDisk.py --- a/virtinst/VirtualDisk.py Wed Aug 05 14:37:02 2009 -0400 +++ b/virtinst/VirtualDisk.py Sun Sep 13 13:05:53 2009 -0400 @@ -1142,12 +1142,14 @@ the passed parameters. @returns: str prefix, or None if no reasonable guess can be made """ + # The upper limits here aren't necessarilly 1024, but let the HV + # error as appropriate. if self.bus == "virtio": - return ("vd", 16) + return ("vd", 1024) elif self.bus == "scsi" or self.bus == "usb": - return ("sd", 16) + return ("sd", 1024) elif self.bus == "xen": - return ("xvd", 16) + return ("xvd", 1024) elif self.bus == "fdc" or self.device == self.DEVICE_FLOPPY: return ("fd", 2) elif self.bus == "ide":