]> xenbits.xensource.com Git - libvirt.git/commitdiff
qemu: Support chardevs with ARM virt machines
authorChristoffer Dall <cdall@linaro.org>
Wed, 7 Jun 2017 21:13:30 +0000 (23:13 +0200)
committerAndrea Bolognani <abologna@redhat.com>
Sun, 25 Jun 2017 01:52:50 +0000 (09:52 +0800)
The function to check if -chardev is supported by QEMU was written a
long time ago, where adding chardevs did not make sense on the fixed ARM
platforms.  Since then, we now have a general purpose virt platform,
which should support plugging in any device over PCIe which is supported
in a similar fashion on x86.

Signed-off-by: Christoffer Dall <cdall@linaro.org>
Reviewed-by: Andrea Bolognani <abologna@redhat.com>
src/qemu/qemu_capabilities.c

index 61c9a1066134667e5ae99634dbb7366a63b55a96..12d9477cf1a3c9042534f0293d19efceae808db2 100644 (file)
@@ -5573,6 +5573,11 @@ virQEMUCapsSupportsChardev(const virDomainDef *def,
     if ((def->os.arch != VIR_ARCH_ARMV7L) && (def->os.arch != VIR_ARCH_AARCH64))
         return true;
 
+    /* The virt machine has a PCIe bus and allows plugging in the same type of
+     * devices as x86 systems do on a PCIe bus. */
+    if (qemuDomainIsVirt(def))
+        return true;
+
     /* This may not be true for all ARM machine types, but at least
      * the only supported non-virtio serial devices of vexpress and versatile
      * don't have the -chardev property wired up. */