RHEL-only
drive-mirror and drive-reopen are still under upstream qemu
discussion; as a result, RHEL decided to backport things under
a downstream name. Accommodate this alternate spelling. I
don't think it's worth trying to support both spellings at once:
if you build upstream libvirt on RHEL, you lose out on the
feature, but then you are also capable of building upstream qemu
for RHEL to reinstate the feature (that is, if you use RHEL, you
should either stick to the distro patches, or you are assumed to
be capable of building the entire virt stack yourself).
* src/qemu/qemu_monitor_json.c (qemuMonitorJSONCheckCommands):
Check for alternate spelling.
(int qemuMonitorJSONDriveMirror, qemuMonitorJSONDriveReopen): Use
that spelling.
---
src/qemu/qemu_monitor_json.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/src/qemu/qemu_monitor_json.c b/src/qemu/qemu_monitor_json.c
index bb080e5..2718fef 100644
--- a/src/qemu/qemu_monitor_json.c
+++ b/src/qemu/qemu_monitor_json.c
@@ -973,9 +973,9 @@ qemuMonitorJSONCheckCommands(qemuMonitorPtr mon,
qemuCapsSet(qemuCaps, QEMU_CAPS_WAKEUP);
else if (STREQ(name, "transaction"))
qemuCapsSet(qemuCaps, QEMU_CAPS_TRANSACTION);
- else if (STREQ(name, "drive-mirror"))
+ else if (STREQ(name, "__com.redhat_drive-mirror"))
qemuCapsSet(qemuCaps, QEMU_CAPS_DRIVE_MIRROR);
- else if (STREQ(name, "drive-reopen"))
+ else if (STREQ(name, "__com.redhat_drive-reopen"))
qemuCapsSet(qemuCaps, QEMU_CAPS_DRIVE_REOPEN);
}
@@ -3203,7 +3203,7 @@ qemuMonitorJSONDriveMirror(qemuMonitorPtr mon ATTRIBUTE_UNUSED,
virJSONValuePtr reply = NULL;
cmd = qemuMonitorJSONMakeCommandRaw(actions != NULL,
- "drive-mirror",
+ "__com.redhat_drive-mirror",
"s:device", device,
"s:target", file,
"s:mode",
@@ -3268,7 +3268,7 @@ qemuMonitorJSONDriveReopen(qemuMonitorPtr mon, const char *device,
virJSONValuePtr cmd;
virJSONValuePtr reply = NULL;
- cmd = qemuMonitorJSONMakeCommand("drive-reopen",
+ cmd = qemuMonitorJSONMakeCommand("__com.redhat_drive-reopen",
"s:device", device,
"s:new-image-file", file,
format ? "s:format" : NULL, format,
--
1.7.7.6