From: Cole Robinson Date: Mon, 6 Apr 2015 13:43:18 -0400 Subject: [PATCH virt-manager] guest: Use sata by default for q35 cdrom, non-virtio (bz #1207834) (cherry picked from commit e29f216503106738328d267b33773f54230c2f86) --- .../compare/virt-install-q35-defaults.xml | 133 +++++++++++++++++++++ virtinst/guest.py | 4 + 2 files changed, 137 insertions(+) create mode 100644 tests/cli-test-xml/compare/virt-install-q35-defaults.xml diff --git a/tests/cli-test-xml/compare/virt-install-q35-defaults.xml b/tests/cli-test-xml/compare/virt-install-q35-defaults.xml new file mode 100644 index 0000000..b87afe1 --- /dev/null +++ b/tests/cli-test-xml/compare/virt-install-q35-defaults.xml @@ -0,0 +1,133 @@ + + foobar + 00000000-1111-2222-3333-444444444444 + 65536 + 65536 + 1 + + hvm + + + + + + + + + + core2duo + + + + + + + destroy + destroy + destroy + + /usr/bin/qemu-kvm + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + foobar + 00000000-1111-2222-3333-444444444444 + 65536 + 65536 + 1 + + hvm + + + + + + + + + core2duo + + + + + + + destroy + restart + restart + + /usr/bin/qemu-kvm + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/virtinst/guest.py b/virtinst/guest.py index 2d0ec87..c0ce305 100644 --- a/virtinst/guest.py +++ b/virtinst/guest.py @@ -875,6 +875,8 @@ class Guest(XMLBuilder): d.bus = "xen" return if not self.os.is_hvm(): + # This likely isn't correct, but it's kind of a catch all + # for virt types we don't know how to handle. d.bus = "ide" return @@ -886,6 +888,8 @@ class Guest(XMLBuilder): d.bus = "scsi" elif self.os.is_arm(): d.bus = "sd" + elif self.os.is_q35(): + d.bus = "sata" else: d.bus = "ide"