Avoid regressions by disallowing the BLOCKDEV capability.
Signed-off-by: Peter Krempa <pkrempa(a)redhat.com>
---
src/qemu/qemu_capabilities.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c
index 4ed995d59f..09d48282a5 100644
--- a/src/qemu/qemu_capabilities.c
+++ b/src/qemu/qemu_capabilities.c
@@ -4332,6 +4332,11 @@ virQEMUCapsInitQMPMonitor(virQEMUCapsPtr qemuCaps,
virQEMUCapsClear(qemuCaps, QEMU_CAPS_SEV_GUEST);
}
+ /* To avoid guest ABI regression, blockdev shall be enabled only when
+ * we are able to pass the custom 'device_id' for SCSI disks and cdroms. */
+ if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_SCSI_DISK_DEVICE_ID))
+ virQEMUCapsClear(qemuCaps, QEMU_CAPS_BLOCKDEV);
+
ret = 0;
cleanup:
return ret;
--
2.20.1