QEMU 2.12 introduced a new vfio-pci device option 'display=on/off/auto'.
Initially, libvirt is only going to support values on/off only, as we
don't want to predict what the intended usage of the mediated device
will be and most importantly, what kind of vfio display implementation
to use - dmabuf vs vfio region mapping as there's no convenient way for
us to find out what implementation the device's underlying driver
supports.
Signed-off-by: Erik Skultety <eskultet(a)redhat.com>
---
src/qemu/qemu_capabilities.c | 2 ++
src/qemu/qemu_capabilities.h | 1 +
tests/qemucapabilitiesdata/caps_2.12.0.aarch64.xml | 1 +
tests/qemucapabilitiesdata/caps_2.12.0.ppc64.xml | 1 +
tests/qemucapabilitiesdata/caps_2.12.0.s390x.xml | 1 +
tests/qemucapabilitiesdata/caps_2.12.0.x86_64.xml | 1 +
6 files changed, 7 insertions(+)
diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c
index e2e76e4dd8..7c08991103 100644
--- a/src/qemu/qemu_capabilities.c
+++ b/src/qemu/qemu_capabilities.c
@@ -493,6 +493,7 @@ VIR_ENUM_IMPL(virQEMUCaps, QEMU_CAPS_LAST,
/* 305 */
"vhost-vsock",
+ "vfio-pci.display",
);
@@ -1179,6 +1180,7 @@ static struct virQEMUCapsStringFlags
virQEMUCapsDevicePropsPCIAssign[] = {
static struct virQEMUCapsStringFlags virQEMUCapsDevicePropsVfioPCI[] = {
{ "bootindex", QEMU_CAPS_VFIO_PCI_BOOTINDEX },
+ { "display", QEMU_CAPS_VFIO_PCI_DISPLAY },
};
static struct virQEMUCapsStringFlags virQEMUCapsDevicePropsSCSIDisk[] = {
diff --git a/src/qemu/qemu_capabilities.h b/src/qemu/qemu_capabilities.h
index f2aecefb9b..07cbe58789 100644
--- a/src/qemu/qemu_capabilities.h
+++ b/src/qemu/qemu_capabilities.h
@@ -477,6 +477,7 @@ typedef enum { /* virQEMUCapsFlags grouping marker for syntax-check
*/
/* 305 */
QEMU_CAPS_DEVICE_VHOST_VSOCK, /* -device vhost-vsock-* */
+ QEMU_CAPS_VFIO_PCI_DISPLAY, /* -device vfio-pci.display */
QEMU_CAPS_LAST /* this must always be the last item */
} virQEMUCapsFlags;
diff --git a/tests/qemucapabilitiesdata/caps_2.12.0.aarch64.xml
b/tests/qemucapabilitiesdata/caps_2.12.0.aarch64.xml
index f511bcb58c..3dba3e3b27 100644
--- a/tests/qemucapabilitiesdata/caps_2.12.0.aarch64.xml
+++ b/tests/qemucapabilitiesdata/caps_2.12.0.aarch64.xml
@@ -167,6 +167,7 @@
<flag name='hda-output'/>
<flag name='blockdev-del'/>
<flag name='vhost-vsock'/>
+ <flag name='vfio-pci.display'/>
<version>2011090</version>
<kvmVersion>0</kvmVersion>
<microcodeVersion>343099</microcodeVersion>
diff --git a/tests/qemucapabilitiesdata/caps_2.12.0.ppc64.xml
b/tests/qemucapabilitiesdata/caps_2.12.0.ppc64.xml
index 37813ad0b1..13634db45f 100644
--- a/tests/qemucapabilitiesdata/caps_2.12.0.ppc64.xml
+++ b/tests/qemucapabilitiesdata/caps_2.12.0.ppc64.xml
@@ -164,6 +164,7 @@
<flag name='hda-output'/>
<flag name='blockdev-del'/>
<flag name='vhost-vsock'/>
+ <flag name='vfio-pci.display'/>
<version>2011090</version>
<kvmVersion>0</kvmVersion>
<microcodeVersion>419968</microcodeVersion>
diff --git a/tests/qemucapabilitiesdata/caps_2.12.0.s390x.xml
b/tests/qemucapabilitiesdata/caps_2.12.0.s390x.xml
index 3191e9ba95..5ff96afc86 100644
--- a/tests/qemucapabilitiesdata/caps_2.12.0.s390x.xml
+++ b/tests/qemucapabilitiesdata/caps_2.12.0.s390x.xml
@@ -131,6 +131,7 @@
<flag name='screendump_device'/>
<flag name='blockdev-del'/>
<flag name='vhost-vsock'/>
+ <flag name='vfio-pci.display'/>
<version>2012000</version>
<kvmVersion>0</kvmVersion>
<microcodeVersion>371055</microcodeVersion>
diff --git a/tests/qemucapabilitiesdata/caps_2.12.0.x86_64.xml
b/tests/qemucapabilitiesdata/caps_2.12.0.x86_64.xml
index 964b9e8fa6..5aa6b2bc3d 100644
--- a/tests/qemucapabilitiesdata/caps_2.12.0.x86_64.xml
+++ b/tests/qemucapabilitiesdata/caps_2.12.0.x86_64.xml
@@ -206,6 +206,7 @@
<flag name='blockdev-del'/>
<flag name='vmgenid'/>
<flag name='vhost-vsock'/>
+ <flag name='vfio-pci.display'/>
<version>2011090</version>
<kvmVersion>0</kvmVersion>
<microcodeVersion>390813</microcodeVersion>
--
2.14.3