if (strstr(help, "-netdev")) {
/* Disable -netdev on 0.12 since although it exists,
* the corresponding netdev_add/remove monitor commands
- * do not, and we need them to be able todo hotplug */
+ * do not, and we need them to be able to do hotplug.
+ * But see below about RHEL build. */
if (version >= 13000)
qemuCapsSet(flags, QEMU_CAPS_NETDEV);
}
/* While JSON mode was available in 0.12.0, it was too
* incomplete to contemplate using. The 0.13.0 release
* is good enough to use, even though it lacks one or
- * two features. The benefits of JSON mode now outweigh
- * the downside.
+ * two features. This is also true of versions of qemu
+ * built for RHEL, labeled 0.12.1, but with extra text
+ * in the help output that mentions that features were
+ * backported for libvirt. The benefits of JSON mode now
+ * outweigh the downside.
*/
#if HAVE_YAJL
- if (version >= 13000)
+ if (version >= 13000) {
qemuCapsSet(flags, QEMU_CAPS_MONITOR_JSON);
+ } else if (version >= 12000 &&
+ strstr(help, "libvirt")) {
+ qemuCapsSet(flags, QEMU_CAPS_MONITOR_JSON);
+ qemuCapsSet(flags, QEMU_CAPS_NETDEV);
+ }
#endif
if (version >= 13000)
QEMU_CAPS_MIGRATE_QEMU_UNIX,
QEMU_CAPS_CHARDEV,
QEMU_CAPS_ENABLE_KVM,
+ QEMU_CAPS_MONITOR_JSON,
QEMU_CAPS_BALLOON,
QEMU_CAPS_DEVICE,
QEMU_CAPS_SMP_TOPOLOGY,
+ QEMU_CAPS_NETDEV,
QEMU_CAPS_RTC,
QEMU_CAPS_VHOST_NET,
QEMU_CAPS_NO_KVM_PIT,
QEMU_CAPS_MIGRATE_QEMU_UNIX,
QEMU_CAPS_CHARDEV,
QEMU_CAPS_ENABLE_KVM,
+ QEMU_CAPS_MONITOR_JSON,
QEMU_CAPS_BALLOON,
QEMU_CAPS_DEVICE,
QEMU_CAPS_SMP_TOPOLOGY,
+ QEMU_CAPS_NETDEV,
QEMU_CAPS_RTC,
QEMU_CAPS_VHOST_NET,
QEMU_CAPS_NO_KVM_PIT,
QEMU_CAPS_CHARDEV,
QEMU_CAPS_ENABLE_KVM,
QEMU_CAPS_BALLOON,
+ QEMU_CAPS_MONITOR_JSON,
QEMU_CAPS_DEVICE,
QEMU_CAPS_SMP_TOPOLOGY,
+ QEMU_CAPS_NETDEV,
QEMU_CAPS_RTC,
QEMU_CAPS_VHOST_NET,
QEMU_CAPS_NO_KVM_PIT,