diff --git a/ui/addhardware.ui b/ui/addhardware.ui index 00321c4a8..d72935b7f 100644 --- a/ui/addhardware.ui +++ b/ui/addhardware.ui @@ -243,30 +243,6 @@ 0 - - - True - False - start - _IO mode: - True - storage-io - - - 0 - 1 - - - - - True - False - - - 1 - 1 - - True @@ -278,7 +254,7 @@ 0 - 2 + 1 @@ -288,7 +264,7 @@ 1 - 2 + 1 @@ -302,7 +278,7 @@ 0 - 3 + 2 @@ -312,33 +288,7 @@ 1 - 3 - - - - - True - False - end - Persistent _Reservations: - True - disk-pr-checkbox - - - 0 - 4 - - - - - True - True - False - False - - - 1 - 4 + 2 diff --git a/virtManager/addhardware.py b/virtManager/addhardware.py index cfa0cffe8..5ed07ca18 100644 --- a/virtManager/addhardware.py +++ b/virtManager/addhardware.py @@ -196,7 +196,6 @@ class vmmAddHardware(vmmGObjectUI): self.build_disk_bus_combo(self.vm, self.widget("storage-bustype")) self._build_disk_device_combo() self.build_disk_cache_combo(self.vm, self.widget("storage-cache")) - self.build_disk_io_combo(self.vm, self.widget("storage-io")) self.build_disk_discard_combo(self.vm, self.widget("storage-discard")) self.build_disk_detect_zeroes_combo(self.vm, self.widget("storage-detect-zeroes")) @@ -733,13 +732,6 @@ class vmmAddHardware(vmmGObjectUI): values.append([m, m]) _build_combo(combo, values, sort=False) - @staticmethod - def build_disk_io_combo(_vm, combo): - values = [[None, _("Hypervisor default")]] - for m in DeviceDisk.IO_MODES: - values.append([m, m]) - _build_combo(combo, values, sort=False) - @staticmethod def build_disk_discard_combo(_vm, combo): values = [[None, _("Hypervisor default")]] @@ -1140,11 +1132,6 @@ class vmmAddHardware(vmmGObjectUI): self.widget("storage-devtype")) self._refresh_disk_bus(devtype) - # Reset the status of disk-pr-checkbox to inactive - self.widget("disk-pr-checkbox").set_active(False) - is_lun = devtype == "lun" - uiutil.set_grid_row_visible(self.widget("disk-pr-checkbox"), is_lun) - allow_create = devtype not in ["cdrom", "floppy"] self.addstorage.widget("storage-create-box").set_sensitive( allow_create) @@ -1549,14 +1536,10 @@ class vmmAddHardware(vmmGObjectUI): self.widget("storage-devtype")) cache = uiutil.get_list_selection( self.widget("storage-cache")) - io = uiutil.get_list_selection( - self.widget("storage-io")) discard = uiutil.get_list_selection( self.widget("storage-discard")) detect_zeroes = uiutil.get_list_selection( self.widget("storage-detect-zeroes")) - if device == "lun": - reservations_managed = self.widget("disk-pr-checkbox").get_active() controller_model = None if (bus == "scsi" and @@ -1572,14 +1555,10 @@ class vmmAddHardware(vmmGObjectUI): disk.bus = bus if cache: disk.driver_cache = cache - if io: - disk.driver_io = io if discard: disk.driver_discard = discard if detect_zeroes: disk.driver_detect_zeroes = detect_zeroes - if device == "lun" and reservations_managed: - disk.reservations_managed = "yes" # Generate target disks = (self.vm.xmlobj.devices.disk + diff --git a/virtinst/devices/disk.py b/virtinst/devices/disk.py index cfe6ae914..cf5f31b8a 100644 --- a/virtinst/devices/disk.py +++ b/virtinst/devices/disk.py @@ -78,7 +78,7 @@ class DeviceDisk(Device): IO_MODE_NATIVE = "native" IO_MODE_THREADS = "threads" - IO_MODES = [IO_MODE_NATIVE, IO_MODE_THREADS] + @staticmethod def path_definitely_exists(conn, path):