Martin Polednik has uploaded a new change for review. Change subject: storage: extend drives name to allow sata interface ......................................................................
storage: extend drives name to allow sata interface SATA is widely used physical interface for storage devices. The interface uses SCSI protocol, making it similar to SCSI itself in terms of naming, but libvirt distinguishes the physical interfaces. We therefore add SATA name generation to properly support SATA devices. Change-Id: Ibec60639922a410218e0e48d0d607ce46e5ed4a7 Signed-off-by: Martin Polednik <[email protected]> --- M tests/vmStorageTests.py M vdsm/virt/vmdevices/storage.py 2 files changed, 10 insertions(+), 1 deletion(-) git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/03/56803/1 diff --git a/tests/vmStorageTests.py b/tests/vmStorageTests.py index 9534f69..af95aab 100644 --- a/tests/vmStorageTests.py +++ b/tests/vmStorageTests.py @@ -633,6 +633,14 @@ ['fdc', 26, 'fdz'], ['fdc', 27, 'fda'], ['fdc', 28, 'fdb'], + + ['sata', -1, 'sda'], + ['sata', 0, 'sda'], + ['sata', 1, 'sda'], + ['sata', 2, 'sdb'], + ['sata', 26, 'sdz'], + ['sata', 27, 'sda'], + ['sata', 28, 'sdb'], ]) def test_ide_drive(self, interface, index, expected_name): conf = drive_config( diff --git a/vdsm/virt/vmdevices/storage.py b/vdsm/virt/vmdevices/storage.py index 74e03b2..713f996 100644 --- a/vdsm/virt/vmdevices/storage.py +++ b/vdsm/virt/vmdevices/storage.py @@ -352,7 +352,8 @@ pass # Ignore if custom disk cache is missing def _makeName(self): - devname = {'ide': 'hd', 'scsi': 'sd', 'virtio': 'vd', 'fdc': 'fd'} + devname = {'ide': 'hd', 'scsi': 'sd', 'virtio': 'vd', 'fdc': 'fd', + 'sata': 'sd'} devindex = '' i = int(self.index) -- To view, visit https://gerrit.ovirt.org/56803 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ibec60639922a410218e0e48d0d607ce46e5ed4a7 Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Martin Polednik <[email protected]> _______________________________________________ vdsm-patches mailing list [email protected] https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches
