提交 5c62d6c4 编写于 作者: J Ján Tomko

qemu: add capabilities for virtio input devices

Add capabilities for virtio-keyboard, virtio-mouse
and virtio-tablet devices:

name "virtio-keyboard-device", bus virtio-bus
name "virtio-keyboard-pci", bus PCI
name "virtio-mouse-device", bus virtio-bus
name "virtio-mouse-pci", bus PCI
name "virtio-tablet-device", bus virtio-bus
name "virtio-tablet-pci", bus PCI

Map both -device and -pci versions of the device to one capability.

https://bugzilla.redhat.com/show_bug.cgi?id=1231114
上级 cb974262
......@@ -303,6 +303,10 @@ VIR_ENUM_IMPL(virQEMUCaps, QEMU_CAPS_LAST,
"incoming-defer", /* 200 */
"virtio-gpu",
"virtio-gpu.virgl",
"virtio-keyboard",
"virtio-mouse",
"virtio-tablet", /* 205 */
);
......@@ -1547,6 +1551,12 @@ struct virQEMUCapsStringFlags virQEMUCapsObjectTypes[] = {
{ "virtio-net-device", QEMU_CAPS_DEVICE_VIRTIO_NET },
{ "virtio-gpu-pci", QEMU_CAPS_DEVICE_VIRTIO_GPU },
{ "virtio-gpu-device", QEMU_CAPS_DEVICE_VIRTIO_GPU },
{ "virtio-keyboard-device", QEMU_CAPS_VIRTIO_KEYBOARD },
{ "virtio-keyboard-pci", QEMU_CAPS_VIRTIO_KEYBOARD },
{ "virtio-mouse-device", QEMU_CAPS_VIRTIO_MOUSE },
{ "virtio-mouse-pci", QEMU_CAPS_VIRTIO_MOUSE },
{ "virtio-tablet-device", QEMU_CAPS_VIRTIO_TABLET },
{ "virtio-tablet-pci", QEMU_CAPS_VIRTIO_TABLET },
};
static struct virQEMUCapsStringFlags virQEMUCapsObjectPropsVirtioBlk[] = {
......
......@@ -329,6 +329,11 @@ typedef enum {
QEMU_CAPS_INCOMING_DEFER, /* -incoming defer and migrate_incoming */
QEMU_CAPS_DEVICE_VIRTIO_GPU, /* -device virtio-gpu-* & virtio-vga */
QEMU_CAPS_DEVICE_VIRTIO_GPU_VIRGL, /* -device virtio-gpu-*.virgl */
QEMU_CAPS_VIRTIO_KEYBOARD, /* -device virtio-keyboard-{device,pci} */
QEMU_CAPS_VIRTIO_MOUSE, /* -device virtio-mouse-{device,pci} */
/* 205 */
QEMU_CAPS_VIRTIO_TABLET, /* -device virtio-tablet-{device,pci} */
QEMU_CAPS_LAST /* this must always be the last item */
} virQEMUCapsFlags;
......
......@@ -163,4 +163,7 @@
<flag name='virtio-net'/>
<flag name='incoming-defer'/>
<flag name='virtio-gpu'/>
<flag name='virtio-keyboard'/>
<flag name='virtio-mouse'/>
<flag name='virtio-tablet'/>
</qemuCaps>
......@@ -164,4 +164,7 @@
<flag name='incoming-defer'/>
<flag name='virtio-gpu'/>
<flag name='virtio-gpu.virgl'/>
<flag name='virtio-keyboard'/>
<flag name='virtio-mouse'/>
<flag name='virtio-tablet'/>
</qemuCaps>
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册