From c0acc3de080abd1efe6460d9255f065807b6fb81 Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Wed, 18 May 2022 10:01:06 -0400 Subject: [PATCH] aarch64/arm64 libvirt VMs should default to SCSI controller The current logic breaks when sushy-tools tries to mount virtual media to an arm64/aarch64 libvirt vm. This is because by default it tries to connect and ide controller, and the only controller option for arm is scsi. This patch ensures that aarch64 type vms will always get a scsi controller. Story: 2009962 Task: 44940 Change-Id: Ib7c3267f401355cf045954e71fe7297b484508be --- sushy_tools/emulator/resources/systems/libvirtdriver.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sushy_tools/emulator/resources/systems/libvirtdriver.py b/sushy_tools/emulator/resources/systems/libvirtdriver.py index 1c15f7e2..de5aae2c 100644 --- a/sushy_tools/emulator/resources/systems/libvirtdriver.py +++ b/sushy_tools/emulator/resources/systems/libvirtdriver.py @@ -913,11 +913,13 @@ class LibvirtDriver(AbstractSystemsDriver): if os_element is not None: type_element = os_element.find('type') if type_element is not None: + arch = type_element.attrib.get('arch') machine = type_element.attrib.get('machine') if machine and 'q35' in machine: # No IDE support for newer q35 machine types return 'sata' - + if arch and 'aarch64' in arch: + return 'scsi' return 'ide' def _add_boot_image(self, domain, domain_tree, device,