The new names comply more with the fact that they are all members of
enum qemuCapsFlags.
---
src/qemu/qemu_capabilities.c | 128 ++++----
src/qemu/qemu_capabilities.h | 120 ++++----
src/qemu/qemu_command.c | 246 ++++++++--------
src/qemu/qemu_driver.c | 24 +-
src/qemu/qemu_hotplug.c | 86 +++---
tests/qemuargv2xmltest.c | 2 +-
tests/qemuhelptest.c | 654 +++++++++++++++++++++---------------------
tests/qemuxml2argvtest.c | 302 ++++++++++----------
8 files changed, 781 insertions(+), 781 deletions(-)
diff --git a/src/qemu/qemu_capabilities.c b/src/qemu/qemu_capabilities.c
index 0e1f79c..9e0b440 100644
--- a/src/qemu/qemu_capabilities.c
+++ b/src/qemu/qemu_capabilities.c
@@ -389,7 +389,7 @@ qemuCapsProbeCPUModels(const char *qemu,
}
cmd = virCommandNewArgList(qemu, "-cpu", "?", NULL);
- if (qemuCmdFlags & QEMUD_CMD_FLAG_NODEFCONFIG)
+ if (qemuCmdFlags & QEMU_CAPS_NODEFCONFIG)
virCommandAddArg(cmd, "-nodefconfig");
virCommandAddEnvPassCommon(cmd);
virCommandSetOutputBuffer(cmd, &output);
@@ -548,7 +548,7 @@ qemuCapsInitGuest(virCapsPtr caps,
goto error;
if (qemuCapsExtractVersionInfo(binary, NULL, &qemuCmdFlags) < 0 ||
- ((qemuCmdFlags & QEMUD_CMD_FLAG_BOOTINDEX) &&
+ ((qemuCmdFlags & QEMU_CAPS_BOOTINDEX) &&
!virCapabilitiesAddGuestFeature(guest, "deviceboot", 1, 0)))
goto error;
@@ -780,119 +780,119 @@ qemuCapsComputeCmdFlags(const char *help,
const char *p;
if (strstr(help, "-no-kqemu"))
- flags |= QEMUD_CMD_FLAG_KQEMU;
+ flags |= QEMU_CAPS_KQEMU;
if (strstr(help, "-enable-kqemu"))
- flags |= QEMUD_CMD_FLAG_ENABLE_KQEMU;
+ flags |= QEMU_CAPS_ENABLE_KQEMU;
if (strstr(help, "-no-kvm"))
- flags |= QEMUD_CMD_FLAG_KVM;
+ flags |= QEMU_CAPS_KVM;
if (strstr(help, "-enable-kvm"))
- flags |= QEMUD_CMD_FLAG_ENABLE_KVM;
+ flags |= QEMU_CAPS_ENABLE_KVM;
if (strstr(help, "-no-reboot"))
- flags |= QEMUD_CMD_FLAG_NO_REBOOT;
+ flags |= QEMU_CAPS_NO_REBOOT;
if (strstr(help, "-name")) {
- flags |= QEMUD_CMD_FLAG_NAME;
+ flags |= QEMU_CAPS_NAME;
if (strstr(help, ",process="))
- flags |= QEMUD_CMD_FLAG_NAME_PROCESS;
+ flags |= QEMU_CAPS_NAME_PROCESS;
}
if (strstr(help, "-uuid"))
- flags |= QEMUD_CMD_FLAG_UUID;
+ flags |= QEMU_CAPS_UUID;
if (strstr(help, "-xen-domid"))
- flags |= QEMUD_CMD_FLAG_XEN_DOMID;
+ flags |= QEMU_CAPS_XEN_DOMID;
else if (strstr(help, "-domid"))
- flags |= QEMUD_CMD_FLAG_DOMID;
+ flags |= QEMU_CAPS_DOMID;
if (strstr(help, "-drive")) {
- flags |= QEMUD_CMD_FLAG_DRIVE;
+ flags |= QEMU_CAPS_DRIVE;
if (strstr(help, "cache=") &&
!strstr(help, "cache=on|off"))
- flags |= QEMUD_CMD_FLAG_DRIVE_CACHE_V2;
+ flags |= QEMU_CAPS_DRIVE_CACHE_V2;
if (strstr(help, "format="))
- flags |= QEMUD_CMD_FLAG_DRIVE_FORMAT;
+ flags |= QEMU_CAPS_DRIVE_FORMAT;
if (strstr(help, "readonly="))
- flags |= QEMUD_CMD_FLAG_DRIVE_READONLY;
+ flags |= QEMU_CAPS_DRIVE_READONLY;
if (strstr(help, "aio=threads|native"))
- flags |= QEMUD_CMD_FLAG_DRIVE_AIO;
+ flags |= QEMU_CAPS_DRIVE_AIO;
}
if ((p = strstr(help, "-vga")) && !strstr(help,
"-std-vga")) {
const char *nl = strstr(p, "\n");
- flags |= QEMUD_CMD_FLAG_VGA;
+ flags |= QEMU_CAPS_VGA;
if (strstr(p, "|qxl"))
- flags |= QEMUD_CMD_FLAG_VGA_QXL;
+ flags |= QEMU_CAPS_VGA_QXL;
if ((p = strstr(p, "|none")) && p < nl)
- flags |= QEMUD_CMD_FLAG_VGA_NONE;
+ flags |= QEMU_CAPS_VGA_NONE;
}
if (strstr(help, "-spice"))
- flags |= QEMUD_CMD_FLAG_SPICE;
+ flags |= QEMU_CAPS_SPICE;
if (strstr(help, "boot=on"))
- flags |= QEMUD_CMD_FLAG_DRIVE_BOOT;
+ flags |= QEMU_CAPS_DRIVE_BOOT;
if (strstr(help, "serial=s"))
- flags |= QEMUD_CMD_FLAG_DRIVE_SERIAL;
+ flags |= QEMU_CAPS_DRIVE_SERIAL;
if (strstr(help, "-pcidevice"))
- flags |= QEMUD_CMD_FLAG_PCIDEVICE;
+ flags |= QEMU_CAPS_PCIDEVICE;
if (strstr(help, "-mem-path"))
- flags |= QEMUD_CMD_FLAG_MEM_PATH;
+ flags |= QEMU_CAPS_MEM_PATH;
if (strstr(help, "-chardev")) {
- flags |= QEMUD_CMD_FLAG_CHARDEV;
+ flags |= QEMU_CAPS_CHARDEV;
if (strstr(help, "-chardev spicevmc"))
- flags |= QEMUD_CMD_FLAG_CHARDEV_SPICEVMC;
+ flags |= QEMU_CAPS_CHARDEV_SPICEVMC;
}
if (strstr(help, "-balloon"))
- flags |= QEMUD_CMD_FLAG_BALLOON;
+ flags |= QEMU_CAPS_BALLOON;
if (strstr(help, "-device")) {
- flags |= QEMUD_CMD_FLAG_DEVICE;
+ flags |= QEMU_CAPS_DEVICE;
/*
* When -device was introduced, qemu already supported drive's
* readonly option but didn't advertise that.
*/
- flags |= QEMUD_CMD_FLAG_DRIVE_READONLY;
+ flags |= QEMU_CAPS_DRIVE_READONLY;
}
if (strstr(help, "-nodefconfig"))
- flags |= QEMUD_CMD_FLAG_NODEFCONFIG;
+ flags |= QEMU_CAPS_NODEFCONFIG;
/* The trailing ' ' is important to avoid a bogus match */
if (strstr(help, "-rtc "))
- flags |= QEMUD_CMD_FLAG_RTC;
+ flags |= QEMU_CAPS_RTC;
/* to wit */
if (strstr(help, "-rtc-td-hack"))
- flags |= QEMUD_CMD_FLAG_RTC_TD_HACK;
+ flags |= QEMU_CAPS_RTC_TD_HACK;
if (strstr(help, "-no-hpet"))
- flags |= QEMUD_CMD_FLAG_NO_HPET;
+ flags |= QEMU_CAPS_NO_HPET;
if (strstr(help, "-no-kvm-pit-reinjection"))
- flags |= QEMUD_CMD_FLAG_NO_KVM_PIT;
+ flags |= QEMU_CAPS_NO_KVM_PIT;
if (strstr(help, "-tdf"))
- flags |= QEMUD_CMD_FLAG_TDF;
+ flags |= QEMU_CAPS_TDF;
if (strstr(help, "-enable-nesting"))
- flags |= QEMUD_CMD_FLAG_NESTING;
+ flags |= QEMU_CAPS_NESTING;
if (strstr(help, ",menu=on"))
- flags |= QEMUD_CMD_FLAG_BOOT_MENU;
+ flags |= QEMU_CAPS_BOOT_MENU;
if (strstr(help, "-fsdev"))
- flags |= QEMUD_CMD_FLAG_FSDEV;
+ flags |= QEMU_CAPS_FSDEV;
if (strstr(help, "-smbios type"))
- flags |= QEMUD_CMD_FLAG_SMBIOS_TYPE;
+ flags |= QEMU_CAPS_SMBIOS_TYPE;
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 */
if (version >= 13000)
- flags |= QEMUD_CMD_FLAG_NETDEV;
+ flags |= QEMU_CAPS_NETDEV;
}
if (strstr(help, "-sdl"))
- flags |= QEMUD_CMD_FLAG_SDL;
+ flags |= QEMU_CAPS_SDL;
if (strstr(help, "cores=") &&
strstr(help, "threads=") &&
strstr(help, "sockets="))
- flags |= QEMUD_CMD_FLAG_SMP_TOPOLOGY;
+ flags |= QEMU_CAPS_SMP_TOPOLOGY;
if (version >= 9000)
- flags |= QEMUD_CMD_FLAG_VNC_COLON;
+ flags |= QEMU_CAPS_VNC_COLON;
if (is_kvm && (version >= 10000 || kvm_version >= 74))
- flags |= QEMUD_CMD_FLAG_VNET_HDR;
+ flags |= QEMU_CAPS_VNET_HDR;
if (is_kvm && strstr(help, ",vhost=")) {
- flags |= QEMUD_CMD_FLAG_VNET_HOST;
+ flags |= QEMU_CAPS_VNET_HOST;
}
/*
@@ -908,22 +908,22 @@ qemuCapsComputeCmdFlags(const char *help,
* while waiting for data, so pretend it doesn't exist
*/
if (version >= 10000) {
- flags |= QEMUD_CMD_FLAG_MIGRATE_QEMU_TCP;
- flags |= QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC;
+ flags |= QEMU_CAPS_MIGRATE_QEMU_TCP;
+ flags |= QEMU_CAPS_MIGRATE_QEMU_EXEC;
if (version >= 12000) {
- flags |= QEMUD_CMD_FLAG_MIGRATE_QEMU_UNIX;
- flags |= QEMUD_CMD_FLAG_MIGRATE_QEMU_FD;
+ flags |= QEMU_CAPS_MIGRATE_QEMU_UNIX;
+ flags |= QEMU_CAPS_MIGRATE_QEMU_FD;
}
} else if (kvm_version >= 79) {
- flags |= QEMUD_CMD_FLAG_MIGRATE_QEMU_TCP;
+ flags |= QEMU_CAPS_MIGRATE_QEMU_TCP;
if (kvm_version >= 80)
- flags |= QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC;
+ flags |= QEMU_CAPS_MIGRATE_QEMU_EXEC;
} else if (kvm_version > 0) {
- flags |= QEMUD_CMD_FLAG_MIGRATE_KVM_STDIO;
+ flags |= QEMU_CAPS_MIGRATE_KVM_STDIO;
}
if (version >= 10000)
- flags |= QEMUD_CMD_FLAG_0_10;
+ flags |= QEMU_CAPS_0_10;
/* While JSON mode was available in 0.12.0, it was too
* incomplete to contemplate using. The 0.13.0 release
@@ -932,7 +932,7 @@ qemuCapsComputeCmdFlags(const char *help,
* the downside.
*/
if (version >= 13000)
- flags |= QEMUD_CMD_FLAG_MONITOR_JSON;
+ flags |= QEMU_CAPS_MONITOR_JSON;
return flags;
}
@@ -1086,23 +1086,23 @@ qemuCapsParseDeviceStr(const char *str, unsigned long long
*flags)
{
/* Which devices exist. */
if (strstr(str, "name \"hda-duplex\""))
- *flags |= QEMUD_CMD_FLAG_HDA_DUPLEX;
+ *flags |= QEMU_CAPS_HDA_DUPLEX;
if (strstr(str, "name \"ccid-card-emulated\""))
- *flags |= QEMUD_CMD_FLAG_CCID_EMULATED;
+ *flags |= QEMU_CAPS_CCID_EMULATED;
if (strstr(str, "name \"ccid-card-passthru\""))
- *flags |= QEMUD_CMD_FLAG_CCID_PASSTHRU;
+ *flags |= QEMU_CAPS_CCID_PASSTHRU;
/* Prefer -chardev spicevmc (detected earlier) over -device spicevmc */
- if (!(*flags & QEMUD_CMD_FLAG_CHARDEV_SPICEVMC) &&
+ if (!(*flags & QEMU_CAPS_CHARDEV_SPICEVMC) &&
strstr(str, "name \"spicevmc\""))
- *flags |= QEMUD_CMD_FLAG_DEVICE_SPICEVMC;
+ *flags |= QEMU_CAPS_DEVICE_SPICEVMC;
/* Features of given devices. */
if (strstr(str, "pci-assign.configfd"))
- *flags |= QEMUD_CMD_FLAG_PCI_CONFIGFD;
+ *flags |= QEMU_CAPS_PCI_CONFIGFD;
if (strstr(str, "virtio-blk-pci.bootindex")) {
- *flags |= QEMUD_CMD_FLAG_BOOTINDEX;
+ *flags |= QEMU_CAPS_BOOTINDEX;
if (strstr(str, "pci-assign.bootindex"))
- *flags |= QEMUD_CMD_FLAG_PCI_BOOTINDEX;
+ *flags |= QEMU_CAPS_PCI_BOOTINDEX;
}
return 0;
@@ -1146,7 +1146,7 @@ int qemuCapsExtractVersionInfo(const char *qemu,
/* qemuCapsExtractDeviceStr will only set additional flags if qemu
* understands the 0.13.0+ notion of "-device driver,". */
- if ((flags & QEMUD_CMD_FLAG_DEVICE) &&
+ if ((flags & QEMU_CAPS_DEVICE) &&
strstr(help, "-device driver,?") &&
qemuCapsExtractDeviceStr(qemu, &flags) < 0)
goto cleanup;
diff --git a/src/qemu/qemu_capabilities.h b/src/qemu/qemu_capabilities.h
index dd39b3b..e839d63 100644
--- a/src/qemu/qemu_capabilities.h
+++ b/src/qemu/qemu_capabilities.h
@@ -28,70 +28,70 @@
/* Internal flags to keep track of qemu command line capabilities */
enum qemuCapsFlags {
- QEMUD_CMD_FLAG_KQEMU = (1 << 0), /* Whether KQEMU is compiled in */
- QEMUD_CMD_FLAG_VNC_COLON = (1 << 1), /* Does the VNC take just port, or
address + display */
- QEMUD_CMD_FLAG_NO_REBOOT = (1 << 2), /* Is the -no-reboot flag available
*/
- QEMUD_CMD_FLAG_DRIVE = (1 << 3), /* Is the new -drive arg available
*/
- QEMUD_CMD_FLAG_DRIVE_BOOT = (1 << 4), /* Does -drive support boot=on */
- QEMUD_CMD_FLAG_NAME = (1 << 5), /* Is the -name flag available */
- QEMUD_CMD_FLAG_UUID = (1 << 6), /* Is the -uuid flag available */
- QEMUD_CMD_FLAG_DOMID = (1 << 7), /* Xenner only, special -domid flag
available */
- QEMUD_CMD_FLAG_VNET_HDR = (1 << 8),
- QEMUD_CMD_FLAG_MIGRATE_KVM_STDIO = (1 << 9), /* Original migration code from
KVM. Also had tcp, but we can't use that
+ QEMU_CAPS_KQEMU = (1 << 0), /* Whether KQEMU is compiled in */
+ QEMU_CAPS_VNC_COLON = (1 << 1), /* Does the VNC take just port, or address
+ display */
+ QEMU_CAPS_NO_REBOOT = (1 << 2), /* Is the -no-reboot flag available */
+ QEMU_CAPS_DRIVE = (1 << 3), /* Is the new -drive arg available */
+ QEMU_CAPS_DRIVE_BOOT = (1 << 4), /* Does -drive support boot=on */
+ QEMU_CAPS_NAME = (1 << 5), /* Is the -name flag available */
+ QEMU_CAPS_UUID = (1 << 6), /* Is the -uuid flag available */
+ QEMU_CAPS_DOMID = (1 << 7), /* Xenner only, special -domid flag
available */
+ QEMU_CAPS_VNET_HDR = (1 << 8),
+ QEMU_CAPS_MIGRATE_KVM_STDIO = (1 << 9), /* Original migration code from KVM.
Also had tcp, but we can't use that
* since it had a design bug blocking
the entire monitor console */
- QEMUD_CMD_FLAG_MIGRATE_QEMU_TCP = (1 << 10), /* New migration syntax after
merge to QEMU with TCP transport */
- QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC = (1 << 11), /* New migration syntax after
merge to QEMU with EXEC transport */
- QEMUD_CMD_FLAG_DRIVE_CACHE_V2 = (1 << 12), /* Is the cache= flag wanting new
v2 values */
- QEMUD_CMD_FLAG_KVM = (1 << 13), /* Whether KVM is compiled in */
- QEMUD_CMD_FLAG_DRIVE_FORMAT = (1 << 14), /* Is -drive format= avail */
- QEMUD_CMD_FLAG_VGA = (1 << 15), /* Is -vga avail */
+ QEMU_CAPS_MIGRATE_QEMU_TCP = (1 << 10), /* New migration syntax after merge to
QEMU with TCP transport */
+ QEMU_CAPS_MIGRATE_QEMU_EXEC = (1 << 11), /* New migration syntax after merge to
QEMU with EXEC transport */
+ QEMU_CAPS_DRIVE_CACHE_V2 = (1 << 12), /* Is the cache= flag wanting new v2
values */
+ QEMU_CAPS_KVM = (1 << 13), /* Whether KVM is compiled in */
+ QEMU_CAPS_DRIVE_FORMAT = (1 << 14), /* Is -drive format= avail */
+ QEMU_CAPS_VGA = (1 << 15), /* Is -vga avail */
/* features added in qemu-0.10.0 or later */
- QEMUD_CMD_FLAG_0_10 = (1 << 16),
- QEMUD_CMD_FLAG_NET_NAME = QEMUD_CMD_FLAG_0_10, /* -net ...,name=str */
- QEMUD_CMD_FLAG_HOST_NET_ADD = QEMUD_CMD_FLAG_0_10, /* host_net_add monitor command
*/
+ QEMU_CAPS_0_10 = (1 << 16),
+ QEMU_CAPS_NET_NAME = QEMU_CAPS_0_10, /* -net ...,name=str */
+ QEMU_CAPS_HOST_NET_ADD = QEMU_CAPS_0_10, /* host_net_add monitor command */
- QEMUD_CMD_FLAG_PCIDEVICE = (1 << 17), /* PCI device assignment only
supported by qemu-kvm */
- QEMUD_CMD_FLAG_MEM_PATH = (1 << 18), /* mmap'ped guest backing
supported */
- QEMUD_CMD_FLAG_DRIVE_SERIAL = (1 << 19), /* -driver serial= available */
- QEMUD_CMD_FLAG_XEN_DOMID = (1 << 20), /* -xen-domid (new style xen
integration) */
- QEMUD_CMD_FLAG_MIGRATE_QEMU_UNIX = (1 << 21), /* Does qemu support unix domain
sockets for migration? */
- QEMUD_CMD_FLAG_CHARDEV = (1 << 22), /* Is the new -chardev arg available
*/
- QEMUD_CMD_FLAG_ENABLE_KVM = (1 << 23), /* Is the -enable-kvm flag available
to "enable KVM full virtualization support" */
- QEMUD_CMD_FLAG_MONITOR_JSON = (1 << 24), /* JSON mode for monitor */
- QEMUD_CMD_FLAG_BALLOON = (1 << 25), /* -balloon available */
- QEMUD_CMD_FLAG_DEVICE = (1 << 26), /* Is the new -device arg available
*/
- QEMUD_CMD_FLAG_SDL = (1 << 27), /* Is the new -sdl arg available */
- QEMUD_CMD_FLAG_SMP_TOPOLOGY = (1 << 28), /* Is sockets=s,cores=c,threads=t
available for -smp? */
- QEMUD_CMD_FLAG_NETDEV = (1 << 29), /* The -netdev flag &
netdev_add/remove monitor commands */
- QEMUD_CMD_FLAG_RTC = (1 << 30), /* The -rtc flag for clock options
*/
- QEMUD_CMD_FLAG_VNET_HOST = (1LL << 31), /* vnet-host support is available
in qemu */
- QEMUD_CMD_FLAG_RTC_TD_HACK = (1LL << 32), /* -rtc-td-hack available */
- QEMUD_CMD_FLAG_NO_HPET = (1LL << 33), /* -no-hpet flag is supported */
- QEMUD_CMD_FLAG_NO_KVM_PIT = (1LL << 34), /* -no-kvm-pit-reinjection
supported */
- QEMUD_CMD_FLAG_TDF = (1LL << 35), /* -tdf flag (user-mode pit
catchup) */
- QEMUD_CMD_FLAG_PCI_CONFIGFD = (1LL << 36), /* pci-assign.configfd */
- QEMUD_CMD_FLAG_NODEFCONFIG = (1LL << 37), /* -nodefconfig */
- QEMUD_CMD_FLAG_BOOT_MENU = (1LL << 38), /* -boot menu=on support */
- QEMUD_CMD_FLAG_ENABLE_KQEMU = (1LL << 39), /* -enable-kqemu flag */
- QEMUD_CMD_FLAG_FSDEV = (1LL << 40), /* -fstype filesystem passthrough
*/
- QEMUD_CMD_FLAG_NESTING = (1LL << 41), /* -enable-nesting (SVM/VMX) */
- QEMUD_CMD_FLAG_NAME_PROCESS = (1LL << 42), /* Is -name process= available */
- QEMUD_CMD_FLAG_DRIVE_READONLY= (1LL << 43), /* -drive readonly=on|off */
- QEMUD_CMD_FLAG_SMBIOS_TYPE = (1LL << 44), /* Is -smbios type= available */
- QEMUD_CMD_FLAG_VGA_QXL = (1LL << 45), /* The 'qxl' arg for
'-vga' */
- QEMUD_CMD_FLAG_SPICE = (1LL << 46), /* Is -spice avail */
- QEMUD_CMD_FLAG_VGA_NONE = (1LL << 47), /* The 'none' arg for
'-vga' */
- QEMUD_CMD_FLAG_MIGRATE_QEMU_FD = (1LL << 48), /* -incoming fd:n */
- QEMUD_CMD_FLAG_BOOTINDEX = (1LL << 49), /* -device bootindex property */
- QEMUD_CMD_FLAG_HDA_DUPLEX = (1LL << 50), /* -device hda-duplex */
- QEMUD_CMD_FLAG_DRIVE_AIO = (1LL << 51), /* -drive aio= supported */
- QEMUD_CMD_FLAG_PCI_MULTIBUS = (1LL << 52), /* bus=pci.0 vs bus=pci */
- QEMUD_CMD_FLAG_PCI_BOOTINDEX = (1LL << 53), /* pci-assign.bootindex */
- QEMUD_CMD_FLAG_CCID_EMULATED = (1LL << 54), /* -device ccid-card-emulated */
- QEMUD_CMD_FLAG_CCID_PASSTHRU = (1LL << 55), /* -device ccid-card-passthru */
- QEMUD_CMD_FLAG_CHARDEV_SPICEVMC = (1LL << 56), /* newer -chardev spicevmc */
- QEMUD_CMD_FLAG_DEVICE_SPICEVMC = (1LL << 57), /* older -device spicevmc*/
+ QEMU_CAPS_PCIDEVICE = (1 << 17), /* PCI device assignment only supported by
qemu-kvm */
+ QEMU_CAPS_MEM_PATH = (1 << 18), /* mmap'ped guest backing supported
*/
+ QEMU_CAPS_DRIVE_SERIAL = (1 << 19), /* -driver serial= available */
+ QEMU_CAPS_XEN_DOMID = (1 << 20), /* -xen-domid (new style xen integration)
*/
+ QEMU_CAPS_MIGRATE_QEMU_UNIX = (1 << 21), /* Does qemu support unix domain
sockets for migration? */
+ QEMU_CAPS_CHARDEV = (1 << 22), /* Is the new -chardev arg available */
+ QEMU_CAPS_ENABLE_KVM = (1 << 23), /* Is the -enable-kvm flag available to
"enable KVM full virtualization support" */
+ QEMU_CAPS_MONITOR_JSON = (1 << 24), /* JSON mode for monitor */
+ QEMU_CAPS_BALLOON = (1 << 25), /* -balloon available */
+ QEMU_CAPS_DEVICE = (1 << 26), /* Is the new -device arg available */
+ QEMU_CAPS_SDL = (1 << 27), /* Is the new -sdl arg available */
+ QEMU_CAPS_SMP_TOPOLOGY = (1 << 28), /* Is sockets=s,cores=c,threads=t
available for -smp? */
+ QEMU_CAPS_NETDEV = (1 << 29), /* The -netdev flag &
netdev_add/remove monitor commands */
+ QEMU_CAPS_RTC = (1 << 30), /* The -rtc flag for clock options */
+ QEMU_CAPS_VNET_HOST = (1LL << 31), /* vnet-host support is available in
qemu */
+ QEMU_CAPS_RTC_TD_HACK = (1LL << 32), /* -rtc-td-hack available */
+ QEMU_CAPS_NO_HPET = (1LL << 33), /* -no-hpet flag is supported */
+ QEMU_CAPS_NO_KVM_PIT = (1LL << 34), /* -no-kvm-pit-reinjection supported */
+ QEMU_CAPS_TDF = (1LL << 35), /* -tdf flag (user-mode pit catchup) */
+ QEMU_CAPS_PCI_CONFIGFD = (1LL << 36), /* pci-assign.configfd */
+ QEMU_CAPS_NODEFCONFIG = (1LL << 37), /* -nodefconfig */
+ QEMU_CAPS_BOOT_MENU = (1LL << 38), /* -boot menu=on support */
+ QEMU_CAPS_ENABLE_KQEMU = (1LL << 39), /* -enable-kqemu flag */
+ QEMU_CAPS_FSDEV = (1LL << 40), /* -fstype filesystem passthrough */
+ QEMU_CAPS_NESTING = (1LL << 41), /* -enable-nesting (SVM/VMX) */
+ QEMU_CAPS_NAME_PROCESS = (1LL << 42), /* Is -name process= available */
+ QEMU_CAPS_DRIVE_READONLY= (1LL << 43), /* -drive readonly=on|off */
+ QEMU_CAPS_SMBIOS_TYPE = (1LL << 44), /* Is -smbios type= available */
+ QEMU_CAPS_VGA_QXL = (1LL << 45), /* The 'qxl' arg for
'-vga' */
+ QEMU_CAPS_SPICE = (1LL << 46), /* Is -spice avail */
+ QEMU_CAPS_VGA_NONE = (1LL << 47), /* The 'none' arg for
'-vga' */
+ QEMU_CAPS_MIGRATE_QEMU_FD = (1LL << 48), /* -incoming fd:n */
+ QEMU_CAPS_BOOTINDEX = (1LL << 49), /* -device bootindex property */
+ QEMU_CAPS_HDA_DUPLEX = (1LL << 50), /* -device hda-duplex */
+ QEMU_CAPS_DRIVE_AIO = (1LL << 51), /* -drive aio= supported */
+ QEMU_CAPS_PCI_MULTIBUS = (1LL << 52), /* bus=pci.0 vs bus=pci */
+ QEMU_CAPS_PCI_BOOTINDEX = (1LL << 53), /* pci-assign.bootindex */
+ QEMU_CAPS_CCID_EMULATED = (1LL << 54), /* -device ccid-card-emulated */
+ QEMU_CAPS_CCID_PASSTHRU = (1LL << 55), /* -device ccid-card-passthru */
+ QEMU_CAPS_CHARDEV_SPICEVMC = (1LL << 56), /* newer -chardev spicevmc */
+ QEMU_CAPS_DEVICE_SPICEVMC = (1LL << 57), /* older -device spicevmc*/
};
virCapsPtr qemuCapsInit(virCapsPtr old_caps);
diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c
index f78ce71..1a9c0fc 100644
--- a/src/qemu/qemu_command.c
+++ b/src/qemu/qemu_command.c
@@ -119,7 +119,7 @@ qemuPhysIfaceConnect(virConnectPtr conn,
int vnet_hdr = 0;
int err;
- if (qemuCmdFlags & QEMUD_CMD_FLAG_VNET_HDR &&
+ if (qemuCmdFlags & QEMU_CAPS_VNET_HDR &&
net->model && STREQ(net->model, "virtio"))
vnet_hdr = 1;
@@ -241,7 +241,7 @@ qemuNetworkIfaceConnect(virConnectPtr conn,
template_ifname = 1;
}
- if (qemuCmdFlags & QEMUD_CMD_FLAG_VNET_HDR &&
+ if (qemuCmdFlags & QEMU_CAPS_VNET_HDR &&
net->model && STREQ(net->model, "virtio"))
vnet_hdr = 1;
@@ -318,9 +318,9 @@ qemuOpenVhostNet(virDomainNetDefPtr net,
/* If qemu doesn't support vhost-net mode (including the -netdev command
* option), don't try to open the device.
*/
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_VNET_HOST &&
- qemuCmdFlags & QEMUD_CMD_FLAG_NETDEV &&
- qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE)) {
+ if (!(qemuCmdFlags & QEMU_CAPS_VNET_HOST &&
+ qemuCmdFlags & QEMU_CAPS_NETDEV &&
+ qemuCmdFlags & QEMU_CAPS_DEVICE)) {
if (net->backend == VIR_DOMAIN_NET_BACKEND_TYPE_VHOST) {
qemuReportError(VIR_ERR_CONFIG_UNSUPPORTED,
"%s", _("vhost-net is not supported with
"
@@ -406,7 +406,7 @@ char *qemuDeviceDriveHostAlias(virDomainDiskDefPtr disk,
{
char *ret;
- if (qemudCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemudCmdFlags & QEMU_CAPS_DEVICE) {
if (virAsprintf(&ret, "%s%s", QEMU_DRIVE_HOST_PREFIX,
disk->info.alias) < 0) {
virReportOOMError();
return NULL;
@@ -502,8 +502,8 @@ no_memory:
int
qemuAssignDeviceDiskAlias(virDomainDiskDefPtr def, unsigned long long qemuCmdFlags)
{
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DRIVE) {
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE)
+ if (qemuCmdFlags & QEMU_CAPS_DRIVE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE)
return qemuAssignDeviceDiskAliasCustom(def);
else
return qemuAssignDeviceDiskAliasFixed(def);
@@ -591,15 +591,15 @@ qemuAssignDeviceAliases(virDomainDefPtr def, unsigned long long
qemuCmdFlags)
if (qemuAssignDeviceDiskAlias(def->disks[i], qemuCmdFlags) < 0)
return -1;
}
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_NET_NAME) ||
- (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE)) {
+ if ((qemuCmdFlags & QEMU_CAPS_NET_NAME) ||
+ (qemuCmdFlags & QEMU_CAPS_DEVICE)) {
for (i = 0; i < def->nnets ; i++) {
if (qemuAssignDeviceNetAlias(def, def->nets[i], i) < 0)
return -1;
}
}
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE))
+ if (!(qemuCmdFlags & QEMU_CAPS_DEVICE))
return 0;
for (i = 0; i < def->nfss ; i++) {
@@ -1119,7 +1119,7 @@ qemuBuildDeviceAddressStr(virBufferPtr buf,
* When QEMU grows support for > 1 PCI domain, then pci.0 change
* to pciNN.0 where NN is the domain number
*/
- if (qemuCmdFlags & QEMUD_CMD_FLAG_PCI_MULTIBUS)
+ if (qemuCmdFlags & QEMU_CAPS_PCI_MULTIBUS)
virBufferVSprintf(buf, ",bus=pci.0,addr=0x%x",
info->addr.pci.slot);
else
virBufferVSprintf(buf, ",bus=pci,addr=0x%x",
info->addr.pci.slot);
@@ -1279,7 +1279,7 @@ qemuBuildDriveStr(virDomainDiskDefPtr disk,
virBufferVSprintf(&opt, "file=%s,", disk->src);
}
}
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE)
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE)
virBufferAddLit(&opt, "if=none");
else
virBufferVSprintf(&opt, "if=%s", bus);
@@ -1287,7 +1287,7 @@ qemuBuildDriveStr(virDomainDiskDefPtr disk,
if (disk->device == VIR_DOMAIN_DISK_DEVICE_CDROM)
virBufferAddLit(&opt, ",media=cdrom");
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
virBufferVSprintf(&opt, ",id=%s%s", QEMU_DRIVE_HOST_PREFIX,
disk->info.alias);
} else {
if (busid == -1 && unitid == -1) {
@@ -1305,14 +1305,14 @@ qemuBuildDriveStr(virDomainDiskDefPtr disk,
disk->bus != VIR_DOMAIN_DISK_BUS_IDE)
virBufferAddLit(&opt, ",boot=on");
if (disk->readonly &&
- qemuCmdFlags & QEMUD_CMD_FLAG_DRIVE_READONLY)
+ qemuCmdFlags & QEMU_CAPS_DRIVE_READONLY)
virBufferAddLit(&opt, ",readonly=on");
if (disk->driverType && *disk->driverType != '\0' &&
disk->type != VIR_DOMAIN_DISK_TYPE_DIR &&
- qemuCmdFlags & QEMUD_CMD_FLAG_DRIVE_FORMAT)
+ qemuCmdFlags & QEMU_CAPS_DRIVE_FORMAT)
virBufferVSprintf(&opt, ",format=%s", disk->driverType);
if (disk->serial &&
- (qemuCmdFlags & QEMUD_CMD_FLAG_DRIVE_SERIAL)) {
+ (qemuCmdFlags & QEMU_CAPS_DRIVE_SERIAL)) {
if (qemuSafeSerialParamValue(disk->serial) < 0)
goto error;
virBufferVSprintf(&opt, ",serial=%s", disk->serial);
@@ -1320,7 +1320,7 @@ qemuBuildDriveStr(virDomainDiskDefPtr disk,
if (disk->cachemode) {
const char *mode =
- (qemuCmdFlags & QEMUD_CMD_FLAG_DRIVE_CACHE_V2) ?
+ (qemuCmdFlags & QEMU_CAPS_DRIVE_CACHE_V2) ?
qemuDiskCacheV2TypeToString(disk->cachemode) :
qemuDiskCacheV1TypeToString(disk->cachemode);
@@ -1329,7 +1329,7 @@ qemuBuildDriveStr(virDomainDiskDefPtr disk,
virBufferAddLit(&opt, ",cache=off");
}
- if (qemuCmdFlags & QEMUD_CMD_FLAG_MONITOR_JSON) {
+ if (qemuCmdFlags & QEMU_CAPS_MONITOR_JSON) {
if (disk->error_policy) {
virBufferVSprintf(&opt, ",werror=%s,rerror=%s",
virDomainDiskErrorPolicyTypeToString(disk->error_policy),
@@ -1338,7 +1338,7 @@ qemuBuildDriveStr(virDomainDiskDefPtr disk,
}
if (disk->iomode) {
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DRIVE_AIO) {
+ if (qemuCmdFlags & QEMU_CAPS_DRIVE_AIO) {
virBufferVSprintf(&opt, ",aio=%s",
virDomainDiskIoTypeToString(disk->iomode));
} else {
@@ -1404,7 +1404,7 @@ qemuBuildDriveDevStr(virDomainDiskDefPtr disk,
}
virBufferVSprintf(&opt, ",drive=%s%s", QEMU_DRIVE_HOST_PREFIX,
disk->info.alias);
virBufferVSprintf(&opt, ",id=%s", disk->info.alias);
- if (disk->bootIndex && (qemuCmdFlags & QEMUD_CMD_FLAG_BOOTINDEX))
+ if (disk->bootIndex && (qemuCmdFlags & QEMU_CAPS_BOOTINDEX))
virBufferVSprintf(&opt, ",bootindex=%d", disk->bootIndex);
if (virBufferError(&opt)) {
@@ -1598,7 +1598,7 @@ qemuBuildNicDevStr(virDomainNetDefPtr net,
net->mac[4], net->mac[5]);
if (qemuBuildDeviceAddressStr(&buf, &net->info, qemuCmdFlags) < 0)
goto error;
- if (net->bootIndex && (qemuCmdFlags & QEMUD_CMD_FLAG_BOOTINDEX))
+ if (net->bootIndex && (qemuCmdFlags & QEMU_CAPS_BOOTINDEX))
virBufferVSprintf(&buf, ",bootindex=%d", net->bootIndex);
if (virBufferError(&buf)) {
@@ -2075,7 +2075,7 @@ qemuBuildChrChardevStr(virDomainChrSourceDefPtr dev, const char
*alias,
break;
case VIR_DOMAIN_CHR_TYPE_SPICEVMC:
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_CHARDEV_SPICEVMC)) {
+ if (!(qemuCmdFlags & QEMU_CAPS_CHARDEV_SPICEVMC)) {
qemuReportError(VIR_ERR_CONFIG_UNSUPPORTED,
_("spicevmc not supported in this QEMU binary"));
goto error;
@@ -2190,7 +2190,7 @@ qemuBuildVirtioSerialPortDevStr(virDomainChrDefPtr dev,
virBuffer buf = VIR_BUFFER_INITIALIZER;
if (dev->deviceType == VIR_DOMAIN_CHR_DEVICE_TYPE_CONSOLE)
virBufferAddLit(&buf, "virtconsole");
- else if ((qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE_SPICEVMC) &&
+ else if ((qemuCmdFlags & QEMU_CAPS_DEVICE_SPICEVMC) &&
dev->source.type == VIR_DOMAIN_CHR_TYPE_SPICEVMC)
virBufferAddLit(&buf, "spicevmc");
else
@@ -2223,7 +2223,7 @@ qemuBuildVirtioSerialPortDevStr(virDomainChrDefPtr dev,
dev->target.name);
goto error;
}
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE_SPICEVMC) &&
+ if ((qemuCmdFlags & QEMU_CAPS_DEVICE_SPICEVMC) &&
dev->source.type == VIR_DOMAIN_CHR_TYPE_SPICEVMC) {
virBufferVSprintf(&buf, ",id=%s", dev->info.alias);
} else {
@@ -2552,7 +2552,7 @@ qemuBuildSmpArgStr(const virDomainDefPtr def,
virBufferVSprintf(&buf, "%u", def->vcpus);
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_SMP_TOPOLOGY)) {
+ if ((qemuCmdFlags & QEMU_CAPS_SMP_TOPOLOGY)) {
if (def->vcpus != def->maxvcpus)
virBufferVSprintf(&buf, ",maxcpus=%u", def->maxvcpus);
/* sockets, cores, and threads are either all zero
@@ -2635,26 +2635,26 @@ qemuBuildCommandLine(virConnectPtr conn,
* do not use boot=on for drives when not using KVM since this
* is not supported at all in upstream QEmu.
*/
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_KVM) &&
+ if ((qemuCmdFlags & QEMU_CAPS_KVM) &&
(def->virtType == VIR_DOMAIN_VIRT_QEMU) &&
- (qemuCmdFlags & QEMUD_CMD_FLAG_DRIVE_BOOT))
- qemuCmdFlags -= QEMUD_CMD_FLAG_DRIVE_BOOT;
+ (qemuCmdFlags & QEMU_CAPS_DRIVE_BOOT))
+ qemuCmdFlags -= QEMU_CAPS_DRIVE_BOOT;
switch (def->virtType) {
case VIR_DOMAIN_VIRT_QEMU:
- if (qemuCmdFlags & QEMUD_CMD_FLAG_KQEMU)
+ if (qemuCmdFlags & QEMU_CAPS_KQEMU)
disableKQEMU = 1;
- if (qemuCmdFlags & QEMUD_CMD_FLAG_KVM)
+ if (qemuCmdFlags & QEMU_CAPS_KVM)
disableKVM = 1;
break;
case VIR_DOMAIN_VIRT_KQEMU:
- if (qemuCmdFlags & QEMUD_CMD_FLAG_KVM)
+ if (qemuCmdFlags & QEMU_CAPS_KVM)
disableKVM = 1;
- if (qemuCmdFlags & QEMUD_CMD_FLAG_ENABLE_KQEMU) {
+ if (qemuCmdFlags & QEMU_CAPS_ENABLE_KQEMU) {
enableKQEMU = 1;
- } else if (!(qemuCmdFlags & QEMUD_CMD_FLAG_KQEMU)) {
+ } else if (!(qemuCmdFlags & QEMU_CAPS_KQEMU)) {
qemuReportError(VIR_ERR_CONFIG_UNSUPPORTED,
_("the QEMU binary %s does not support kqemu"),
emulator);
@@ -2662,12 +2662,12 @@ qemuBuildCommandLine(virConnectPtr conn,
break;
case VIR_DOMAIN_VIRT_KVM:
- if (qemuCmdFlags & QEMUD_CMD_FLAG_KQEMU)
+ if (qemuCmdFlags & QEMU_CAPS_KQEMU)
disableKQEMU = 1;
- if (qemuCmdFlags & QEMUD_CMD_FLAG_ENABLE_KVM) {
+ if (qemuCmdFlags & QEMU_CAPS_ENABLE_KVM) {
enableKVM = 1;
- } else if (!(qemuCmdFlags & QEMUD_CMD_FLAG_KVM)) {
+ } else if (!(qemuCmdFlags & QEMU_CAPS_KVM)) {
qemuReportError(VIR_ERR_CONFIG_UNSUPPORTED,
_("the QEMU binary %s does not support kvm"),
emulator);
@@ -2688,7 +2688,7 @@ qemuBuildCommandLine(virConnectPtr conn,
/* Currently only x86_64 and i686 support PCI-multibus. */
if (STREQLEN(def->os.arch, "x86_64", 6) ||
STREQLEN(def->os.arch, "i686", 4)) {
- qemuCmdFlags |= QEMUD_CMD_FLAG_PCI_MULTIBUS;
+ qemuCmdFlags |= QEMU_CAPS_PCI_MULTIBUS;
}
cmd = virCommandNewArgList(emulator, "-S", NULL);
@@ -2710,7 +2710,7 @@ qemuBuildCommandLine(virConnectPtr conn,
virCommandAddArgList(cmd, "-cpu", cpu, NULL);
VIR_FREE(cpu);
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_NESTING) &&
+ if ((qemuCmdFlags & QEMU_CAPS_NESTING) &&
hasHwVirt)
virCommandAddArg(cmd, "-enable-nesting");
}
@@ -2741,7 +2741,7 @@ qemuBuildCommandLine(virConnectPtr conn,
"%s", _("hugepages are disabled by
administrator config"));
goto error;
}
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_MEM_PATH)) {
+ if (!(qemuCmdFlags & QEMU_CAPS_MEM_PATH)) {
qemuReportError(VIR_ERR_INTERNAL_ERROR,
_("hugepage backing not supported by
'%s'"),
def->emulator);
@@ -2757,25 +2757,25 @@ qemuBuildCommandLine(virConnectPtr conn,
virCommandAddArg(cmd, smp);
VIR_FREE(smp);
- if (qemuCmdFlags & QEMUD_CMD_FLAG_NAME) {
+ if (qemuCmdFlags & QEMU_CAPS_NAME) {
virCommandAddArg(cmd, "-name");
if (driver->setProcessName &&
- (qemuCmdFlags & QEMUD_CMD_FLAG_NAME_PROCESS)) {
+ (qemuCmdFlags & QEMU_CAPS_NAME_PROCESS)) {
virCommandAddArgFormat(cmd, "%s,process=qemu:%s",
def->name, def->name);
} else {
virCommandAddArg(cmd, def->name);
}
}
- if (qemuCmdFlags & QEMUD_CMD_FLAG_UUID)
+ if (qemuCmdFlags & QEMU_CAPS_UUID)
virCommandAddArgList(cmd, "-uuid", uuid, NULL);
if (def->virtType == VIR_DOMAIN_VIRT_XEN ||
STREQ(def->os.type, "xen") ||
STREQ(def->os.type, "linux")) {
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DOMID) {
+ if (qemuCmdFlags & QEMU_CAPS_DOMID) {
virCommandAddArg(cmd, "-domid");
virCommandAddArgFormat(cmd, "%d", def->id);
- } else if (qemuCmdFlags & QEMUD_CMD_FLAG_XEN_DOMID) {
+ } else if (qemuCmdFlags & QEMU_CAPS_XEN_DOMID) {
virCommandAddArg(cmd, "-xen-attach");
virCommandAddArg(cmd, "-xen-domid");
virCommandAddArgFormat(cmd, "%d", def->id);
@@ -2792,7 +2792,7 @@ qemuBuildCommandLine(virConnectPtr conn,
virSysinfoDefPtr source = NULL;
bool skip_uuid = false;
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_SMBIOS_TYPE)) {
+ if (!(qemuCmdFlags & QEMU_CAPS_SMBIOS_TYPE)) {
qemuReportError(VIR_ERR_CONFIG_UNSUPPORTED,
_("the QEMU binary %s does not support smbios settings"),
emulator);
@@ -2845,8 +2845,8 @@ qemuBuildCommandLine(virConnectPtr conn,
if (!def->graphics)
virCommandAddArg(cmd, "-nographic");
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
- if (qemuCmdFlags & QEMUD_CMD_FLAG_NODEFCONFIG)
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_NODEFCONFIG)
virCommandAddArg(cmd,
"-nodefconfig"); /* Disable global config files
*/
virCommandAddArg(cmd,
@@ -2856,7 +2856,7 @@ qemuBuildCommandLine(virConnectPtr conn,
if (monitor_chr) {
char *chrdev;
/* Use -chardev if it's available */
- if (qemuCmdFlags & QEMUD_CMD_FLAG_CHARDEV) {
+ if (qemuCmdFlags & QEMU_CAPS_CHARDEV) {
virCommandAddArg(cmd, "-chardev");
if (!(chrdev = qemuBuildChrChardevStr(monitor_chr, "monitor",
@@ -2882,7 +2882,7 @@ qemuBuildCommandLine(virConnectPtr conn,
}
}
- if (qemuCmdFlags & QEMUD_CMD_FLAG_RTC) {
+ if (qemuCmdFlags & QEMU_CAPS_RTC) {
const char *rtcopt;
virCommandAddArg(cmd, "-rtc");
if (!(rtcopt = qemuBuildClockArgStr(&def->clock)))
@@ -2924,9 +2924,9 @@ qemuBuildCommandLine(virConnectPtr conn,
case VIR_DOMAIN_TIMER_NAME_RTC:
/* This has already been taken care of (in qemuBuildClockArgStr)
- if QEMUD_CMD_FLAG_RTC is set (mutually exclusive with
+ if QEMU_CAPS_RTC is set (mutually exclusive with
QEMUD_FLAG_RTC_TD_HACK) */
- if (qemuCmdFlags & QEMUD_CMD_FLAG_RTC_TD_HACK) {
+ if (qemuCmdFlags & QEMU_CAPS_RTC_TD_HACK) {
switch (def->clock.timers[i]->tickpolicy) {
case -1:
case VIR_DOMAIN_TIMER_TICKPOLICY_DELAY:
@@ -2942,7 +2942,7 @@ qemuBuildCommandLine(virConnectPtr conn,
virDomainTimerTickpolicyTypeToString(def->clock.timers[i]->tickpolicy));
goto error;
}
- } else if (!(qemuCmdFlags & QEMUD_CMD_FLAG_RTC)
+ } else if (!(qemuCmdFlags & QEMU_CAPS_RTC)
&& (def->clock.timers[i]->tickpolicy
!= VIR_DOMAIN_TIMER_TICKPOLICY_DELAY)
&& (def->clock.timers[i]->tickpolicy != -1)) {
@@ -2961,13 +2961,13 @@ qemuBuildCommandLine(virConnectPtr conn,
case VIR_DOMAIN_TIMER_TICKPOLICY_DELAY:
/* delay is the default if we don't have kernel
(-no-kvm-pit), otherwise, the default is catchup. */
- if (qemuCmdFlags & QEMUD_CMD_FLAG_NO_KVM_PIT)
+ if (qemuCmdFlags & QEMU_CAPS_NO_KVM_PIT)
virCommandAddArg(cmd, "-no-kvm-pit-reinjection");
break;
case VIR_DOMAIN_TIMER_TICKPOLICY_CATCHUP:
- if (qemuCmdFlags & QEMUD_CMD_FLAG_NO_KVM_PIT) {
+ if (qemuCmdFlags & QEMU_CAPS_NO_KVM_PIT) {
/* do nothing - this is default for kvm-pit */
- } else if (qemuCmdFlags & QEMUD_CMD_FLAG_TDF) {
+ } else if (qemuCmdFlags & QEMU_CAPS_TDF) {
/* -tdf switches to 'catchup' with userspace pit. */
virCommandAddArg(cmd, "-tdf");
} else {
@@ -2996,7 +2996,7 @@ qemuBuildCommandLine(virConnectPtr conn,
* and when -no-hpet doesn't exist is "no".
"confusing"?
* "yes"! */
- if (qemuCmdFlags & QEMUD_CMD_FLAG_NO_HPET) {
+ if (qemuCmdFlags & QEMU_CAPS_NO_HPET) {
if (def->clock.timers[i]->present == 0)
virCommandAddArg(cmd, "-no-hpet");
} else {
@@ -3011,7 +3011,7 @@ qemuBuildCommandLine(virConnectPtr conn,
}
}
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_NO_REBOOT) &&
+ if ((qemuCmdFlags & QEMU_CAPS_NO_REBOOT) &&
def->onReboot != VIR_DOMAIN_LIFECYCLE_RESTART)
virCommandAddArg(cmd, "-no-reboot");
@@ -3044,7 +3044,7 @@ qemuBuildCommandLine(virConnectPtr conn,
boot[def->os.nBootDevs] = '\0';
- if (qemuCmdFlags & QEMUD_CMD_FLAG_BOOT_MENU &&
+ if (qemuCmdFlags & QEMU_CAPS_BOOT_MENU &&
def->os.bootmenu != VIR_DOMAIN_BOOT_MENU_DEFAULT) {
if (def->os.bootmenu == VIR_DOMAIN_BOOT_MENU_ENABLED)
virBufferVSprintf(&boot_buf, "order=%s,menu=on",
boot);
@@ -3055,7 +3055,7 @@ qemuBuildCommandLine(virConnectPtr conn,
}
virCommandAddArgBuffer(cmd, &boot_buf);
- } else if (!(qemuCmdFlags & QEMUD_CMD_FLAG_BOOTINDEX)) {
+ } else if (!(qemuCmdFlags & QEMU_CAPS_BOOTINDEX)) {
/* def->os.nBootDevs is guaranteed to be > 0 unless per-device boot
* configuration is used
*/
@@ -3086,7 +3086,7 @@ qemuBuildCommandLine(virConnectPtr conn,
}
}
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
for (i = 0 ; i < def->ncontrollers ; i++) {
virDomainControllerDefPtr cont = def->controllers[i];
@@ -3116,11 +3116,11 @@ qemuBuildCommandLine(virConnectPtr conn,
}
/* If QEMU supports -drive param instead of old -hda, -hdb, -cdrom .. */
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DRIVE) {
+ if (qemuCmdFlags & QEMU_CAPS_DRIVE) {
int bootCD = 0, bootFloppy = 0, bootDisk = 0;
/* If QEMU supports boot=on for -drive param... */
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DRIVE_BOOT) {
+ if (qemuCmdFlags & QEMU_CAPS_DRIVE_BOOT) {
for (i = 0 ; i < def->os.nBootDevs ; i++) {
switch (def->os.bootDevs[i]) {
case VIR_DOMAIN_BOOT_CDROM:
@@ -3146,7 +3146,7 @@ qemuBuildCommandLine(virConnectPtr conn,
/* Unless we have -device, then USB disks need special
handling */
if ((disk->bus == VIR_DOMAIN_DISK_BUS_USB) &&
- !(qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE)) {
+ !(qemuCmdFlags & QEMU_CAPS_DEVICE)) {
if (disk->device == VIR_DOMAIN_DISK_DEVICE_DISK) {
virCommandAddArg(cmd, "-usbdevice");
virCommandAddArgFormat(cmd, "disk:%s", disk->src);
@@ -3181,12 +3181,12 @@ qemuBuildCommandLine(virConnectPtr conn,
devices. Fortunately, those don't need
static PCI addresses, so we don't really
care that we can't use -device */
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) &&
+ if ((qemuCmdFlags & QEMU_CAPS_DEVICE) &&
(disk->bus != VIR_DOMAIN_DISK_BUS_XEN))
withDeviceArg = 1;
if (!(optstr = qemuBuildDriveStr(disk, bootable,
(withDeviceArg ? qemuCmdFlags :
- (qemuCmdFlags &
~QEMUD_CMD_FLAG_DEVICE)))))
+ (qemuCmdFlags & ~QEMU_CAPS_DEVICE)))))
goto error;
virCommandAddArg(cmd, optstr);
VIR_FREE(optstr);
@@ -3221,7 +3221,7 @@ qemuBuildCommandLine(virConnectPtr conn,
disk->info.alias);
if (disk->bootIndex &&
- (qemuCmdFlags & QEMUD_CMD_FLAG_BOOTINDEX)) {
+ (qemuCmdFlags & QEMU_CAPS_BOOTINDEX)) {
virCommandAddArg(cmd, "-global");
virCommandAddArgFormat(cmd, "isa-fdc.bootindex%c=%d",
disk->info.addr.drive.unit
@@ -3346,7 +3346,7 @@ qemuBuildCommandLine(virConnectPtr conn,
if (has_rbd_hosts)
virCommandAddEnvBuffer(cmd, &rbd_hosts);
- if (qemuCmdFlags & QEMUD_CMD_FLAG_FSDEV) {
+ if (qemuCmdFlags & QEMU_CAPS_FSDEV) {
for (i = 0 ; i < def->nfss ; i++) {
char *optstr;
virDomainFSDefPtr fs = def->fss[i];
@@ -3373,7 +3373,7 @@ qemuBuildCommandLine(virConnectPtr conn,
if (!def->nnets) {
/* If we have -device, then we set -nodefault already */
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE))
+ if (!(qemuCmdFlags & QEMU_CAPS_DEVICE))
virCommandAddArgList(cmd, "-net", "none", NULL);
} else {
for (i = 0 ; i < def->nnets ; i++) {
@@ -3384,8 +3384,8 @@ qemuBuildCommandLine(virConnectPtr conn,
int vlan;
/* VLANs are not used with -netdev, so don't record them */
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_NETDEV) &&
- (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE))
+ if ((qemuCmdFlags & QEMU_CAPS_NETDEV) &&
+ (qemuCmdFlags & QEMU_CAPS_DEVICE))
vlan = -1;
else
vlan = i;
@@ -3444,8 +3444,8 @@ qemuBuildCommandLine(virConnectPtr conn,
*
* NB, no support for -netdev without use of -device
*/
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_NETDEV) &&
- (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE)) {
+ if ((qemuCmdFlags & QEMU_CAPS_NETDEV) &&
+ (qemuCmdFlags & QEMU_CAPS_DEVICE)) {
virCommandAddArg(cmd, "-netdev");
if (!(host = qemuBuildHostNetStr(net, ',', vlan,
tapfd_name, vhostfd_name)))
@@ -3453,7 +3453,7 @@ qemuBuildCommandLine(virConnectPtr conn,
virCommandAddArg(cmd, host);
VIR_FREE(host);
}
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
virCommandAddArg(cmd, "-device");
if (!(nic = qemuBuildNicDevStr(net, vlan, qemuCmdFlags)))
goto error;
@@ -3466,8 +3466,8 @@ qemuBuildCommandLine(virConnectPtr conn,
virCommandAddArg(cmd, nic);
VIR_FREE(nic);
}
- if (!((qemuCmdFlags & QEMUD_CMD_FLAG_NETDEV) &&
- (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE))) {
+ if (!((qemuCmdFlags & QEMU_CAPS_NETDEV) &&
+ (qemuCmdFlags & QEMU_CAPS_DEVICE))) {
virCommandAddArg(cmd, "-net");
if (!(host = qemuBuildHostNetStr(net, ',', vlan,
tapfd_name, vhostfd_name)))
@@ -3500,8 +3500,8 @@ qemuBuildCommandLine(virConnectPtr conn,
switch (smartcard->type) {
case VIR_DOMAIN_SMARTCARD_TYPE_HOST:
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_CHARDEV) ||
- !(qemuCmdFlags & QEMUD_CMD_FLAG_CCID_EMULATED)) {
+ if (!(qemuCmdFlags & QEMU_CAPS_CHARDEV) ||
+ !(qemuCmdFlags & QEMU_CAPS_CCID_EMULATED)) {
qemuReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
_("this QEMU binary lacks smartcard host "
"mode support"));
@@ -3512,8 +3512,8 @@ qemuBuildCommandLine(virConnectPtr conn,
break;
case VIR_DOMAIN_SMARTCARD_TYPE_HOST_CERTIFICATES:
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_CHARDEV) ||
- !(qemuCmdFlags & QEMUD_CMD_FLAG_CCID_EMULATED)) {
+ if (!(qemuCmdFlags & QEMU_CAPS_CHARDEV) ||
+ !(qemuCmdFlags & QEMU_CAPS_CCID_EMULATED)) {
qemuReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
_("this QEMU binary lacks smartcard host "
"mode support"));
@@ -3548,8 +3548,8 @@ qemuBuildCommandLine(virConnectPtr conn,
break;
case VIR_DOMAIN_SMARTCARD_TYPE_PASSTHROUGH:
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_CHARDEV) ||
- !(qemuCmdFlags & QEMUD_CMD_FLAG_CCID_PASSTHRU)) {
+ if (!(qemuCmdFlags & QEMU_CAPS_CHARDEV) ||
+ !(qemuCmdFlags & QEMU_CAPS_CCID_PASSTHRU)) {
qemuReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
_("this QEMU binary lacks smartcard "
"passthrough mode support"));
@@ -3584,7 +3584,7 @@ qemuBuildCommandLine(virConnectPtr conn,
if (!def->nserials) {
/* If we have -device, then we set -nodefault already */
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE))
+ if (!(qemuCmdFlags & QEMU_CAPS_DEVICE))
virCommandAddArgList(cmd, "-serial", "none", NULL);
} else {
for (i = 0 ; i < def->nserials ; i++) {
@@ -3592,8 +3592,8 @@ qemuBuildCommandLine(virConnectPtr conn,
char *devstr;
/* Use -chardev with -device if they are available */
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_CHARDEV) &&
- (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE)) {
+ if ((qemuCmdFlags & QEMU_CAPS_CHARDEV) &&
+ (qemuCmdFlags & QEMU_CAPS_DEVICE)) {
virCommandAddArg(cmd, "-chardev");
if (!(devstr = qemuBuildChrChardevStr(&serial->source,
serial->info.alias,
@@ -3617,7 +3617,7 @@ qemuBuildCommandLine(virConnectPtr conn,
if (!def->nparallels) {
/* If we have -device, then we set -nodefault already */
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE))
+ if (!(qemuCmdFlags & QEMU_CAPS_DEVICE))
virCommandAddArgList(cmd, "-parallel", "none", NULL);
} else {
for (i = 0 ; i < def->nparallels ; i++) {
@@ -3625,8 +3625,8 @@ qemuBuildCommandLine(virConnectPtr conn,
char *devstr;
/* Use -chardev with -device if they are available */
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_CHARDEV) &&
- (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE)) {
+ if ((qemuCmdFlags & QEMU_CAPS_CHARDEV) &&
+ (qemuCmdFlags & QEMU_CAPS_DEVICE)) {
virCommandAddArg(cmd, "-chardev");
if (!(devstr = qemuBuildChrChardevStr(¶llel->source,
parallel->info.alias,
@@ -3655,8 +3655,8 @@ qemuBuildCommandLine(virConnectPtr conn,
switch(channel->targetType) {
case VIR_DOMAIN_CHR_CHANNEL_TARGET_TYPE_GUESTFWD:
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_CHARDEV) ||
- !(qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE)) {
+ if (!(qemuCmdFlags & QEMU_CAPS_CHARDEV) ||
+ !(qemuCmdFlags & QEMU_CAPS_DEVICE)) {
qemuReportError(VIR_ERR_CONFIG_UNSUPPORTED,
"%s", _("guestfwd requires QEMU to support
-chardev & -device"));
goto error;
@@ -3684,13 +3684,13 @@ qemuBuildCommandLine(virConnectPtr conn,
break;
case VIR_DOMAIN_CHR_CHANNEL_TARGET_TYPE_VIRTIO:
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE)) {
+ if (!(qemuCmdFlags & QEMU_CAPS_DEVICE)) {
qemuReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
_("virtio channel requires QEMU to support -device"));
goto error;
}
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE_SPICEVMC) &&
+ if ((qemuCmdFlags & QEMU_CAPS_DEVICE_SPICEVMC) &&
channel->source.type == VIR_DOMAIN_CHR_TYPE_SPICEVMC) {
/* spicevmc was originally introduced via a -device
* with a backend internal to qemu; although we prefer
@@ -3723,7 +3723,7 @@ qemuBuildCommandLine(virConnectPtr conn,
switch(console->targetType) {
case VIR_DOMAIN_CHR_CONSOLE_TARGET_TYPE_VIRTIO:
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE)) {
+ if (!(qemuCmdFlags & QEMU_CAPS_DEVICE)) {
qemuReportError(VIR_ERR_NO_SUPPORT, "%s",
_("virtio channel requires QEMU to support -device"));
goto error;
@@ -3761,7 +3761,7 @@ qemuBuildCommandLine(virConnectPtr conn,
virDomainInputDefPtr input = def->inputs[i];
if (input->bus == VIR_DOMAIN_INPUT_BUS_USB) {
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
char *optstr;
virCommandAddArg(cmd, "-device");
if (!(optstr = qemuBuildUSBInputDevStr(input)))
@@ -3798,7 +3798,7 @@ qemuBuildCommandLine(virConnectPtr conn,
virBufferVSprintf(&opt, "unix:%s",
def->graphics[0]->data.vnc.socket);
- } else if (qemuCmdFlags & QEMUD_CMD_FLAG_VNC_COLON) {
+ } else if (qemuCmdFlags & QEMU_CAPS_VNC_COLON) {
if (def->graphics[0]->data.vnc.listenAddr)
virBufferAdd(&opt, def->graphics[0]->data.vnc.listenAddr, -1);
else if (driver->vncListen)
@@ -3812,7 +3812,7 @@ qemuBuildCommandLine(virConnectPtr conn,
def->graphics[0]->data.vnc.port - 5900);
}
- if (qemuCmdFlags & QEMUD_CMD_FLAG_VNC_COLON) {
+ if (qemuCmdFlags & QEMU_CAPS_VNC_COLON) {
if (def->graphics[0]->data.vnc.auth.passwd ||
driver->vncPassword)
virBufferAddLit(&opt, ",password");
@@ -3857,8 +3857,8 @@ qemuBuildCommandLine(virConnectPtr conn,
}
} else if ((def->ngraphics == 1) &&
def->graphics[0]->type == VIR_DOMAIN_GRAPHICS_TYPE_SDL) {
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_0_10) &&
- !(qemuCmdFlags & QEMUD_CMD_FLAG_SDL)) {
+ if ((qemuCmdFlags & QEMU_CAPS_0_10) &&
+ !(qemuCmdFlags & QEMU_CAPS_SDL)) {
qemuReportError(VIR_ERR_CONFIG_UNSUPPORTED,
_("sdl not supported by '%s'"),
def->emulator);
@@ -3884,14 +3884,14 @@ qemuBuildCommandLine(virConnectPtr conn,
/* New QEMU has this flag to let us explicitly ask for
* SDL graphics. This is better than relying on the
* default, since the default changes :-( */
- if (qemuCmdFlags & QEMUD_CMD_FLAG_SDL)
+ if (qemuCmdFlags & QEMU_CAPS_SDL)
virCommandAddArg(cmd, "-sdl");
} else if ((def->ngraphics == 1) &&
def->graphics[0]->type == VIR_DOMAIN_GRAPHICS_TYPE_SPICE) {
virBuffer opt = VIR_BUFFER_INITIALIZER;
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_SPICE)) {
+ if (!(qemuCmdFlags & QEMU_CAPS_SPICE)) {
qemuReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
_("spice graphics are not supported with this
QEMU"));
goto error;
@@ -3950,12 +3950,12 @@ qemuBuildCommandLine(virConnectPtr conn,
}
if (def->nvideos > 0) {
- if (qemuCmdFlags & QEMUD_CMD_FLAG_VGA) {
+ if (qemuCmdFlags & QEMU_CAPS_VGA) {
if (def->videos[0]->type == VIR_DOMAIN_VIDEO_TYPE_XEN) {
/* nothing - vga has no effect on Xen pvfb */
} else {
if ((def->videos[0]->type == VIR_DOMAIN_VIDEO_TYPE_QXL) &&
- !(qemuCmdFlags & QEMUD_CMD_FLAG_VGA_QXL)) {
+ !(qemuCmdFlags & QEMU_CAPS_VGA_QXL)) {
qemuReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
_("This QEMU does not support QXL graphics
adapters"));
goto error;
@@ -3996,7 +3996,7 @@ qemuBuildCommandLine(virConnectPtr conn,
}
if (def->nvideos > 1) {
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
for (i = 1 ; i < def->nvideos ; i++) {
char *str;
if (def->videos[i]->type != VIR_DOMAIN_VIDEO_TYPE_QXL) {
@@ -4023,15 +4023,15 @@ qemuBuildCommandLine(virConnectPtr conn,
} else {
/* If we have -device, then we set -nodefault already */
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) &&
- (qemuCmdFlags & QEMUD_CMD_FLAG_VGA) &&
- (qemuCmdFlags & QEMUD_CMD_FLAG_VGA_NONE))
+ if (!(qemuCmdFlags & QEMU_CAPS_DEVICE) &&
+ (qemuCmdFlags & QEMU_CAPS_VGA) &&
+ (qemuCmdFlags & QEMU_CAPS_VGA_NONE))
virCommandAddArgList(cmd, "-vga", "none", NULL);
}
/* Add sound hardware */
if (def->nsounds) {
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
for (i = 0 ; i < def->nsounds ; i++) {
virDomainSoundDefPtr sound = def->sounds[i];
char *str = NULL;
@@ -4050,7 +4050,7 @@ qemuBuildCommandLine(virConnectPtr conn,
if (sound->model == VIR_DOMAIN_SOUND_MODEL_ICH6) {
char *codecstr = NULL;
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_HDA_DUPLEX)) {
+ if (!(qemuCmdFlags & QEMU_CAPS_HDA_DUPLEX)) {
qemuReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
_("this QEMU binary lacks hda support"));
goto error;
@@ -4106,7 +4106,7 @@ qemuBuildCommandLine(virConnectPtr conn,
virDomainWatchdogDefPtr watchdog = def->watchdog;
char *optstr;
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
virCommandAddArg(cmd, "-device");
optstr = qemuBuildWatchdogDevStr(watchdog, qemuCmdFlags);
@@ -4152,7 +4152,7 @@ qemuBuildCommandLine(virConnectPtr conn,
_("booting from assigned devices is only"
" supported for PCI devices"));
goto error;
- } else if (!(qemuCmdFlags & QEMUD_CMD_FLAG_PCI_BOOTINDEX)) {
+ } else if (!(qemuCmdFlags & QEMU_CAPS_PCI_BOOTINDEX)) {
qemuReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
_("booting from assigned PCI devices is not"
" supported with this version of qemu"));
@@ -4164,7 +4164,7 @@ qemuBuildCommandLine(virConnectPtr conn,
if (hostdev->mode == VIR_DOMAIN_HOSTDEV_MODE_SUBSYS &&
hostdev->source.subsys.type == VIR_DOMAIN_HOSTDEV_SUBSYS_TYPE_USB) {
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
virCommandAddArg(cmd, "-device");
if (!(devstr = qemuBuildUSBHostdevDevStr(hostdev)))
goto error;
@@ -4182,9 +4182,9 @@ qemuBuildCommandLine(virConnectPtr conn,
/* PCI */
if (hostdev->mode == VIR_DOMAIN_HOSTDEV_MODE_SUBSYS &&
hostdev->source.subsys.type == VIR_DOMAIN_HOSTDEV_SUBSYS_TYPE_PCI) {
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
char *configfd_name = NULL;
- if (qemuCmdFlags & QEMUD_CMD_FLAG_PCI_CONFIGFD) {
+ if (qemuCmdFlags & QEMU_CAPS_PCI_CONFIGFD) {
int configfd = qemuOpenPCIConfig(hostdev);
if (configfd >= 0) {
@@ -4204,7 +4204,7 @@ qemuBuildCommandLine(virConnectPtr conn,
goto error;
virCommandAddArg(cmd, devstr);
VIR_FREE(devstr);
- } else if (qemuCmdFlags & QEMUD_CMD_FLAG_PCIDEVICE) {
+ } else if (qemuCmdFlags & QEMU_CAPS_PCIDEVICE) {
virCommandAddArg(cmd, "-pcidevice");
if (!(devstr = qemuBuildPCIHostdevPCIDevStr(hostdev)))
goto error;
@@ -4224,7 +4224,7 @@ qemuBuildCommandLine(virConnectPtr conn,
if (migrateFrom) {
virCommandAddArg(cmd, "-incoming");
if (STRPREFIX(migrateFrom, "tcp")) {
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_MIGRATE_QEMU_TCP)) {
+ if (!(qemuCmdFlags & QEMU_CAPS_MIGRATE_QEMU_TCP)) {
qemuReportError(VIR_ERR_CONFIG_UNSUPPORTED,
"%s", _("TCP migration is not supported
with "
"this QEMU binary"));
@@ -4232,13 +4232,13 @@ qemuBuildCommandLine(virConnectPtr conn,
}
virCommandAddArg(cmd, migrateFrom);
} else if (STREQ(migrateFrom, "stdio")) {
- if (qemuCmdFlags & QEMUD_CMD_FLAG_MIGRATE_QEMU_FD) {
+ if (qemuCmdFlags & QEMU_CAPS_MIGRATE_QEMU_FD) {
virCommandAddArgFormat(cmd, "fd:%d", migrateFd);
virCommandPreserveFD(cmd, migrateFd);
- } else if (qemuCmdFlags & QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC) {
+ } else if (qemuCmdFlags & QEMU_CAPS_MIGRATE_QEMU_EXEC) {
virCommandAddArg(cmd, "exec:cat");
virCommandSetInputFD(cmd, migrateFd);
- } else if (qemuCmdFlags & QEMUD_CMD_FLAG_MIGRATE_KVM_STDIO) {
+ } else if (qemuCmdFlags & QEMU_CAPS_MIGRATE_KVM_STDIO) {
virCommandAddArg(cmd, migrateFrom);
virCommandSetInputFD(cmd, migrateFd);
} else {
@@ -4248,7 +4248,7 @@ qemuBuildCommandLine(virConnectPtr conn,
goto error;
}
} else if (STRPREFIX(migrateFrom, "exec")) {
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC)) {
+ if (!(qemuCmdFlags & QEMU_CAPS_MIGRATE_QEMU_EXEC)) {
qemuReportError(VIR_ERR_CONFIG_UNSUPPORTED,
"%s", _("EXEC migration is not supported
"
"with this QEMU binary"));
@@ -4256,7 +4256,7 @@ qemuBuildCommandLine(virConnectPtr conn,
}
virCommandAddArg(cmd, migrateFrom);
} else if (STRPREFIX(migrateFrom, "fd")) {
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_MIGRATE_QEMU_FD)) {
+ if (!(qemuCmdFlags & QEMU_CAPS_MIGRATE_QEMU_FD)) {
qemuReportError(VIR_ERR_CONFIG_UNSUPPORTED,
"%s", _("FD migration is not supported
"
"with this QEMU binary"));
@@ -4265,7 +4265,7 @@ qemuBuildCommandLine(virConnectPtr conn,
virCommandAddArg(cmd, migrateFrom);
virCommandPreserveFD(cmd, migrateFd);
} else if (STRPREFIX(migrateFrom, "unix")) {
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_MIGRATE_QEMU_UNIX)) {
+ if (!(qemuCmdFlags & QEMU_CAPS_MIGRATE_QEMU_UNIX)) {
qemuReportError(VIR_ERR_CONFIG_UNSUPPORTED,
"%s", _("UNIX migration is not supported
"
"with this QEMU binary"));
@@ -4293,7 +4293,7 @@ qemuBuildCommandLine(virConnectPtr conn,
virDomainMemballoonModelTypeToString(def->memballoon->model));
goto error;
}
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
char *optstr;
virCommandAddArg(cmd, "-device");
@@ -4302,7 +4302,7 @@ qemuBuildCommandLine(virConnectPtr conn,
goto error;
virCommandAddArg(cmd, optstr);
VIR_FREE(optstr);
- } else if (qemuCmdFlags & QEMUD_CMD_FLAG_BALLOON) {
+ } else if (qemuCmdFlags & QEMU_CAPS_BALLOON) {
virCommandAddArgList(cmd, "-balloon", "virtio", NULL);
}
}
diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c
index 52ea98e..6d21ddd 100644
--- a/src/qemu/qemu_driver.c
+++ b/src/qemu/qemu_driver.c
@@ -946,7 +946,7 @@ qemuReconnectDomain(void *payload, const char *name ATTRIBUTE_UNUSED,
void *opaq
if (qemuCapsExtractVersionInfo(obj->def->emulator,
NULL,
&qemuCmdFlags) >= 0 &&
- (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE)) {
+ (qemuCmdFlags & QEMU_CAPS_DEVICE)) {
priv->persistentAddrs = 1;
if (!(priv->pciaddrs = qemuDomainPCIAddressSetCreate(obj->def)) ||
@@ -2021,7 +2021,7 @@ qemuInitPasswords(virConnectPtr conn,
if (ret < 0)
goto cleanup;
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
int i;
for (i = 0 ; i < vm->def->ndisks ; i++) {
@@ -2521,7 +2521,7 @@ qemuAssignPCIAddresses(virDomainDefPtr def)
&qemuCmdFlags) < 0)
goto cleanup;
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
if (!(addrs = qemuDomainPCIAddressSetCreate(def)))
goto cleanup;
@@ -2768,7 +2768,7 @@ static int qemudStartVMDaemon(virConnectPtr conn,
goto cleanup;
#if HAVE_YAJL
- if (qemuCmdFlags & QEMUD_CMD_FLAG_MONITOR_JSON)
+ if (qemuCmdFlags & QEMU_CAPS_MONITOR_JSON)
priv->monJSON = 1;
else
#endif
@@ -2797,7 +2797,7 @@ static int qemudStartVMDaemon(virConnectPtr conn,
* we also need to populate the PCi address set cache for later
* use in hotplug
*/
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
DEBUG0("Assigning domain PCI addresses");
/* Populate cache with current addresses */
if (priv->pciaddrs) {
@@ -2929,7 +2929,7 @@ static int qemudStartVMDaemon(virConnectPtr conn,
/* If we have -device, then addresses are assigned explicitly.
* If not, then we have to detect dynamic ones here */
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE)) {
+ if (!(qemuCmdFlags & QEMU_CAPS_DEVICE)) {
DEBUG0("Determining domain device PCI addresses");
if (qemuInitPCIAddresses(driver, vm) < 0)
goto cleanup;
@@ -8084,9 +8084,9 @@ qemudDomainMigratePrepareTunnel(virConnectPtr dconn,
vm->def->emulator);
goto endjob;
}
- if (qemuCmdFlags & QEMUD_CMD_FLAG_MIGRATE_QEMU_UNIX)
+ if (qemuCmdFlags & QEMU_CAPS_MIGRATE_QEMU_UNIX)
internalret = virAsprintf(&migrateFrom, "unix:%s", unixfile);
- else if (qemuCmdFlags & QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC)
+ else if (qemuCmdFlags & QEMU_CAPS_MIGRATE_QEMU_EXEC)
internalret = virAsprintf(&migrateFrom, "exec:nc -U -l %s",
unixfile);
else {
qemuReportError(VIR_ERR_OPERATION_FAILED,
@@ -8596,8 +8596,8 @@ static int doTunnelMigrate(virDomainPtr dom,
goto cleanup;
}
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_MIGRATE_QEMU_UNIX) &&
- !(qemuCmdFlags & QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC)) {
+ if (!(qemuCmdFlags & QEMU_CAPS_MIGRATE_QEMU_UNIX) &&
+ !(qemuCmdFlags & QEMU_CAPS_MIGRATE_QEMU_EXEC)) {
qemuReportError(VIR_ERR_OPERATION_FAILED,
"%s", _("Source qemu is too old to support
tunnelled migration"));
goto cleanup;
@@ -8639,11 +8639,11 @@ static int doTunnelMigrate(virDomainPtr dom,
background_flags |= QEMU_MONITOR_MIGRATE_NON_SHARED_DISK;
if (flags & VIR_MIGRATE_NON_SHARED_INC)
background_flags |= QEMU_MONITOR_MIGRATE_NON_SHARED_INC;
- if (qemuCmdFlags & QEMUD_CMD_FLAG_MIGRATE_QEMU_UNIX){
+ if (qemuCmdFlags & QEMU_CAPS_MIGRATE_QEMU_UNIX){
internalret = qemuMonitorMigrateToUnix(priv->mon, background_flags,
unixfile);
}
- else if (qemuCmdFlags & QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC) {
+ else if (qemuCmdFlags & QEMU_CAPS_MIGRATE_QEMU_EXEC) {
const char *args[] = { "nc", "-U", unixfile, NULL };
internalret = qemuMonitorMigrateToCommand(priv->mon,
QEMU_MONITOR_MIGRATE_BACKGROUND, args);
} else {
diff --git a/src/qemu/qemu_hotplug.c b/src/qemu/qemu_hotplug.c
index fb9db5a..a7b1a20 100644
--- a/src/qemu/qemu_hotplug.c
+++ b/src/qemu/qemu_hotplug.c
@@ -160,7 +160,7 @@ int qemuDomainAttachPciDiskDevice(struct qemud_driver *driver,
vm, disk) < 0)
return -1;
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
if (qemuDomainPCIAddressEnsureAddr(priv->pciaddrs, &disk->info) <
0)
goto error;
if (qemuAssignDeviceDiskAlias(disk, qemuCmdFlags) < 0)
@@ -179,7 +179,7 @@ int qemuDomainAttachPciDiskDevice(struct qemud_driver *driver,
}
qemuDomainObjEnterMonitorWithDriver(driver, vm);
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
ret = qemuMonitorAddDrive(priv->mon, drivestr);
if (ret == 0) {
ret = qemuMonitorAddDevice(priv->mon, devstr);
@@ -219,7 +219,7 @@ error:
VIR_FREE(devstr);
VIR_FREE(drivestr);
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) &&
+ if ((qemuCmdFlags & QEMU_CAPS_DEVICE) &&
(disk->info.type == VIR_DOMAIN_DEVICE_ADDRESS_TYPE_PCI) &&
qemuDomainPCIAddressReleaseAddr(priv->pciaddrs, &disk->info) < 0)
VIR_WARN("Unable to release PCI address on %s", disk->src);
@@ -253,7 +253,7 @@ int qemuDomainAttachPciControllerDevice(struct qemud_driver *driver,
}
}
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
if (qemuDomainPCIAddressEnsureAddr(priv->pciaddrs, &controller->info)
< 0)
goto cleanup;
if (qemuAssignDeviceControllerAlias(controller) < 0)
@@ -270,7 +270,7 @@ int qemuDomainAttachPciControllerDevice(struct qemud_driver *driver,
}
qemuDomainObjEnterMonitorWithDriver(driver, vm);
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
ret = qemuMonitorAddDevice(priv->mon, devstr);
} else {
ret = qemuMonitorAttachPCIDiskController(priv->mon,
@@ -286,7 +286,7 @@ int qemuDomainAttachPciControllerDevice(struct qemud_driver *driver,
cleanup:
if ((ret != 0) &&
- (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) &&
+ (qemuCmdFlags & QEMU_CAPS_DEVICE) &&
(controller->info.type == VIR_DOMAIN_DEVICE_ADDRESS_TYPE_PCI) &&
qemuDomainPCIAddressReleaseAddr(priv->pciaddrs, &controller->info) <
0)
VIR_WARN0("Unable to release PCI address on controller");
@@ -376,7 +376,7 @@ int qemuDomainAttachSCSIDisk(struct qemud_driver *driver,
goto error;
}
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
if (qemuAssignDeviceDiskAlias(disk, qemuCmdFlags) < 0)
goto error;
if (!(devstr = qemuBuildDriveDevStr(disk, qemuCmdFlags)))
@@ -409,7 +409,7 @@ int qemuDomainAttachSCSIDisk(struct qemud_driver *driver,
}
qemuDomainObjEnterMonitorWithDriver(driver, vm);
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
ret = qemuMonitorAddDrive(priv->mon, drivestr);
if (ret == 0) {
ret = qemuMonitorAddDevice(priv->mon, devstr);
@@ -487,7 +487,7 @@ int qemuDomainAttachUsbMassstorageDevice(struct qemud_driver *driver,
goto error;
}
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
if (qemuAssignDeviceDiskAlias(disk, qemuCmdFlags) < 0)
goto error;
if (!(drivestr = qemuBuildDriveStr(disk, 0, qemuCmdFlags)))
@@ -502,7 +502,7 @@ int qemuDomainAttachUsbMassstorageDevice(struct qemud_driver *driver,
}
qemuDomainObjEnterMonitorWithDriver(driver, vm);
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
ret = qemuMonitorAddDrive(priv->mon, drivestr);
if (ret == 0) {
ret = qemuMonitorAddDevice(priv->mon, devstr);
@@ -558,7 +558,7 @@ int qemuDomainAttachNetDevice(virConnectPtr conn,
virDomainDevicePCIAddress guestAddr;
int vlan;
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_HOST_NET_ADD)) {
+ if (!(qemuCmdFlags & QEMU_CAPS_HOST_NET_ADD)) {
qemuReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
_("installed qemu version does not support
host_net_add"));
return -1;
@@ -595,18 +595,18 @@ int qemuDomainAttachNetDevice(virConnectPtr conn,
if (VIR_REALLOC_N(vm->def->nets, vm->def->nnets+1) < 0)
goto no_memory;
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_NET_NAME) ||
- (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE)) {
+ if ((qemuCmdFlags & QEMU_CAPS_NET_NAME) ||
+ (qemuCmdFlags & QEMU_CAPS_DEVICE)) {
if (qemuAssignDeviceNetAlias(vm->def, net, -1) < 0)
goto cleanup;
}
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) &&
+ if ((qemuCmdFlags & QEMU_CAPS_DEVICE) &&
qemuDomainPCIAddressEnsureAddr(priv->pciaddrs, &net->info) < 0)
goto cleanup;
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_NETDEV) &&
- (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE)) {
+ if ((qemuCmdFlags & QEMU_CAPS_NETDEV) &&
+ (qemuCmdFlags & QEMU_CAPS_DEVICE)) {
vlan = -1;
} else {
vlan = qemuDomainNetVLAN(net);
@@ -637,8 +637,8 @@ int qemuDomainAttachNetDevice(virConnectPtr conn,
}
/* FIXME - need to support vhost-net here (5th arg) */
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_NETDEV) &&
- (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE)) {
+ if ((qemuCmdFlags & QEMU_CAPS_NETDEV) &&
+ (qemuCmdFlags & QEMU_CAPS_DEVICE)) {
if (!(netstr = qemuBuildHostNetStr(net, ',',
-1, tapfd_name, 0)))
goto try_tapfd_close;
@@ -649,8 +649,8 @@ int qemuDomainAttachNetDevice(virConnectPtr conn,
}
qemuDomainObjEnterMonitorWithDriver(driver, vm);
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_NETDEV) &&
- (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE)) {
+ if ((qemuCmdFlags & QEMU_CAPS_NETDEV) &&
+ (qemuCmdFlags & QEMU_CAPS_DEVICE)) {
if (qemuMonitorAddNetdev(priv->mon, netstr) < 0) {
qemuDomainObjExitMonitorWithDriver(driver, vm);
qemuDomainNetAudit(vm, NULL, net, "attach", false);
@@ -673,7 +673,7 @@ int qemuDomainAttachNetDevice(virConnectPtr conn,
goto cleanup;
}
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
if (!(nicstr = qemuBuildNicDevStr(net, vlan, qemuCmdFlags)))
goto try_remove;
} else {
@@ -682,7 +682,7 @@ int qemuDomainAttachNetDevice(virConnectPtr conn,
}
qemuDomainObjEnterMonitorWithDriver(driver, vm);
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
if (qemuMonitorAddDevice(priv->mon, nicstr) < 0) {
qemuDomainObjExitMonitorWithDriver(driver, vm);
qemuDomainNetAudit(vm, NULL, net, "attach", false);
@@ -708,7 +708,7 @@ int qemuDomainAttachNetDevice(virConnectPtr conn,
cleanup:
if ((ret != 0) &&
- (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) &&
+ (qemuCmdFlags & QEMU_CAPS_DEVICE) &&
(net->info.type == VIR_DOMAIN_DEVICE_ADDRESS_TYPE_PCI) &&
qemuDomainPCIAddressReleaseAddr(priv->pciaddrs, &net->info) < 0)
VIR_WARN0("Unable to release PCI address on NIC");
@@ -728,8 +728,8 @@ try_remove:
goto cleanup;
if (vlan < 0) {
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_NETDEV) &&
- (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE)) {
+ if ((qemuCmdFlags & QEMU_CAPS_NETDEV) &&
+ (qemuCmdFlags & QEMU_CAPS_DEVICE)) {
char *netdev_name;
if (virAsprintf(&netdev_name, "host%s", net->info.alias)
< 0)
goto no_memory;
@@ -793,12 +793,12 @@ int qemuDomainAttachHostPciDevice(struct qemud_driver *driver,
if (qemuPrepareHostdevPCIDevices(driver, &hostdev, 1) < 0)
return -1;
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
if (qemuAssignDeviceHostdevAlias(vm->def, hostdev, -1) < 0)
goto error;
if (qemuDomainPCIAddressEnsureAddr(priv->pciaddrs, &hostdev->info) <
0)
goto error;
- if (qemuCmdFlags & QEMUD_CMD_FLAG_PCI_CONFIGFD) {
+ if (qemuCmdFlags & QEMU_CAPS_PCI_CONFIGFD) {
configfd = qemuOpenPCIConfig(hostdev);
if (configfd >= 0) {
if (virAsprintf(&configfd_name, "fd-%s",
@@ -854,7 +854,7 @@ int qemuDomainAttachHostPciDevice(struct qemud_driver *driver,
return 0;
error:
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) &&
+ if ((qemuCmdFlags & QEMU_CAPS_DEVICE) &&
(hostdev->info.type == VIR_DOMAIN_DEVICE_ADDRESS_TYPE_PCI) &&
qemuDomainPCIAddressReleaseAddr(priv->pciaddrs, &hostdev->info) <
0)
VIR_WARN0("Unable to release PCI address on host device");
@@ -878,7 +878,7 @@ int qemuDomainAttachHostUsbDevice(struct qemud_driver *driver,
qemuDomainObjPrivatePtr priv = vm->privateData;
char *devstr = NULL;
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
if (qemuAssignDeviceHostdevAlias(vm->def, hostdev, -1) < 0)
goto error;
if (!(devstr = qemuBuildUSBHostdevDevStr(hostdev)))
@@ -910,7 +910,7 @@ int qemuDomainAttachHostUsbDevice(struct qemud_driver *driver,
}
qemuDomainObjEnterMonitorWithDriver(driver, vm);
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE)
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE)
ret = qemuMonitorAddDevice(priv->mon, devstr);
else
ret = qemuMonitorAddUSBDeviceExact(priv->mon,
@@ -1173,7 +1173,7 @@ int qemuDomainDetachPciDiskDevice(struct qemud_driver *driver,
}
qemuDomainObjEnterMonitorWithDriver(driver, vm);
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
if (qemuMonitorDelDevice(priv->mon, detach->info.alias) < 0) {
qemuDomainObjExitMonitor(vm);
goto cleanup;
@@ -1193,7 +1193,7 @@ int qemuDomainDetachPciDiskDevice(struct qemud_driver *driver,
qemuDomainDiskAudit(vm, detach, NULL, "detach", ret >= 0);
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) &&
+ if ((qemuCmdFlags & QEMU_CAPS_DEVICE) &&
qemuDomainPCIAddressReleaseAddr(priv->pciaddrs, &detach->info) < 0)
VIR_WARN("Unable to release PCI address on %s",
dev->data.disk->src);
@@ -1237,7 +1237,7 @@ int qemuDomainDetachSCSIDiskDevice(struct qemud_driver *driver,
goto cleanup;
}
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE)) {
+ if (!(qemuCmdFlags & QEMU_CAPS_DEVICE)) {
qemuReportError(VIR_ERR_OPERATION_FAILED, "%s",
_("Underlying qemu does not support SCSI disk
removal"));
goto cleanup;
@@ -1329,13 +1329,13 @@ int qemuDomainDetachPciControllerDevice(struct qemud_driver
*driver,
goto cleanup;
}
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
if (qemuAssignDeviceControllerAlias(detach) < 0)
goto cleanup;
}
qemuDomainObjEnterMonitorWithDriver(driver, vm);
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
if (qemuMonitorDelDevice(priv->mon, detach->info.alias)) {
qemuDomainObjExitMonitor(vm);
goto cleanup;
@@ -1363,7 +1363,7 @@ int qemuDomainDetachPciControllerDevice(struct qemud_driver
*driver,
vm->def->ncontrollers = 0;
}
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) &&
+ if ((qemuCmdFlags & QEMU_CAPS_DEVICE) &&
qemuDomainPCIAddressReleaseAddr(priv->pciaddrs, &detach->info) < 0)
VIR_WARN0("Unable to release PCI address on controller");
@@ -1423,7 +1423,7 @@ int qemuDomainDetachNetDevice(struct qemud_driver *driver,
}
qemuDomainObjEnterMonitorWithDriver(driver, vm);
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
if (qemuMonitorDelDevice(priv->mon, detach->info.alias) < 0) {
qemuDomainObjExitMonitor(vm);
qemuDomainNetAudit(vm, detach, NULL, "detach", false);
@@ -1438,8 +1438,8 @@ int qemuDomainDetachNetDevice(struct qemud_driver *driver,
}
}
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_NETDEV) &&
- (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE)) {
+ if ((qemuCmdFlags & QEMU_CAPS_NETDEV) &&
+ (qemuCmdFlags & QEMU_CAPS_DEVICE)) {
if (qemuMonitorRemoveNetdev(priv->mon, hostnet_name) < 0) {
qemuDomainObjExitMonitorWithDriver(driver, vm);
qemuDomainNetAudit(vm, detach, NULL, "detach", false);
@@ -1456,7 +1456,7 @@ int qemuDomainDetachNetDevice(struct qemud_driver *driver,
qemuDomainNetAudit(vm, detach, NULL, "detach", true);
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) &&
+ if ((qemuCmdFlags & QEMU_CAPS_DEVICE) &&
qemuDomainPCIAddressReleaseAddr(priv->pciaddrs, &detach->info) < 0)
VIR_WARN0("Unable to release PCI address on NIC");
@@ -1549,7 +1549,7 @@ int qemuDomainDetachHostPciDevice(struct qemud_driver *driver,
}
qemuDomainObjEnterMonitorWithDriver(driver, vm);
- if (qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) {
+ if (qemuCmdFlags & QEMU_CAPS_DEVICE) {
if (qemuMonitorDelDevice(priv->mon, detach->info.alias) < 0) {
qemuDomainObjExitMonitor(vm);
return -1;
@@ -1580,7 +1580,7 @@ int qemuDomainDetachHostPciDevice(struct qemud_driver *driver,
pciFreeDevice(pci);
}
- if ((qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE) &&
+ if ((qemuCmdFlags & QEMU_CAPS_DEVICE) &&
qemuDomainPCIAddressReleaseAddr(priv->pciaddrs, &detach->info) < 0)
VIR_WARN0("Unable to release PCI address on host device");
@@ -1651,7 +1651,7 @@ int qemuDomainDetachHostUsbDevice(struct qemud_driver *driver,
return -1;
}
- if (!(qemuCmdFlags & QEMUD_CMD_FLAG_DEVICE)) {
+ if (!(qemuCmdFlags & QEMU_CAPS_DEVICE)) {
qemuReportError(VIR_ERR_OPERATION_FAILED,
"%s", _("device cannot be detached with this QEMU
version"));
return -1;
diff --git a/tests/qemuargv2xmltest.c b/tests/qemuargv2xmltest.c
index 7499ba0..74bc763 100644
--- a/tests/qemuargv2xmltest.c
+++ b/tests/qemuargv2xmltest.c
@@ -145,7 +145,7 @@ mymain(int argc, char **argv)
unsetenv("LD_LIBRARY_PATH");
/* Can't roundtrip vcpu cpuset attribute */
- /*DO_TEST("minimal", QEMUD_CMD_FLAG_NAME);*/
+ /*DO_TEST("minimal", QEMU_CAPS_NAME);*/
DO_TEST("boot-cdrom");
DO_TEST("boot-network");
DO_TEST("boot-floppy");
diff --git a/tests/qemuhelptest.c b/tests/qemuhelptest.c
index 3a04b61..975a759 100644
--- a/tests/qemuhelptest.c
+++ b/tests/qemuhelptest.c
@@ -57,7 +57,7 @@ static int testHelpStrParsing(const void *data)
&version, &is_kvm, &kvm_version) == -1)
goto cleanup;
- if (info->flags & QEMUD_CMD_FLAG_DEVICE) {
+ if (info->flags & QEMU_CAPS_DEVICE) {
VIR_FREE(path);
if (virAsprintf(&path, "%s/qemuhelpdata/%s-device", abs_srcdir,
info->name) < 0)
@@ -133,354 +133,354 @@ mymain(int argc, char **argv)
} while (0)
DO_TEST("qemu-0.9.1",
- QEMUD_CMD_FLAG_KQEMU |
- QEMUD_CMD_FLAG_VNC_COLON |
- QEMUD_CMD_FLAG_NO_REBOOT |
- QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_NAME,
+ QEMU_CAPS_KQEMU |
+ QEMU_CAPS_VNC_COLON |
+ QEMU_CAPS_NO_REBOOT |
+ QEMU_CAPS_DRIVE |
+ QEMU_CAPS_NAME,
9001, 0, 0);
DO_TEST("kvm-74",
- QEMUD_CMD_FLAG_VNC_COLON |
- QEMUD_CMD_FLAG_NO_REBOOT |
- QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_BOOT |
- QEMUD_CMD_FLAG_NAME |
- QEMUD_CMD_FLAG_VNET_HDR |
- QEMUD_CMD_FLAG_MIGRATE_KVM_STDIO |
- QEMUD_CMD_FLAG_KVM |
- QEMUD_CMD_FLAG_DRIVE_FORMAT |
- QEMUD_CMD_FLAG_MEM_PATH |
- QEMUD_CMD_FLAG_TDF,
+ QEMU_CAPS_VNC_COLON |
+ QEMU_CAPS_NO_REBOOT |
+ QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_BOOT |
+ QEMU_CAPS_NAME |
+ QEMU_CAPS_VNET_HDR |
+ QEMU_CAPS_MIGRATE_KVM_STDIO |
+ QEMU_CAPS_KVM |
+ QEMU_CAPS_DRIVE_FORMAT |
+ QEMU_CAPS_MEM_PATH |
+ QEMU_CAPS_TDF,
9001, 1, 74);
DO_TEST("kvm-83-rhel56",
- QEMUD_CMD_FLAG_VNC_COLON |
- QEMUD_CMD_FLAG_NO_REBOOT |
- QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_BOOT |
- QEMUD_CMD_FLAG_NAME |
- QEMUD_CMD_FLAG_UUID |
- QEMUD_CMD_FLAG_VNET_HDR |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_TCP |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC |
- QEMUD_CMD_FLAG_DRIVE_CACHE_V2 |
- QEMUD_CMD_FLAG_KVM |
- QEMUD_CMD_FLAG_DRIVE_FORMAT |
- QEMUD_CMD_FLAG_DRIVE_SERIAL |
- QEMUD_CMD_FLAG_VGA |
- QEMUD_CMD_FLAG_PCIDEVICE |
- QEMUD_CMD_FLAG_MEM_PATH |
- QEMUD_CMD_FLAG_BALLOON |
- QEMUD_CMD_FLAG_RTC_TD_HACK |
- QEMUD_CMD_FLAG_NO_HPET |
- QEMUD_CMD_FLAG_NO_KVM_PIT |
- QEMUD_CMD_FLAG_TDF |
- QEMUD_CMD_FLAG_DRIVE_READONLY |
- QEMUD_CMD_FLAG_SMBIOS_TYPE |
- QEMUD_CMD_FLAG_SPICE,
+ QEMU_CAPS_VNC_COLON |
+ QEMU_CAPS_NO_REBOOT |
+ QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_BOOT |
+ QEMU_CAPS_NAME |
+ QEMU_CAPS_UUID |
+ QEMU_CAPS_VNET_HDR |
+ QEMU_CAPS_MIGRATE_QEMU_TCP |
+ QEMU_CAPS_MIGRATE_QEMU_EXEC |
+ QEMU_CAPS_DRIVE_CACHE_V2 |
+ QEMU_CAPS_KVM |
+ QEMU_CAPS_DRIVE_FORMAT |
+ QEMU_CAPS_DRIVE_SERIAL |
+ QEMU_CAPS_VGA |
+ QEMU_CAPS_PCIDEVICE |
+ QEMU_CAPS_MEM_PATH |
+ QEMU_CAPS_BALLOON |
+ QEMU_CAPS_RTC_TD_HACK |
+ QEMU_CAPS_NO_HPET |
+ QEMU_CAPS_NO_KVM_PIT |
+ QEMU_CAPS_TDF |
+ QEMU_CAPS_DRIVE_READONLY |
+ QEMU_CAPS_SMBIOS_TYPE |
+ QEMU_CAPS_SPICE,
9001, 1, 83);
DO_TEST("qemu-0.10.5",
- QEMUD_CMD_FLAG_KQEMU |
- QEMUD_CMD_FLAG_VNC_COLON |
- QEMUD_CMD_FLAG_NO_REBOOT |
- QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_NAME |
- QEMUD_CMD_FLAG_UUID |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_TCP |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC |
- QEMUD_CMD_FLAG_DRIVE_CACHE_V2 |
- QEMUD_CMD_FLAG_DRIVE_FORMAT |
- QEMUD_CMD_FLAG_DRIVE_SERIAL |
- QEMUD_CMD_FLAG_VGA |
- QEMUD_CMD_FLAG_0_10 |
- QEMUD_CMD_FLAG_ENABLE_KVM |
- QEMUD_CMD_FLAG_SDL |
- QEMUD_CMD_FLAG_RTC_TD_HACK |
- QEMUD_CMD_FLAG_NO_HPET |
- QEMUD_CMD_FLAG_VGA_NONE,
+ QEMU_CAPS_KQEMU |
+ QEMU_CAPS_VNC_COLON |
+ QEMU_CAPS_NO_REBOOT |
+ QEMU_CAPS_DRIVE |
+ QEMU_CAPS_NAME |
+ QEMU_CAPS_UUID |
+ QEMU_CAPS_MIGRATE_QEMU_TCP |
+ QEMU_CAPS_MIGRATE_QEMU_EXEC |
+ QEMU_CAPS_DRIVE_CACHE_V2 |
+ QEMU_CAPS_DRIVE_FORMAT |
+ QEMU_CAPS_DRIVE_SERIAL |
+ QEMU_CAPS_VGA |
+ QEMU_CAPS_0_10 |
+ QEMU_CAPS_ENABLE_KVM |
+ QEMU_CAPS_SDL |
+ QEMU_CAPS_RTC_TD_HACK |
+ QEMU_CAPS_NO_HPET |
+ QEMU_CAPS_VGA_NONE,
10005, 0, 0);
DO_TEST("qemu-kvm-0.10.5",
- QEMUD_CMD_FLAG_VNC_COLON |
- QEMUD_CMD_FLAG_NO_REBOOT |
- QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_BOOT |
- QEMUD_CMD_FLAG_NAME |
- QEMUD_CMD_FLAG_UUID |
- QEMUD_CMD_FLAG_VNET_HDR |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_TCP |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC |
- QEMUD_CMD_FLAG_DRIVE_CACHE_V2 |
- QEMUD_CMD_FLAG_KVM |
- QEMUD_CMD_FLAG_DRIVE_FORMAT |
- QEMUD_CMD_FLAG_DRIVE_SERIAL |
- QEMUD_CMD_FLAG_VGA |
- QEMUD_CMD_FLAG_0_10 |
- QEMUD_CMD_FLAG_PCIDEVICE |
- QEMUD_CMD_FLAG_MEM_PATH |
- QEMUD_CMD_FLAG_SDL |
- QEMUD_CMD_FLAG_RTC_TD_HACK |
- QEMUD_CMD_FLAG_NO_HPET |
- QEMUD_CMD_FLAG_NO_KVM_PIT |
- QEMUD_CMD_FLAG_TDF |
- QEMUD_CMD_FLAG_NESTING |
- QEMUD_CMD_FLAG_VGA_NONE,
+ QEMU_CAPS_VNC_COLON |
+ QEMU_CAPS_NO_REBOOT |
+ QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_BOOT |
+ QEMU_CAPS_NAME |
+ QEMU_CAPS_UUID |
+ QEMU_CAPS_VNET_HDR |
+ QEMU_CAPS_MIGRATE_QEMU_TCP |
+ QEMU_CAPS_MIGRATE_QEMU_EXEC |
+ QEMU_CAPS_DRIVE_CACHE_V2 |
+ QEMU_CAPS_KVM |
+ QEMU_CAPS_DRIVE_FORMAT |
+ QEMU_CAPS_DRIVE_SERIAL |
+ QEMU_CAPS_VGA |
+ QEMU_CAPS_0_10 |
+ QEMU_CAPS_PCIDEVICE |
+ QEMU_CAPS_MEM_PATH |
+ QEMU_CAPS_SDL |
+ QEMU_CAPS_RTC_TD_HACK |
+ QEMU_CAPS_NO_HPET |
+ QEMU_CAPS_NO_KVM_PIT |
+ QEMU_CAPS_TDF |
+ QEMU_CAPS_NESTING |
+ QEMU_CAPS_VGA_NONE,
10005, 1, 0);
DO_TEST("kvm-86",
- QEMUD_CMD_FLAG_VNC_COLON |
- QEMUD_CMD_FLAG_NO_REBOOT |
- QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_BOOT |
- QEMUD_CMD_FLAG_NAME |
- QEMUD_CMD_FLAG_UUID |
- QEMUD_CMD_FLAG_VNET_HDR |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_TCP |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC |
- QEMUD_CMD_FLAG_DRIVE_CACHE_V2 |
- QEMUD_CMD_FLAG_KVM |
- QEMUD_CMD_FLAG_DRIVE_FORMAT |
- QEMUD_CMD_FLAG_DRIVE_SERIAL |
- QEMUD_CMD_FLAG_VGA |
- QEMUD_CMD_FLAG_0_10 |
- QEMUD_CMD_FLAG_PCIDEVICE |
- QEMUD_CMD_FLAG_SDL |
- QEMUD_CMD_FLAG_RTC_TD_HACK |
- QEMUD_CMD_FLAG_NO_HPET |
- QEMUD_CMD_FLAG_NO_KVM_PIT |
- QEMUD_CMD_FLAG_TDF |
- QEMUD_CMD_FLAG_NESTING |
- QEMUD_CMD_FLAG_SMBIOS_TYPE |
- QEMUD_CMD_FLAG_VGA_NONE,
+ QEMU_CAPS_VNC_COLON |
+ QEMU_CAPS_NO_REBOOT |
+ QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_BOOT |
+ QEMU_CAPS_NAME |
+ QEMU_CAPS_UUID |
+ QEMU_CAPS_VNET_HDR |
+ QEMU_CAPS_MIGRATE_QEMU_TCP |
+ QEMU_CAPS_MIGRATE_QEMU_EXEC |
+ QEMU_CAPS_DRIVE_CACHE_V2 |
+ QEMU_CAPS_KVM |
+ QEMU_CAPS_DRIVE_FORMAT |
+ QEMU_CAPS_DRIVE_SERIAL |
+ QEMU_CAPS_VGA |
+ QEMU_CAPS_0_10 |
+ QEMU_CAPS_PCIDEVICE |
+ QEMU_CAPS_SDL |
+ QEMU_CAPS_RTC_TD_HACK |
+ QEMU_CAPS_NO_HPET |
+ QEMU_CAPS_NO_KVM_PIT |
+ QEMU_CAPS_TDF |
+ QEMU_CAPS_NESTING |
+ QEMU_CAPS_SMBIOS_TYPE |
+ QEMU_CAPS_VGA_NONE,
10050, 1, 0);
DO_TEST("qemu-kvm-0.11.0-rc2",
- QEMUD_CMD_FLAG_VNC_COLON |
- QEMUD_CMD_FLAG_NO_REBOOT |
- QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_BOOT |
- QEMUD_CMD_FLAG_NAME |
- QEMUD_CMD_FLAG_UUID |
- QEMUD_CMD_FLAG_VNET_HDR |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_TCP |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC |
- QEMUD_CMD_FLAG_DRIVE_CACHE_V2 |
- QEMUD_CMD_FLAG_KVM |
- QEMUD_CMD_FLAG_DRIVE_FORMAT |
- QEMUD_CMD_FLAG_DRIVE_SERIAL |
- QEMUD_CMD_FLAG_VGA |
- QEMUD_CMD_FLAG_0_10 |
- QEMUD_CMD_FLAG_PCIDEVICE |
- QEMUD_CMD_FLAG_MEM_PATH |
- QEMUD_CMD_FLAG_ENABLE_KVM |
- QEMUD_CMD_FLAG_BALLOON |
- QEMUD_CMD_FLAG_SDL |
- QEMUD_CMD_FLAG_RTC_TD_HACK |
- QEMUD_CMD_FLAG_NO_HPET |
- QEMUD_CMD_FLAG_NO_KVM_PIT |
- QEMUD_CMD_FLAG_TDF |
- QEMUD_CMD_FLAG_BOOT_MENU |
- QEMUD_CMD_FLAG_NESTING |
- QEMUD_CMD_FLAG_NAME_PROCESS |
- QEMUD_CMD_FLAG_SMBIOS_TYPE |
- QEMUD_CMD_FLAG_VGA_NONE,
+ QEMU_CAPS_VNC_COLON |
+ QEMU_CAPS_NO_REBOOT |
+ QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_BOOT |
+ QEMU_CAPS_NAME |
+ QEMU_CAPS_UUID |
+ QEMU_CAPS_VNET_HDR |
+ QEMU_CAPS_MIGRATE_QEMU_TCP |
+ QEMU_CAPS_MIGRATE_QEMU_EXEC |
+ QEMU_CAPS_DRIVE_CACHE_V2 |
+ QEMU_CAPS_KVM |
+ QEMU_CAPS_DRIVE_FORMAT |
+ QEMU_CAPS_DRIVE_SERIAL |
+ QEMU_CAPS_VGA |
+ QEMU_CAPS_0_10 |
+ QEMU_CAPS_PCIDEVICE |
+ QEMU_CAPS_MEM_PATH |
+ QEMU_CAPS_ENABLE_KVM |
+ QEMU_CAPS_BALLOON |
+ QEMU_CAPS_SDL |
+ QEMU_CAPS_RTC_TD_HACK |
+ QEMU_CAPS_NO_HPET |
+ QEMU_CAPS_NO_KVM_PIT |
+ QEMU_CAPS_TDF |
+ QEMU_CAPS_BOOT_MENU |
+ QEMU_CAPS_NESTING |
+ QEMU_CAPS_NAME_PROCESS |
+ QEMU_CAPS_SMBIOS_TYPE |
+ QEMU_CAPS_VGA_NONE,
10092, 1, 0);
DO_TEST("qemu-0.12.1",
- QEMUD_CMD_FLAG_VNC_COLON |
- QEMUD_CMD_FLAG_NO_REBOOT |
- QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_NAME |
- QEMUD_CMD_FLAG_UUID |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_TCP |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC |
- QEMUD_CMD_FLAG_DRIVE_CACHE_V2 |
- QEMUD_CMD_FLAG_DRIVE_FORMAT |
- QEMUD_CMD_FLAG_DRIVE_SERIAL |
- QEMUD_CMD_FLAG_DRIVE_READONLY |
- QEMUD_CMD_FLAG_VGA |
- QEMUD_CMD_FLAG_0_10 |
- QEMUD_CMD_FLAG_ENABLE_KVM |
- QEMUD_CMD_FLAG_SDL |
- QEMUD_CMD_FLAG_XEN_DOMID |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_UNIX |
- QEMUD_CMD_FLAG_CHARDEV |
- QEMUD_CMD_FLAG_BALLOON |
- QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_SMP_TOPOLOGY |
- QEMUD_CMD_FLAG_RTC |
- QEMUD_CMD_FLAG_NO_HPET |
- QEMUD_CMD_FLAG_BOOT_MENU |
- QEMUD_CMD_FLAG_NAME_PROCESS |
- QEMUD_CMD_FLAG_SMBIOS_TYPE |
- QEMUD_CMD_FLAG_VGA_NONE |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_FD |
- QEMUD_CMD_FLAG_DRIVE_AIO,
+ QEMU_CAPS_VNC_COLON |
+ QEMU_CAPS_NO_REBOOT |
+ QEMU_CAPS_DRIVE |
+ QEMU_CAPS_NAME |
+ QEMU_CAPS_UUID |
+ QEMU_CAPS_MIGRATE_QEMU_TCP |
+ QEMU_CAPS_MIGRATE_QEMU_EXEC |
+ QEMU_CAPS_DRIVE_CACHE_V2 |
+ QEMU_CAPS_DRIVE_FORMAT |
+ QEMU_CAPS_DRIVE_SERIAL |
+ QEMU_CAPS_DRIVE_READONLY |
+ QEMU_CAPS_VGA |
+ QEMU_CAPS_0_10 |
+ QEMU_CAPS_ENABLE_KVM |
+ QEMU_CAPS_SDL |
+ QEMU_CAPS_XEN_DOMID |
+ QEMU_CAPS_MIGRATE_QEMU_UNIX |
+ QEMU_CAPS_CHARDEV |
+ QEMU_CAPS_BALLOON |
+ QEMU_CAPS_DEVICE |
+ QEMU_CAPS_SMP_TOPOLOGY |
+ QEMU_CAPS_RTC |
+ QEMU_CAPS_NO_HPET |
+ QEMU_CAPS_BOOT_MENU |
+ QEMU_CAPS_NAME_PROCESS |
+ QEMU_CAPS_SMBIOS_TYPE |
+ QEMU_CAPS_VGA_NONE |
+ QEMU_CAPS_MIGRATE_QEMU_FD |
+ QEMU_CAPS_DRIVE_AIO,
12001, 0, 0);
DO_TEST("qemu-kvm-0.12.1.2-rhel60",
- QEMUD_CMD_FLAG_VNC_COLON |
- QEMUD_CMD_FLAG_NO_REBOOT |
- QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_BOOT |
- QEMUD_CMD_FLAG_NAME |
- QEMUD_CMD_FLAG_UUID |
- QEMUD_CMD_FLAG_VNET_HDR |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_TCP |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC |
- QEMUD_CMD_FLAG_DRIVE_CACHE_V2 |
- QEMUD_CMD_FLAG_KVM |
- QEMUD_CMD_FLAG_DRIVE_FORMAT |
- QEMUD_CMD_FLAG_DRIVE_SERIAL |
- QEMUD_CMD_FLAG_DRIVE_READONLY |
- QEMUD_CMD_FLAG_VGA |
- QEMUD_CMD_FLAG_0_10 |
- QEMUD_CMD_FLAG_PCIDEVICE |
- QEMUD_CMD_FLAG_MEM_PATH |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_UNIX |
- QEMUD_CMD_FLAG_CHARDEV |
- QEMUD_CMD_FLAG_ENABLE_KVM |
- QEMUD_CMD_FLAG_BALLOON |
- QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_SMP_TOPOLOGY |
- QEMUD_CMD_FLAG_RTC |
- QEMUD_CMD_FLAG_VNET_HOST |
- QEMUD_CMD_FLAG_NO_KVM_PIT |
- QEMUD_CMD_FLAG_TDF |
- QEMUD_CMD_FLAG_PCI_CONFIGFD |
- QEMUD_CMD_FLAG_NODEFCONFIG |
- QEMUD_CMD_FLAG_BOOT_MENU |
- QEMUD_CMD_FLAG_NESTING |
- QEMUD_CMD_FLAG_NAME_PROCESS |
- QEMUD_CMD_FLAG_SMBIOS_TYPE |
- QEMUD_CMD_FLAG_VGA_QXL |
- QEMUD_CMD_FLAG_SPICE |
- QEMUD_CMD_FLAG_VGA_NONE |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_FD |
- QEMUD_CMD_FLAG_DRIVE_AIO |
- QEMUD_CMD_FLAG_DEVICE_SPICEVMC,
+ QEMU_CAPS_VNC_COLON |
+ QEMU_CAPS_NO_REBOOT |
+ QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_BOOT |
+ QEMU_CAPS_NAME |
+ QEMU_CAPS_UUID |
+ QEMU_CAPS_VNET_HDR |
+ QEMU_CAPS_MIGRATE_QEMU_TCP |
+ QEMU_CAPS_MIGRATE_QEMU_EXEC |
+ QEMU_CAPS_DRIVE_CACHE_V2 |
+ QEMU_CAPS_KVM |
+ QEMU_CAPS_DRIVE_FORMAT |
+ QEMU_CAPS_DRIVE_SERIAL |
+ QEMU_CAPS_DRIVE_READONLY |
+ QEMU_CAPS_VGA |
+ QEMU_CAPS_0_10 |
+ QEMU_CAPS_PCIDEVICE |
+ QEMU_CAPS_MEM_PATH |
+ QEMU_CAPS_MIGRATE_QEMU_UNIX |
+ QEMU_CAPS_CHARDEV |
+ QEMU_CAPS_ENABLE_KVM |
+ QEMU_CAPS_BALLOON |
+ QEMU_CAPS_DEVICE |
+ QEMU_CAPS_SMP_TOPOLOGY |
+ QEMU_CAPS_RTC |
+ QEMU_CAPS_VNET_HOST |
+ QEMU_CAPS_NO_KVM_PIT |
+ QEMU_CAPS_TDF |
+ QEMU_CAPS_PCI_CONFIGFD |
+ QEMU_CAPS_NODEFCONFIG |
+ QEMU_CAPS_BOOT_MENU |
+ QEMU_CAPS_NESTING |
+ QEMU_CAPS_NAME_PROCESS |
+ QEMU_CAPS_SMBIOS_TYPE |
+ QEMU_CAPS_VGA_QXL |
+ QEMU_CAPS_SPICE |
+ QEMU_CAPS_VGA_NONE |
+ QEMU_CAPS_MIGRATE_QEMU_FD |
+ QEMU_CAPS_DRIVE_AIO |
+ QEMU_CAPS_DEVICE_SPICEVMC,
12001, 1, 0);
DO_TEST("qemu-kvm-0.12.3",
- QEMUD_CMD_FLAG_VNC_COLON |
- QEMUD_CMD_FLAG_NO_REBOOT |
- QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_BOOT |
- QEMUD_CMD_FLAG_NAME |
- QEMUD_CMD_FLAG_UUID |
- QEMUD_CMD_FLAG_VNET_HDR |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_TCP |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC |
- QEMUD_CMD_FLAG_DRIVE_CACHE_V2 |
- QEMUD_CMD_FLAG_KVM |
- QEMUD_CMD_FLAG_DRIVE_FORMAT |
- QEMUD_CMD_FLAG_DRIVE_SERIAL |
- QEMUD_CMD_FLAG_DRIVE_READONLY |
- QEMUD_CMD_FLAG_VGA |
- QEMUD_CMD_FLAG_0_10 |
- QEMUD_CMD_FLAG_PCIDEVICE |
- QEMUD_CMD_FLAG_MEM_PATH |
- QEMUD_CMD_FLAG_SDL |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_UNIX |
- QEMUD_CMD_FLAG_CHARDEV |
- QEMUD_CMD_FLAG_BALLOON |
- QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_SMP_TOPOLOGY |
- QEMUD_CMD_FLAG_RTC |
- QEMUD_CMD_FLAG_VNET_HOST |
- QEMUD_CMD_FLAG_NO_HPET |
- QEMUD_CMD_FLAG_NO_KVM_PIT |
- QEMUD_CMD_FLAG_TDF |
- QEMUD_CMD_FLAG_BOOT_MENU |
- QEMUD_CMD_FLAG_NESTING |
- QEMUD_CMD_FLAG_NAME_PROCESS |
- QEMUD_CMD_FLAG_SMBIOS_TYPE |
- QEMUD_CMD_FLAG_VGA_NONE |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_FD |
- QEMUD_CMD_FLAG_DRIVE_AIO,
+ QEMU_CAPS_VNC_COLON |
+ QEMU_CAPS_NO_REBOOT |
+ QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_BOOT |
+ QEMU_CAPS_NAME |
+ QEMU_CAPS_UUID |
+ QEMU_CAPS_VNET_HDR |
+ QEMU_CAPS_MIGRATE_QEMU_TCP |
+ QEMU_CAPS_MIGRATE_QEMU_EXEC |
+ QEMU_CAPS_DRIVE_CACHE_V2 |
+ QEMU_CAPS_KVM |
+ QEMU_CAPS_DRIVE_FORMAT |
+ QEMU_CAPS_DRIVE_SERIAL |
+ QEMU_CAPS_DRIVE_READONLY |
+ QEMU_CAPS_VGA |
+ QEMU_CAPS_0_10 |
+ QEMU_CAPS_PCIDEVICE |
+ QEMU_CAPS_MEM_PATH |
+ QEMU_CAPS_SDL |
+ QEMU_CAPS_MIGRATE_QEMU_UNIX |
+ QEMU_CAPS_CHARDEV |
+ QEMU_CAPS_BALLOON |
+ QEMU_CAPS_DEVICE |
+ QEMU_CAPS_SMP_TOPOLOGY |
+ QEMU_CAPS_RTC |
+ QEMU_CAPS_VNET_HOST |
+ QEMU_CAPS_NO_HPET |
+ QEMU_CAPS_NO_KVM_PIT |
+ QEMU_CAPS_TDF |
+ QEMU_CAPS_BOOT_MENU |
+ QEMU_CAPS_NESTING |
+ QEMU_CAPS_NAME_PROCESS |
+ QEMU_CAPS_SMBIOS_TYPE |
+ QEMU_CAPS_VGA_NONE |
+ QEMU_CAPS_MIGRATE_QEMU_FD |
+ QEMU_CAPS_DRIVE_AIO,
12003, 1, 0);
DO_TEST("qemu-kvm-0.13.0",
- QEMUD_CMD_FLAG_VNC_COLON |
- QEMUD_CMD_FLAG_NO_REBOOT |
- QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_BOOT |
- QEMUD_CMD_FLAG_NAME |
- QEMUD_CMD_FLAG_UUID |
- QEMUD_CMD_FLAG_VNET_HDR |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_TCP |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC |
- QEMUD_CMD_FLAG_DRIVE_CACHE_V2 |
- QEMUD_CMD_FLAG_KVM |
- QEMUD_CMD_FLAG_DRIVE_FORMAT |
- QEMUD_CMD_FLAG_DRIVE_SERIAL |
- QEMUD_CMD_FLAG_XEN_DOMID |
- QEMUD_CMD_FLAG_DRIVE_READONLY |
- QEMUD_CMD_FLAG_VGA |
- QEMUD_CMD_FLAG_0_10 |
- QEMUD_CMD_FLAG_PCIDEVICE |
- QEMUD_CMD_FLAG_MEM_PATH |
- QEMUD_CMD_FLAG_SDL |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_UNIX |
- QEMUD_CMD_FLAG_CHARDEV |
- QEMUD_CMD_FLAG_ENABLE_KVM |
- QEMUD_CMD_FLAG_MONITOR_JSON |
- QEMUD_CMD_FLAG_BALLOON |
- QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_SMP_TOPOLOGY |
- QEMUD_CMD_FLAG_NETDEV |
- QEMUD_CMD_FLAG_RTC |
- QEMUD_CMD_FLAG_VNET_HOST |
- QEMUD_CMD_FLAG_NO_HPET |
- QEMUD_CMD_FLAG_NO_KVM_PIT |
- QEMUD_CMD_FLAG_TDF |
- QEMUD_CMD_FLAG_PCI_CONFIGFD |
- QEMUD_CMD_FLAG_NODEFCONFIG |
- QEMUD_CMD_FLAG_BOOT_MENU |
- QEMUD_CMD_FLAG_FSDEV |
- QEMUD_CMD_FLAG_NESTING |
- QEMUD_CMD_FLAG_NAME_PROCESS |
- QEMUD_CMD_FLAG_SMBIOS_TYPE |
- QEMUD_CMD_FLAG_SPICE |
- QEMUD_CMD_FLAG_VGA_NONE |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_FD |
- QEMUD_CMD_FLAG_DRIVE_AIO |
- QEMUD_CMD_FLAG_DEVICE_SPICEVMC,
+ QEMU_CAPS_VNC_COLON |
+ QEMU_CAPS_NO_REBOOT |
+ QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_BOOT |
+ QEMU_CAPS_NAME |
+ QEMU_CAPS_UUID |
+ QEMU_CAPS_VNET_HDR |
+ QEMU_CAPS_MIGRATE_QEMU_TCP |
+ QEMU_CAPS_MIGRATE_QEMU_EXEC |
+ QEMU_CAPS_DRIVE_CACHE_V2 |
+ QEMU_CAPS_KVM |
+ QEMU_CAPS_DRIVE_FORMAT |
+ QEMU_CAPS_DRIVE_SERIAL |
+ QEMU_CAPS_XEN_DOMID |
+ QEMU_CAPS_DRIVE_READONLY |
+ QEMU_CAPS_VGA |
+ QEMU_CAPS_0_10 |
+ QEMU_CAPS_PCIDEVICE |
+ QEMU_CAPS_MEM_PATH |
+ QEMU_CAPS_SDL |
+ 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_VNET_HOST |
+ QEMU_CAPS_NO_HPET |
+ QEMU_CAPS_NO_KVM_PIT |
+ QEMU_CAPS_TDF |
+ QEMU_CAPS_PCI_CONFIGFD |
+ QEMU_CAPS_NODEFCONFIG |
+ QEMU_CAPS_BOOT_MENU |
+ QEMU_CAPS_FSDEV |
+ QEMU_CAPS_NESTING |
+ QEMU_CAPS_NAME_PROCESS |
+ QEMU_CAPS_SMBIOS_TYPE |
+ QEMU_CAPS_SPICE |
+ QEMU_CAPS_VGA_NONE |
+ QEMU_CAPS_MIGRATE_QEMU_FD |
+ QEMU_CAPS_DRIVE_AIO |
+ QEMU_CAPS_DEVICE_SPICEVMC,
13000, 1, 0);
DO_TEST("qemu-kvm-0.12.1.2-rhel61",
- QEMUD_CMD_FLAG_VNC_COLON |
- QEMUD_CMD_FLAG_NO_REBOOT |
- QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_NAME |
- QEMUD_CMD_FLAG_UUID |
- QEMUD_CMD_FLAG_VNET_HDR |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_TCP |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC |
- QEMUD_CMD_FLAG_DRIVE_CACHE_V2 |
- QEMUD_CMD_FLAG_KVM |
- QEMUD_CMD_FLAG_DRIVE_FORMAT |
- QEMUD_CMD_FLAG_DRIVE_SERIAL |
- QEMUD_CMD_FLAG_DRIVE_READONLY |
- QEMUD_CMD_FLAG_VGA |
- QEMUD_CMD_FLAG_0_10 |
- QEMUD_CMD_FLAG_PCIDEVICE |
- QEMUD_CMD_FLAG_MEM_PATH |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_UNIX |
- QEMUD_CMD_FLAG_CHARDEV |
- QEMUD_CMD_FLAG_ENABLE_KVM |
- QEMUD_CMD_FLAG_BALLOON |
- QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_SMP_TOPOLOGY |
- QEMUD_CMD_FLAG_RTC |
- QEMUD_CMD_FLAG_VNET_HOST |
- QEMUD_CMD_FLAG_NO_KVM_PIT |
- QEMUD_CMD_FLAG_TDF |
- QEMUD_CMD_FLAG_PCI_CONFIGFD |
- QEMUD_CMD_FLAG_NODEFCONFIG |
- QEMUD_CMD_FLAG_BOOT_MENU |
- QEMUD_CMD_FLAG_NESTING |
- QEMUD_CMD_FLAG_NAME_PROCESS |
- QEMUD_CMD_FLAG_SMBIOS_TYPE |
- QEMUD_CMD_FLAG_VGA_QXL |
- QEMUD_CMD_FLAG_SPICE |
- QEMUD_CMD_FLAG_VGA_NONE |
- QEMUD_CMD_FLAG_MIGRATE_QEMU_FD |
- QEMUD_CMD_FLAG_HDA_DUPLEX |
- QEMUD_CMD_FLAG_DRIVE_AIO |
- QEMUD_CMD_FLAG_CCID_PASSTHRU |
- QEMUD_CMD_FLAG_CHARDEV_SPICEVMC,
+ QEMU_CAPS_VNC_COLON |
+ QEMU_CAPS_NO_REBOOT |
+ QEMU_CAPS_DRIVE |
+ QEMU_CAPS_NAME |
+ QEMU_CAPS_UUID |
+ QEMU_CAPS_VNET_HDR |
+ QEMU_CAPS_MIGRATE_QEMU_TCP |
+ QEMU_CAPS_MIGRATE_QEMU_EXEC |
+ QEMU_CAPS_DRIVE_CACHE_V2 |
+ QEMU_CAPS_KVM |
+ QEMU_CAPS_DRIVE_FORMAT |
+ QEMU_CAPS_DRIVE_SERIAL |
+ QEMU_CAPS_DRIVE_READONLY |
+ QEMU_CAPS_VGA |
+ QEMU_CAPS_0_10 |
+ QEMU_CAPS_PCIDEVICE |
+ QEMU_CAPS_MEM_PATH |
+ QEMU_CAPS_MIGRATE_QEMU_UNIX |
+ QEMU_CAPS_CHARDEV |
+ QEMU_CAPS_ENABLE_KVM |
+ QEMU_CAPS_BALLOON |
+ QEMU_CAPS_DEVICE |
+ QEMU_CAPS_SMP_TOPOLOGY |
+ QEMU_CAPS_RTC |
+ QEMU_CAPS_VNET_HOST |
+ QEMU_CAPS_NO_KVM_PIT |
+ QEMU_CAPS_TDF |
+ QEMU_CAPS_PCI_CONFIGFD |
+ QEMU_CAPS_NODEFCONFIG |
+ QEMU_CAPS_BOOT_MENU |
+ QEMU_CAPS_NESTING |
+ QEMU_CAPS_NAME_PROCESS |
+ QEMU_CAPS_SMBIOS_TYPE |
+ QEMU_CAPS_VGA_QXL |
+ QEMU_CAPS_SPICE |
+ QEMU_CAPS_VGA_NONE |
+ QEMU_CAPS_MIGRATE_QEMU_FD |
+ QEMU_CAPS_HDA_DUPLEX |
+ QEMU_CAPS_DRIVE_AIO |
+ QEMU_CAPS_CCID_PASSTHRU |
+ QEMU_CAPS_CHARDEV_SPICEVMC,
12001, 1, 0);
return ret == 0 ? EXIT_SUCCESS : EXIT_FAILURE;
diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c
index 52808b5..55a8b09 100644
--- a/tests/qemuxml2argvtest.c
+++ b/tests/qemuxml2argvtest.c
@@ -79,7 +79,7 @@ static int testCompareXMLToArgvFiles(const char *xml,
goto fail;
}
- if (extraFlags & QEMUD_CMD_FLAG_DOMID)
+ if (extraFlags & QEMU_CAPS_DOMID)
vmdef->id = 6;
else
vmdef->id = -1;
@@ -89,14 +89,14 @@ static int testCompareXMLToArgvFiles(const char *xml,
monitor_chr.data.nix.path = (char *)"/tmp/test-monitor";
monitor_chr.data.nix.listen = true;
- flags = QEMUD_CMD_FLAG_VNC_COLON |
- QEMUD_CMD_FLAG_NO_REBOOT |
+ flags = QEMU_CAPS_VNC_COLON |
+ QEMU_CAPS_NO_REBOOT |
extraFlags;
if (qemudCanonicalizeMachine(&driver, vmdef) < 0)
goto fail;
- if (flags & QEMUD_CMD_FLAG_DEVICE) {
+ if (flags & QEMU_CAPS_DEVICE) {
qemuDomainPCIAddressSetPtr pciaddrs;
if (!(pciaddrs = qemuDomainPCIAddressSetCreate(vmdef)))
goto fail;
@@ -247,87 +247,87 @@ mymain(int argc, char **argv)
unsetenv("QEMU_AUDIO_DRV");
unsetenv("SDL_AUDIODRIVER");
- DO_TEST("minimal", QEMUD_CMD_FLAG_NAME, false);
+ DO_TEST("minimal", QEMU_CAPS_NAME, false);
DO_TEST("machine-aliases1", 0, false);
DO_TEST("machine-aliases2", 0, true);
DO_TEST("boot-cdrom", 0, false);
DO_TEST("boot-network", 0, false);
DO_TEST("boot-floppy", 0, false);
- DO_TEST("boot-multi", QEMUD_CMD_FLAG_BOOT_MENU, false);
- DO_TEST("boot-menu-disable", QEMUD_CMD_FLAG_BOOT_MENU, false);
- DO_TEST("boot-order", QEMUD_CMD_FLAG_BOOTINDEX |
- QEMUD_CMD_FLAG_DRIVE | QEMUD_CMD_FLAG_DEVICE, false);
- DO_TEST("bootloader", QEMUD_CMD_FLAG_DOMID, true);
+ DO_TEST("boot-multi", QEMU_CAPS_BOOT_MENU, false);
+ DO_TEST("boot-menu-disable", QEMU_CAPS_BOOT_MENU, false);
+ DO_TEST("boot-order", QEMU_CAPS_BOOTINDEX |
+ QEMU_CAPS_DRIVE | QEMU_CAPS_DEVICE, false);
+ DO_TEST("bootloader", QEMU_CAPS_DOMID, true);
DO_TEST("clock-utc", 0, false);
DO_TEST("clock-localtime", 0, false);
/*
* Can't be enabled since the absolute timestamp changes every time
- DO_TEST("clock-variable", QEMUD_CMD_FLAG_RTC, false);
+ DO_TEST("clock-variable", QEMU_CAPS_RTC, false);
*/
- DO_TEST("clock-france", QEMUD_CMD_FLAG_RTC, false);
+ DO_TEST("clock-france", QEMU_CAPS_RTC, false);
- DO_TEST("hugepages", QEMUD_CMD_FLAG_MEM_PATH, false);
+ DO_TEST("hugepages", QEMU_CAPS_MEM_PATH, false);
DO_TEST("disk-cdrom", 0, false);
- DO_TEST("disk-cdrom-empty", QEMUD_CMD_FLAG_DRIVE, false);
+ DO_TEST("disk-cdrom-empty", QEMU_CAPS_DRIVE, false);
DO_TEST("disk-floppy", 0, false);
DO_TEST("disk-many", 0, false);
- DO_TEST("disk-virtio", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_BOOT, false);
- DO_TEST("disk-xenvbd", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_BOOT, false);
- DO_TEST("disk-drive-boot-disk", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_BOOT, false);
- DO_TEST("disk-drive-boot-cdrom", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_BOOT, false);
- DO_TEST("floppy-drive-fat", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_BOOT | QEMUD_CMD_FLAG_DRIVE_FORMAT, false);
- DO_TEST("disk-drive-fat", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_BOOT | QEMUD_CMD_FLAG_DRIVE_FORMAT, false);
- DO_TEST("disk-drive-readonly-disk", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_READONLY | QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NODEFCONFIG, false);
- DO_TEST("disk-drive-readonly-no-device", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_READONLY | QEMUD_CMD_FLAG_NODEFCONFIG, false);
- DO_TEST("disk-drive-fmt-qcow", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_BOOT | QEMUD_CMD_FLAG_DRIVE_FORMAT, false);
- DO_TEST("disk-drive-shared", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_FORMAT | QEMUD_CMD_FLAG_DRIVE_SERIAL, false);
- DO_TEST("disk-drive-cache-v1-wt", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_FORMAT, false);
- DO_TEST("disk-drive-cache-v1-wb", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_FORMAT, false);
- DO_TEST("disk-drive-cache-v1-none", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_FORMAT, false);
- DO_TEST("disk-drive-error-policy-stop", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_MONITOR_JSON |
- QEMUD_CMD_FLAG_DRIVE_FORMAT, false);
- DO_TEST("disk-drive-cache-v2-wt", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_CACHE_V2 | QEMUD_CMD_FLAG_DRIVE_FORMAT, false);
- DO_TEST("disk-drive-cache-v2-wb", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_CACHE_V2 | QEMUD_CMD_FLAG_DRIVE_FORMAT, false);
- DO_TEST("disk-drive-cache-v2-none", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_CACHE_V2 | QEMUD_CMD_FLAG_DRIVE_FORMAT, false);
- DO_TEST("disk-drive-network-nbd", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_FORMAT, false);
- DO_TEST("disk-drive-network-rbd", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_FORMAT, false);
- DO_TEST("disk-drive-network-sheepdog", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DRIVE_FORMAT, false);
+ DO_TEST("disk-virtio", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_BOOT, false);
+ DO_TEST("disk-xenvbd", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_BOOT, false);
+ DO_TEST("disk-drive-boot-disk", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_BOOT, false);
+ DO_TEST("disk-drive-boot-cdrom", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_BOOT, false);
+ DO_TEST("floppy-drive-fat", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_BOOT | QEMU_CAPS_DRIVE_FORMAT, false);
+ DO_TEST("disk-drive-fat", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_BOOT | QEMU_CAPS_DRIVE_FORMAT, false);
+ DO_TEST("disk-drive-readonly-disk", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_READONLY | QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG, false);
+ DO_TEST("disk-drive-readonly-no-device", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_READONLY | QEMU_CAPS_NODEFCONFIG, false);
+ DO_TEST("disk-drive-fmt-qcow", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_BOOT | QEMU_CAPS_DRIVE_FORMAT, false);
+ DO_TEST("disk-drive-shared", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_FORMAT | QEMU_CAPS_DRIVE_SERIAL, false);
+ DO_TEST("disk-drive-cache-v1-wt", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_FORMAT, false);
+ DO_TEST("disk-drive-cache-v1-wb", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_FORMAT, false);
+ DO_TEST("disk-drive-cache-v1-none", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_FORMAT, false);
+ DO_TEST("disk-drive-error-policy-stop", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_MONITOR_JSON |
+ QEMU_CAPS_DRIVE_FORMAT, false);
+ DO_TEST("disk-drive-cache-v2-wt", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_CACHE_V2 | QEMU_CAPS_DRIVE_FORMAT, false);
+ DO_TEST("disk-drive-cache-v2-wb", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_CACHE_V2 | QEMU_CAPS_DRIVE_FORMAT, false);
+ DO_TEST("disk-drive-cache-v2-none", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_CACHE_V2 | QEMU_CAPS_DRIVE_FORMAT, false);
+ DO_TEST("disk-drive-network-nbd", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_FORMAT, false);
+ DO_TEST("disk-drive-network-rbd", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_FORMAT, false);
+ DO_TEST("disk-drive-network-sheepdog", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DRIVE_FORMAT, false);
DO_TEST("disk-usb", 0, false);
- DO_TEST("disk-usb-device", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DEVICE | QEMUD_CMD_FLAG_NODEFCONFIG, false);
- DO_TEST("disk-scsi-device", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DEVICE | QEMUD_CMD_FLAG_NODEFCONFIG, false);
- DO_TEST("disk-scsi-device-auto", QEMUD_CMD_FLAG_DRIVE |
- QEMUD_CMD_FLAG_DEVICE | QEMUD_CMD_FLAG_NODEFCONFIG, false);
- DO_TEST("disk-aio", QEMUD_CMD_FLAG_DRIVE | QEMUD_CMD_FLAG_DRIVE_AIO |
- QEMUD_CMD_FLAG_DRIVE_CACHE_V2 | QEMUD_CMD_FLAG_DRIVE_FORMAT, false);
+ DO_TEST("disk-usb-device", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DEVICE | QEMU_CAPS_NODEFCONFIG, false);
+ DO_TEST("disk-scsi-device", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DEVICE | QEMU_CAPS_NODEFCONFIG, false);
+ DO_TEST("disk-scsi-device-auto", QEMU_CAPS_DRIVE |
+ QEMU_CAPS_DEVICE | QEMU_CAPS_NODEFCONFIG, false);
+ DO_TEST("disk-aio", QEMU_CAPS_DRIVE | QEMU_CAPS_DRIVE_AIO |
+ QEMU_CAPS_DRIVE_CACHE_V2 | QEMU_CAPS_DRIVE_FORMAT, false);
DO_TEST("graphics-vnc", 0, false);
DO_TEST("graphics-vnc-socket", 0, false);
driver.vncSASL = 1;
driver.vncSASLdir = strdup("/root/.sasl2");
- DO_TEST("graphics-vnc-sasl", QEMUD_CMD_FLAG_VGA, false);
+ DO_TEST("graphics-vnc-sasl", QEMU_CAPS_VGA, false);
driver.vncTLS = 1;
driver.vncTLSx509verify = 1;
driver.vncTLSx509certdir = strdup("/etc/pki/tls/qemu");
@@ -339,29 +339,29 @@ mymain(int argc, char **argv)
DO_TEST("graphics-sdl", 0, false);
DO_TEST("graphics-sdl-fullscreen", 0, false);
- DO_TEST("nographics", QEMUD_CMD_FLAG_VGA, false);
- DO_TEST("nographics-vga", QEMUD_CMD_FLAG_VGA |
- QEMUD_CMD_FLAG_VGA_NONE, false);
+ DO_TEST("nographics", QEMU_CAPS_VGA, false);
+ DO_TEST("nographics-vga", QEMU_CAPS_VGA |
+ QEMU_CAPS_VGA_NONE, false);
DO_TEST("graphics-spice",
- QEMUD_CMD_FLAG_VGA | QEMUD_CMD_FLAG_VGA_QXL |
- QEMUD_CMD_FLAG_DEVICE | QEMUD_CMD_FLAG_SPICE, false);
+ QEMU_CAPS_VGA | QEMU_CAPS_VGA_QXL |
+ QEMU_CAPS_DEVICE | QEMU_CAPS_SPICE, false);
DO_TEST("input-usbmouse", 0, false);
DO_TEST("input-usbtablet", 0, false);
- DO_TEST("input-xen", QEMUD_CMD_FLAG_DOMID, true);
+ DO_TEST("input-xen", QEMU_CAPS_DOMID, true);
DO_TEST("misc-acpi", 0, false);
DO_TEST("misc-no-reboot", 0, false);
- DO_TEST("misc-uuid", QEMUD_CMD_FLAG_NAME |
- QEMUD_CMD_FLAG_UUID, false);
+ DO_TEST("misc-uuid", QEMU_CAPS_NAME |
+ QEMU_CAPS_UUID, false);
DO_TEST("net-user", 0, false);
DO_TEST("net-virtio", 0, false);
- DO_TEST("net-virtio-device", QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NODEFCONFIG, false);
- DO_TEST("net-virtio-netdev", QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NETDEV | QEMUD_CMD_FLAG_NODEFCONFIG, false);
+ DO_TEST("net-virtio-device", QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG, false);
+ DO_TEST("net-virtio-netdev", QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NETDEV | QEMU_CAPS_NODEFCONFIG, false);
DO_TEST("net-eth", 0, false);
DO_TEST("net-eth-ifname", 0, false);
- DO_TEST("net-eth-names", QEMUD_CMD_FLAG_NET_NAME, false);
+ DO_TEST("net-eth-names", QEMU_CAPS_NET_NAME, false);
DO_TEST("serial-vc", 0, false);
DO_TEST("serial-pty", 0, false);
@@ -376,103 +376,103 @@ mymain(int argc, char **argv)
DO_TEST("console-compat", 0, false);
DO_TEST("console-compat-auto", 0, false);
- DO_TEST("serial-vc-chardev", QEMUD_CMD_FLAG_CHARDEV|QEMUD_CMD_FLAG_DEVICE
|
- QEMUD_CMD_FLAG_NODEFCONFIG, false);
- DO_TEST("serial-pty-chardev", QEMUD_CMD_FLAG_CHARDEV|QEMUD_CMD_FLAG_DEVICE
|
- QEMUD_CMD_FLAG_NODEFCONFIG, false);
- DO_TEST("serial-dev-chardev", QEMUD_CMD_FLAG_CHARDEV|QEMUD_CMD_FLAG_DEVICE
|
- QEMUD_CMD_FLAG_NODEFCONFIG, false);
- DO_TEST("serial-file-chardev", QEMUD_CMD_FLAG_CHARDEV|QEMUD_CMD_FLAG_DEVICE
|
- QEMUD_CMD_FLAG_NODEFCONFIG, false);
- DO_TEST("serial-unix-chardev", QEMUD_CMD_FLAG_CHARDEV|QEMUD_CMD_FLAG_DEVICE
|
- QEMUD_CMD_FLAG_NODEFCONFIG, false);
- DO_TEST("serial-tcp-chardev", QEMUD_CMD_FLAG_CHARDEV|QEMUD_CMD_FLAG_DEVICE
|
- QEMUD_CMD_FLAG_NODEFCONFIG, false);
- DO_TEST("serial-udp-chardev", QEMUD_CMD_FLAG_CHARDEV|QEMUD_CMD_FLAG_DEVICE
|
- QEMUD_CMD_FLAG_NODEFCONFIG, false);
- DO_TEST("serial-tcp-telnet-chardev",
QEMUD_CMD_FLAG_CHARDEV|QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NODEFCONFIG, false);
- DO_TEST("serial-many-chardev", QEMUD_CMD_FLAG_CHARDEV|QEMUD_CMD_FLAG_DEVICE
|
- QEMUD_CMD_FLAG_NODEFCONFIG, false);
- DO_TEST("parallel-tcp-chardev",
QEMUD_CMD_FLAG_CHARDEV|QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NODEFCONFIG, false);
- DO_TEST("console-compat-chardev",
QEMUD_CMD_FLAG_CHARDEV|QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NODEFCONFIG, false);
-
- DO_TEST("channel-guestfwd", QEMUD_CMD_FLAG_CHARDEV|QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NODEFCONFIG, false);
- DO_TEST("channel-virtio", QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NODEFCONFIG, false);
- DO_TEST("channel-virtio-auto", QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NODEFCONFIG, false);
- DO_TEST("console-virtio", QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NODEFCONFIG, false);
- DO_TEST("channel-spicevmc", QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NODEFCONFIG | QEMUD_CMD_FLAG_SPICE |
- QEMUD_CMD_FLAG_CHARDEV_SPICEVMC, false);
- DO_TEST("channel-spicevmc-old", QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NODEFCONFIG | QEMUD_CMD_FLAG_SPICE |
- QEMUD_CMD_FLAG_DEVICE_SPICEVMC, false);
+ DO_TEST("serial-vc-chardev", QEMU_CAPS_CHARDEV|QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG, false);
+ DO_TEST("serial-pty-chardev", QEMU_CAPS_CHARDEV|QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG, false);
+ DO_TEST("serial-dev-chardev", QEMU_CAPS_CHARDEV|QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG, false);
+ DO_TEST("serial-file-chardev", QEMU_CAPS_CHARDEV|QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG, false);
+ DO_TEST("serial-unix-chardev", QEMU_CAPS_CHARDEV|QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG, false);
+ DO_TEST("serial-tcp-chardev", QEMU_CAPS_CHARDEV|QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG, false);
+ DO_TEST("serial-udp-chardev", QEMU_CAPS_CHARDEV|QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG, false);
+ DO_TEST("serial-tcp-telnet-chardev", QEMU_CAPS_CHARDEV|QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG, false);
+ DO_TEST("serial-many-chardev", QEMU_CAPS_CHARDEV|QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG, false);
+ DO_TEST("parallel-tcp-chardev", QEMU_CAPS_CHARDEV|QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG, false);
+ DO_TEST("console-compat-chardev", QEMU_CAPS_CHARDEV|QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG, false);
+
+ DO_TEST("channel-guestfwd", QEMU_CAPS_CHARDEV|QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG, false);
+ DO_TEST("channel-virtio", QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG, false);
+ DO_TEST("channel-virtio-auto", QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG, false);
+ DO_TEST("console-virtio", QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG, false);
+ DO_TEST("channel-spicevmc", QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG | QEMU_CAPS_SPICE |
+ QEMU_CAPS_CHARDEV_SPICEVMC, false);
+ DO_TEST("channel-spicevmc-old", QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG | QEMU_CAPS_SPICE |
+ QEMU_CAPS_DEVICE_SPICEVMC, false);
DO_TEST("smartcard-host",
- QEMUD_CMD_FLAG_CHARDEV | QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NODEFCONFIG | QEMUD_CMD_FLAG_CCID_EMULATED, false);
+ QEMU_CAPS_CHARDEV | QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG | QEMU_CAPS_CCID_EMULATED, false);
DO_TEST("smartcard-host-certificates",
- QEMUD_CMD_FLAG_CHARDEV | QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NODEFCONFIG | QEMUD_CMD_FLAG_CCID_EMULATED, false);
+ QEMU_CAPS_CHARDEV | QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG | QEMU_CAPS_CCID_EMULATED, false);
DO_TEST("smartcard-passthrough-tcp",
- QEMUD_CMD_FLAG_CHARDEV | QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NODEFCONFIG | QEMUD_CMD_FLAG_CCID_PASSTHRU, false);
+ QEMU_CAPS_CHARDEV | QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG | QEMU_CAPS_CCID_PASSTHRU, false);
DO_TEST("smartcard-passthrough-spicevmc",
- QEMUD_CMD_FLAG_CHARDEV | QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NODEFCONFIG | QEMUD_CMD_FLAG_CCID_PASSTHRU |
- QEMUD_CMD_FLAG_CHARDEV_SPICEVMC, false);
+ QEMU_CAPS_CHARDEV | QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG | QEMU_CAPS_CCID_PASSTHRU |
+ QEMU_CAPS_CHARDEV_SPICEVMC, false);
DO_TEST("smartcard-controller",
- QEMUD_CMD_FLAG_CHARDEV | QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NODEFCONFIG | QEMUD_CMD_FLAG_CCID_EMULATED, false);
+ QEMU_CAPS_CHARDEV | QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG | QEMU_CAPS_CCID_EMULATED, false);
- DO_TEST("smbios", QEMUD_CMD_FLAG_SMBIOS_TYPE, false);
+ DO_TEST("smbios", QEMU_CAPS_SMBIOS_TYPE, false);
DO_TEST("watchdog", 0, false);
- DO_TEST("watchdog-device", QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NODEFCONFIG, false);
+ DO_TEST("watchdog-device", QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG, false);
DO_TEST("watchdog-dump", 0, false);
- DO_TEST("balloon-device", QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NODEFCONFIG, false);
- DO_TEST("balloon-device-auto", QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NODEFCONFIG, false);
+ DO_TEST("balloon-device", QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG, false);
+ DO_TEST("balloon-device-auto", QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG, false);
DO_TEST("sound", 0, false);
- DO_TEST("sound-device", QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NODEFCONFIG | QEMUD_CMD_FLAG_HDA_DUPLEX, false);
- DO_TEST("fs9p", QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NODEFCONFIG | QEMUD_CMD_FLAG_FSDEV, false);
+ DO_TEST("sound-device", QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG | QEMU_CAPS_HDA_DUPLEX, false);
+ DO_TEST("fs9p", QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG | QEMU_CAPS_FSDEV, false);
DO_TEST("hostdev-usb-address", 0, false);
- DO_TEST("hostdev-usb-address-device", QEMUD_CMD_FLAG_DEVICE |
- QEMUD_CMD_FLAG_NODEFCONFIG, false);
- DO_TEST("hostdev-pci-address", QEMUD_CMD_FLAG_PCIDEVICE, false);
- DO_TEST("hostdev-pci-address-device", QEMUD_CMD_FLAG_PCIDEVICE |
- QEMUD_CMD_FLAG_DEVICE | QEMUD_CMD_FLAG_NODEFCONFIG, false);
+ DO_TEST("hostdev-usb-address-device", QEMU_CAPS_DEVICE |
+ QEMU_CAPS_NODEFCONFIG, false);
+ DO_TEST("hostdev-pci-address", QEMU_CAPS_PCIDEVICE, false);
+ DO_TEST("hostdev-pci-address-device", QEMU_CAPS_PCIDEVICE |
+ QEMU_CAPS_DEVICE | QEMU_CAPS_NODEFCONFIG, false);
- DO_TEST_FULL("restore-v1", QEMUD_CMD_FLAG_MIGRATE_KVM_STDIO,
"stdio", 7,
+ DO_TEST_FULL("restore-v1", QEMU_CAPS_MIGRATE_KVM_STDIO, "stdio",
7,
false);
- DO_TEST_FULL("restore-v2", QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC,
"stdio", 7,
+ DO_TEST_FULL("restore-v2", QEMU_CAPS_MIGRATE_QEMU_EXEC, "stdio",
7,
false);
- DO_TEST_FULL("restore-v2", QEMUD_CMD_FLAG_MIGRATE_QEMU_EXEC,
"exec:cat", 7,
+ DO_TEST_FULL("restore-v2", QEMU_CAPS_MIGRATE_QEMU_EXEC,
"exec:cat", 7,
false);
- DO_TEST_FULL("restore-v2-fd", QEMUD_CMD_FLAG_MIGRATE_QEMU_FD,
"stdio", 7,
+ DO_TEST_FULL("restore-v2-fd", QEMU_CAPS_MIGRATE_QEMU_FD, "stdio",
7,
false);
- DO_TEST_FULL("restore-v2-fd", QEMUD_CMD_FLAG_MIGRATE_QEMU_FD,
"fd:7", 7,
+ DO_TEST_FULL("restore-v2-fd", QEMU_CAPS_MIGRATE_QEMU_FD, "fd:7",
7,
false);
- DO_TEST_FULL("migrate", QEMUD_CMD_FLAG_MIGRATE_QEMU_TCP,
+ DO_TEST_FULL("migrate", QEMU_CAPS_MIGRATE_QEMU_TCP,
"tcp:10.0.0.1:5000", -1, false);
DO_TEST("qemu-ns", 0, false);
- DO_TEST("smp", QEMUD_CMD_FLAG_SMP_TOPOLOGY, false);
+ DO_TEST("smp", QEMU_CAPS_SMP_TOPOLOGY, false);
- DO_TEST("cpu-topology1", QEMUD_CMD_FLAG_SMP_TOPOLOGY, false);
- DO_TEST("cpu-topology2", QEMUD_CMD_FLAG_SMP_TOPOLOGY, false);
+ DO_TEST("cpu-topology1", QEMU_CAPS_SMP_TOPOLOGY, false);
+ DO_TEST("cpu-topology2", QEMU_CAPS_SMP_TOPOLOGY, false);
DO_TEST("cpu-topology3", 0, false);
DO_TEST("cpu-minimum1", 0, false);
DO_TEST("cpu-minimum2", 0, false);
--
1.7.4