* [PATCH 01/88] scripts/checkpatch: skip trailer checks inside patch diff
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 02/88] build-sys: bump minimum glib version to v2.68 Marc-André Lureau
` (88 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Chao Liu
The duplicate-trailer and self-review checks matched trailer-like
lines inside the diff body, not just in the commit message. Gate
the check on !$is_patch so it only runs before the diff starts.
Fixes: c3db8e70451 ("scripts/checkpatch: warn on duplicate trailers and self-review")
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
scripts/checkpatch.pl | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index 9838a6417851..c023767f9670 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -1834,7 +1834,7 @@ sub process {
}
# Check for duplicate trailers and self-review
- if (!$in_header_lines &&
+ if (!$in_header_lines && !$is_patch &&
$line =~ /^\s*([A-Z][a-zA-Z]*(?:-[a-zA-Z]+)*):\s*(.+)/) {
my $trailer_type = $1;
my $trailer_value = $2;
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 02/88] build-sys: bump minimum glib version to v2.68
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
2026-09-22 20:17 ` [PATCH 01/88] scripts/checkpatch: skip trailer checks inside patch diff Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 03/88] docs/devel: minor fix in qom documentation Marc-André Lureau
` (87 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel
Cc: Kevin Wolf, Marc-André Lureau, Richard Henderson,
Paolo Bonzini, Alex Bennée, Pierrick Bouvier,
Alexandre Iooss, Christian Schoenebeck, Greg Kurz,
Michael S. Tsirkin, Igor Mammedov, Ani Sinha,
Philippe Mathieu-Daudé, Zhao Liu, Stefan Weil, Jason Wang,
Gerd Hoffmann, Fam Zheng, Alex Williamson, Cédric Le Goater,
Laurent Vivier, Helge Deller, Daniel P. Berrangé, Zhang Chen,
Li Zhijian, Markus Armbruster, Michael Roth, Chao Liu, Peter Xu
CentOS Stream 9 bumped glib to 2.68, according to repology,
this is the floor version:
centos_stream_9 9 2.68.4
debian_12 12 2.74.6
fedora_43 43 2.86.5
freebsd 15.1 2.88.3
openbsd 7.8 2.88.3
opensuse_leap_15_6 15.6 2.78.6
ubuntu_24_04 24.04 2.80.0
homebrew rolling 2.90.0
msys2_mingw rolling 2.90.0
2.68 brings g_memdup2() for which we had a compat, but also has
GStrvBuilder, g_string_replace(), g_test_get_path() among other nice API
additions.
Replace deprecate g_memdup() usage, and checkpatch check is now
redundant with compile-time deprecation error.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
accel/tcg/cputlb.c | 4 ++--
contrib/plugins/lockstep.c | 25 -------------------------
hw/9pfs/9p-synth.c | 2 +-
hw/9pfs/9p-util.h | 2 +-
hw/9pfs/9p.c | 2 +-
hw/acpi/core.c | 2 +-
hw/core/machine.c | 2 +-
hw/i386/multiboot.c | 2 +-
hw/net/eepro100.c | 2 +-
hw/nvram/fw_cfg.c | 8 ++++----
hw/scsi/mptsas.c | 5 +++--
hw/vfio/pci.c | 2 +-
include/glib-compat.h | 41 ++---------------------------------------
linux-user/syscall.c | 2 +-
linux-user/uaccess.c | 2 +-
meson.build | 2 +-
net/colo.c | 4 ++--
qapi/qapi-clone-visitor.c | 16 ++++++++--------
qapi/qapi-visit-core.c | 6 ++++--
scripts/checkpatch.pl | 5 -----
system/memory.c | 2 +-
system/vl.c | 2 +-
22 files changed, 38 insertions(+), 102 deletions(-)
diff --git a/accel/tcg/cputlb.c b/accel/tcg/cputlb.c
index 7f7c208ba121..a91bd167cf8a 100644
--- a/accel/tcg/cputlb.c
+++ b/accel/tcg/cputlb.c
@@ -833,13 +833,13 @@ void tlb_flush_range_by_mmuidx_all_cpus_synced(CPUState *src_cpu,
/* Allocate a separate data block for each destination cpu. */
CPU_FOREACH(dst_cpu) {
if (dst_cpu != src_cpu) {
- p = g_memdup(&d, sizeof(d));
+ p = g_memdup2(&d, sizeof(d));
async_run_on_cpu(dst_cpu, tlb_flush_range_by_mmuidx_async_1,
RUN_ON_CPU_HOST_PTR(p));
}
}
- p = g_memdup(&d, sizeof(d));
+ p = g_memdup2(&d, sizeof(d));
async_safe_run_on_cpu(src_cpu, tlb_flush_range_by_mmuidx_async_1,
RUN_ON_CPU_HOST_PTR(p));
}
diff --git a/contrib/plugins/lockstep.c b/contrib/plugins/lockstep.c
index ed9d18460fe3..a92658f0115b 100644
--- a/contrib/plugins/lockstep.c
+++ b/contrib/plugins/lockstep.c
@@ -101,31 +101,6 @@ static void plugin_exit(void *p)
plugin_cleanup(NULL);
}
-/*
- * g_memdup has been deprecated in Glib since 2.68 and
- * will complain about it if you try to use it. However until
- * glib_req_ver for QEMU is bumped we make a copy of the glib-compat
- * handler.
- */
-static inline gpointer g_memdup2_qemu(gconstpointer mem, gsize byte_size)
-{
-#if GLIB_CHECK_VERSION(2, 68, 0)
- return g_memdup2(mem, byte_size);
-#else
- gpointer new_mem;
-
- if (mem && byte_size != 0) {
- new_mem = g_malloc(byte_size);
- memcpy(new_mem, mem, byte_size);
- } else {
- new_mem = NULL;
- }
-
- return new_mem;
-#endif
-}
-#define g_memdup2(m, s) g_memdup2_qemu(m, s)
-
static void report_divergance(ExecState *us, ExecState *them)
{
DivergeState divrec = { log, 0 };
diff --git a/hw/9pfs/9p-synth.c b/hw/9pfs/9p-synth.c
index 3b3654b2820b..225bb43d8a9b 100644
--- a/hw/9pfs/9p-synth.c
+++ b/hw/9pfs/9p-synth.c
@@ -525,7 +525,7 @@ static int synth_name_to_path(FsContext *ctx, V9fsPath *dir_path,
out:
/* Copy the node pointer to fid */
g_free(target->data);
- target->data = g_memdup(&node, sizeof(void *));
+ target->data = g_memdup2(&node, sizeof(void *));
target->size = sizeof(void *);
return 0;
}
diff --git a/hw/9pfs/9p-util.h b/hw/9pfs/9p-util.h
index 8dfa803dc2c0..68bc33eeeb72 100644
--- a/hw/9pfs/9p-util.h
+++ b/hw/9pfs/9p-util.h
@@ -265,7 +265,7 @@ static inline struct dirent *qemu_dirent_dup(struct dirent *dent)
sz = offsetof(struct dirent, d_name) +
strlen(dent->d_name) + 1;
}
- return g_memdup(dent, sz);
+ return g_memdup2(dent, sz);
}
/*
diff --git a/hw/9pfs/9p.c b/hw/9pfs/9p.c
index 4764d9db13b1..ffb43993c7a3 100644
--- a/hw/9pfs/9p.c
+++ b/hw/9pfs/9p.c
@@ -229,7 +229,7 @@ void v9fs_path_copy(V9fsPath *dst, const V9fsPath *src)
{
v9fs_path_free(dst);
dst->size = src->size;
- dst->data = g_memdup(src->data, src->size);
+ dst->data = g_memdup2(src->data, src->size);
}
int v9fs_name_to_path(V9fsState *s, V9fsPath *dirpath,
diff --git a/hw/acpi/core.c b/hw/acpi/core.c
index a6a62a742d11..3de7bbd6c6d9 100644
--- a/hw/acpi/core.c
+++ b/hw/acpi/core.c
@@ -647,7 +647,7 @@ void acpi_pm1_cnt_init(ACPIREGS *ar, MemoryRegion *parent,
suspend[3] = 1 | ((!disable_s3) << 7);
suspend[4] = s4_val | ((!disable_s4) << 7);
- fw_cfg_add_file(fw_cfg, "etc/system-states", g_memdup(suspend, 6), 6);
+ fw_cfg_add_file(fw_cfg, "etc/system-states", g_memdup2(suspend, 6), 6);
}
}
diff --git a/hw/core/machine.c b/hw/core/machine.c
index 92f7be52a13f..c99b7ade2161 100644
--- a/hw/core/machine.c
+++ b/hw/core/machine.c
@@ -739,7 +739,7 @@ HotpluggableCPUList *machine_query_hotpluggable_cpus(MachineState *machine)
cpu_item->type = g_strdup(machine->possible_cpus->cpus[i].type);
cpu_item->vcpus_count = machine->possible_cpus->cpus[i].vcpus_count;
- cpu_item->props = g_memdup(&machine->possible_cpus->cpus[i].props,
+ cpu_item->props = g_memdup2(&machine->possible_cpus->cpus[i].props,
sizeof(*cpu_item->props));
cpu = machine->possible_cpus->cpus[i].cpu;
diff --git a/hw/i386/multiboot.c b/hw/i386/multiboot.c
index d544b62afbd5..a59a59338975 100644
--- a/hw/i386/multiboot.c
+++ b/hw/i386/multiboot.c
@@ -387,7 +387,7 @@ int load_multiboot(X86MachineState *x86ms,
mb_debug(" mb_mods_count = %d", mbs.mb_mods_count);
/* save bootinfo off the stack */
- mb_bootinfo_data = g_memdup(bootinfo, sizeof(bootinfo));
+ mb_bootinfo_data = g_memdup2(bootinfo, sizeof(bootinfo));
/* Pass variables to option rom */
fw_cfg_add_i32(fw_cfg, FW_CFG_KERNEL_ENTRY, mh_entry_addr);
diff --git a/hw/net/eepro100.c b/hw/net/eepro100.c
index aaa3eb60f8ab..cbf9e400f3ec 100644
--- a/hw/net/eepro100.c
+++ b/hw/net/eepro100.c
@@ -1883,7 +1883,7 @@ static void e100_nic_realize(PCIDevice *pci_dev, Error **errp)
qemu_register_reset(nic_reset, s);
- s->vmstate = g_memdup(&vmstate_eepro100, sizeof(vmstate_eepro100));
+ s->vmstate = g_memdup2(&vmstate_eepro100, sizeof(vmstate_eepro100));
s->vmstate->name = qemu_get_queue(s->nic)->model;
vmstate_register_any(VMSTATE_IF(&pci_dev->qdev), s->vmstate, s);
}
diff --git a/hw/nvram/fw_cfg.c b/hw/nvram/fw_cfg.c
index b057d870c004..62102f6cf3fc 100644
--- a/hw/nvram/fw_cfg.c
+++ b/hw/nvram/fw_cfg.c
@@ -197,7 +197,7 @@ static void fw_cfg_bootsplash(FWCfgState *s)
/* use little endian format */
bst_le16 = cpu_to_le16(bst_val);
fw_cfg_add_file(s, "etc/boot-menu-wait",
- g_memdup(&bst_le16, sizeof bst_le16), sizeof bst_le16);
+ g_memdup2(&bst_le16, sizeof bst_le16), sizeof bst_le16);
}
/* insert splash file if user configurated */
@@ -247,7 +247,7 @@ static void fw_cfg_reboot(FWCfgState *s)
}
rt_le32 = cpu_to_le32(rt_val);
- fw_cfg_add_file(s, "etc/boot-fail-wait", g_memdup(&rt_le32, 4), 4);
+ fw_cfg_add_file(s, "etc/boot-fail-wait", g_memdup2(&rt_le32, 4), 4);
}
static void fw_cfg_write(FWCfgState *s, uint8_t value)
@@ -745,7 +745,7 @@ void fw_cfg_add_string(FWCfgState *s, uint16_t key, const char *value)
size_t sz = strlen(value) + 1;
trace_fw_cfg_add_string(key, trace_key_name(key), value);
- fw_cfg_add_bytes(s, key, g_memdup(value, sz), sz);
+ fw_cfg_add_bytes(s, key, g_memdup2(value, sz), sz);
}
void fw_cfg_modify_string(FWCfgState *s, uint16_t key, const char *value)
@@ -753,7 +753,7 @@ void fw_cfg_modify_string(FWCfgState *s, uint16_t key, const char *value)
size_t sz = strlen(value) + 1;
char *old;
- old = fw_cfg_modify_bytes_read(s, key, g_memdup(value, sz), sz);
+ old = fw_cfg_modify_bytes_read(s, key, g_memdup2(value, sz), sz);
g_free(old);
}
diff --git a/hw/scsi/mptsas.c b/hw/scsi/mptsas.c
index 5df124c0ce50..fef94ae28bb9 100644
--- a/hw/scsi/mptsas.c
+++ b/hw/scsi/mptsas.c
@@ -458,7 +458,8 @@ static void mptsas_process_scsi_task_mgmt(MPTSASState *s, MPIMsgSCSITaskMgmt *re
} else {
MPTSASCancelNotifier *notifier;
- reply_async = g_memdup(&reply, sizeof(MPIMsgSCSITaskMgmtReply));
+ reply_async = g_memdup2(&reply,
+ sizeof(MPIMsgSCSITaskMgmtReply));
reply_async->IOCLogInfo = INT_MAX;
count = 1;
@@ -485,7 +486,7 @@ static void mptsas_process_scsi_task_mgmt(MPTSASState *s, MPIMsgSCSITaskMgmt *re
goto out;
}
- reply_async = g_memdup(&reply, sizeof(MPIMsgSCSITaskMgmtReply));
+ reply_async = g_memdup2(&reply, sizeof(MPIMsgSCSITaskMgmtReply));
reply_async->IOCLogInfo = INT_MAX;
count = 0;
diff --git a/hw/vfio/pci.c b/hw/vfio/pci.c
index 428ab2f06983..1a0dddbd8d94 100644
--- a/hw/vfio/pci.c
+++ b/hw/vfio/pci.c
@@ -2646,7 +2646,7 @@ static void vfio_add_ext_cap(VFIOPCIDevice *vdev, bool ats_needed)
* physical device, we cache the config space to avoid overwriting
* the original config space when we parse the extended capabilities.
*/
- config = g_memdup(pdev->config, vdev->config_size);
+ config = g_memdup2(pdev->config, vdev->config_size);
/*
* Extended capabilities are chained with each pointing to the next, so we
diff --git a/include/glib-compat.h b/include/glib-compat.h
index 32ee2afdcdf5..1be08ab2764b 100644
--- a/include/glib-compat.h
+++ b/include/glib-compat.h
@@ -19,12 +19,12 @@
/* Ask for warnings for anything that was marked deprecated in
* the defined version, or before. It is a candidate for rewrite.
*/
-#define GLIB_VERSION_MIN_REQUIRED GLIB_VERSION_2_66
+#define GLIB_VERSION_MIN_REQUIRED GLIB_VERSION_2_68
/* Ask for warnings if code tries to use function that did not
* exist in the defined version. These risk breaking builds
*/
-#define GLIB_VERSION_MAX_ALLOWED GLIB_VERSION_2_66
+#define GLIB_VERSION_MAX_ALLOWED GLIB_VERSION_2_68
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
@@ -76,43 +76,6 @@
* without generating warnings.
*/
-/*
- * g_memdup2_qemu:
- * @mem: (nullable): the memory to copy.
- * @byte_size: the number of bytes to copy.
- *
- * Allocates @byte_size bytes of memory, and copies @byte_size bytes into it
- * from @mem. If @mem is %NULL it returns %NULL.
- *
- * This replaces g_memdup(), which was prone to integer overflows when
- * converting the argument from a #gsize to a #guint.
- *
- * This static inline version is a backport of the new public API from
- * GLib 2.68, kept internal to GLib for backport to older stable releases.
- * See https://gitlab.gnome.org/GNOME/glib/-/issues/2319.
- *
- * Returns: (nullable): a pointer to the newly-allocated copy of the memory,
- * or %NULL if @mem is %NULL.
- */
-static inline gpointer g_memdup2_qemu(gconstpointer mem, gsize byte_size)
-{
-#if GLIB_CHECK_VERSION(2, 68, 0)
- return g_memdup2(mem, byte_size);
-#else
- gpointer new_mem;
-
- if (mem && byte_size != 0) {
- new_mem = g_malloc(byte_size);
- memcpy(new_mem, mem, byte_size);
- } else {
- new_mem = NULL;
- }
-
- return new_mem;
-#endif
-}
-#define g_memdup2(m, s) g_memdup2_qemu(m, s)
-
static inline bool
qemu_g_test_slow(void)
{
diff --git a/linux-user/syscall.c b/linux-user/syscall.c
index 9f454502cb6f..8c62c52d7f2e 100644
--- a/linux-user/syscall.c
+++ b/linux-user/syscall.c
@@ -8373,7 +8373,7 @@ static abi_long do_open_by_handle_at(abi_long mount_fd, abi_long handle,
return -TARGET_EFAULT;
}
- fh = g_memdup(target_fh, total_size);
+ fh = g_memdup2(target_fh, total_size);
fh->handle_bytes = size;
fh->handle_type = tswap32(target_fh->handle_type);
diff --git a/linux-user/uaccess.c b/linux-user/uaccess.c
index f9bd713edd76..cddd60e0007b 100644
--- a/linux-user/uaccess.c
+++ b/linux-user/uaccess.c
@@ -16,7 +16,7 @@ void *lock_user(int type, abi_ulong guest_addr, ssize_t len, bool copy)
host_addr = g2h_untagged(guest_addr);
#ifdef CONFIG_DEBUG_REMAP
if (copy) {
- host_addr = g_memdup(host_addr, len);
+ host_addr = g_memdup2(host_addr, len);
} else {
host_addr = g_malloc0(len);
}
diff --git a/meson.build b/meson.build
index cfac634cf13e..e9bf1c310ab4 100644
--- a/meson.build
+++ b/meson.build
@@ -1058,7 +1058,7 @@ have_xen_pci_passthrough = get_option('xen_pci_passthrough') \
# the _WIN32_WINNT setting in osdep.h according to the value from glib.
# You should also check if any of the glib.version() checks
# below can also be removed.
-glib_req_ver = '>=2.66.0'
+glib_req_ver = '>=2.68.0'
glib_pc = dependency('glib-2.0', version: glib_req_ver, required: true,
method: 'pkg-config')
glib_cflags = []
diff --git a/net/colo.c b/net/colo.c
index fb2c36a026f8..21d6b250015f 100644
--- a/net/colo.c
+++ b/net/colo.c
@@ -166,7 +166,7 @@ Packet *packet_new(const void *data, int size, int vnet_hdr_len)
{
Packet *pkt = g_slice_new0(Packet);
- pkt->data = g_memdup(data, size);
+ pkt->data = g_memdup2(data, size);
pkt->size = size;
pkt->creation_ms = qemu_clock_get_ms(QEMU_CLOCK_HOST);
pkt->vnet_hdr_len = vnet_hdr_len;
@@ -221,7 +221,7 @@ Connection *connection_get(GHashTable *connection_track_table,
Connection *conn = g_hash_table_lookup(connection_track_table, key);
if (conn == NULL) {
- ConnectionKey *new_key = g_memdup(key, sizeof(*key));
+ ConnectionKey *new_key = g_memdup2(key, sizeof(*key));
conn = connection_new(key);
diff --git a/qapi/qapi-clone-visitor.c b/qapi/qapi-clone-visitor.c
index 30997638de50..7ee26cb64464 100644
--- a/qapi/qapi-clone-visitor.c
+++ b/qapi/qapi-clone-visitor.c
@@ -37,7 +37,7 @@ static bool qapi_clone_start_struct(Visitor *v, const char *name, void **obj,
return true;
}
- *obj = g_memdup(*obj, size);
+ *obj = g_memdup2(*obj, size);
qcv->depth++;
return true;
}
@@ -65,8 +65,8 @@ static GenericList *qapi_clone_next_list(Visitor *v, GenericList *tail,
QapiCloneVisitor *qcv = to_qcv(v);
assert(qcv->depth);
- /* Unshare the tail of the list cloned by g_memdup() */
- tail->next = g_memdup(tail->next, size);
+ /* Unshare the tail of the list cloned by g_memdup2() */
+ tail->next = g_memdup2(tail->next, size);
return tail->next;
}
@@ -83,7 +83,7 @@ static bool qapi_clone_type_int64(Visitor *v, const char *name, int64_t *obj,
QapiCloneVisitor *qcv = to_qcv(v);
assert(qcv->depth);
- /* Value was already cloned by g_memdup() */
+ /* Value was already cloned by g_memdup2() */
return true;
}
@@ -93,7 +93,7 @@ static bool qapi_clone_type_uint64(Visitor *v, const char *name,
QapiCloneVisitor *qcv = to_qcv(v);
assert(qcv->depth);
- /* Value was already cloned by g_memdup() */
+ /* Value was already cloned by g_memdup2() */
return true;
}
@@ -103,7 +103,7 @@ static bool qapi_clone_type_bool(Visitor *v, const char *name, bool *obj,
QapiCloneVisitor *qcv = to_qcv(v);
assert(qcv->depth);
- /* Value was already cloned by g_memdup() */
+ /* Value was already cloned by g_memdup2() */
return true;
}
@@ -114,7 +114,7 @@ static bool qapi_clone_type_str(Visitor *v, const char *name, char **obj,
assert(qcv->depth);
/*
- * Pointer was already cloned by g_memdup; create fresh copy.
+ * Pointer was already cloned by g_memdup2; create fresh copy.
* Note that as long as qobject-output-visitor accepts NULL instead of
* "", then we must do likewise. However, we want to obey the
* input visitor semantics of never producing NULL when the empty
@@ -130,7 +130,7 @@ static bool qapi_clone_type_number(Visitor *v, const char *name, double *obj,
QapiCloneVisitor *qcv = to_qcv(v);
assert(qcv->depth);
- /* Value was already cloned by g_memdup() */
+ /* Value was already cloned by g_memdup2() */
return true;
}
diff --git a/qapi/qapi-visit-core.c b/qapi/qapi-visit-core.c
index 706c61e02608..469b5694f401 100644
--- a/qapi/qapi-visit-core.c
+++ b/qapi/qapi-visit-core.c
@@ -432,8 +432,10 @@ bool visit_type_enum(Visitor *v, const char *name, int *obj,
case VISITOR_OUTPUT:
return output_type_enum(v, name, obj, lookup, errp);
case VISITOR_CLONE:
- /* nothing further to do, scalar value was already copied by
- * g_memdup() during visit_start_*() */
+ /*
+ * nothing further to do, scalar value was already copied by
+ * g_memdup2() during visit_start_*()
+ */
return true;
case VISITOR_DEALLOC:
/* nothing to deallocate for a scalar */
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index c023767f9670..5c46567ad03c 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -3253,11 +3253,6 @@ sub process {
WARN("consider using g_path_get_$1() in preference to g_strdup($1())\n" . $herecurr);
}
-# enforce g_memdup2() over g_memdup()
- if ($line =~ /\bg_memdup\s*\(/) {
- ERROR("use g_memdup2() instead of unsafe g_memdup()\n" . $herecurr);
- }
-
# recommend qemu_strto* over strto* for numeric conversions
if ($line =~ /\b(strto[^kd].*?)\s*\(/) {
ERROR("consider using qemu_$1 in preference to $1\n" . $herecurr);
diff --git a/system/memory.c b/system/memory.c
index 264dc90c0a55..7ada0f6d8caa 100644
--- a/system/memory.c
+++ b/system/memory.c
@@ -1198,7 +1198,7 @@ static char *memory_region_escape_name(const char *name)
bytes += memory_region_need_escape(*p) ? 4 : 1;
}
if (bytes == p - name) {
- return g_memdup(name, bytes + 1);
+ return g_memdup2(name, bytes + 1);
}
escaped = g_malloc(bytes + 1);
diff --git a/system/vl.c b/system/vl.c
index 468a9fc247ac..d9617a6e25e1 100644
--- a/system/vl.c
+++ b/system/vl.c
@@ -1186,7 +1186,7 @@ static int parse_fw_cfg(void *opaque, QemuOpts *opts, Error **errp)
}
if (nonempty_str(str)) {
size = strlen(str); /* NUL terminator NOT included in fw_cfg blob */
- buf = g_memdup(str, size);
+ buf = g_memdup2(str, size);
} else if (nonempty_str(gen_id)) {
if (!fw_cfg_add_file_from_generator(fw_cfg, object_get_objects_root(),
gen_id, name, errp)) {
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 03/88] docs/devel: minor fix in qom documentation
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
2026-09-22 20:17 ` [PATCH 01/88] scripts/checkpatch: skip trailer checks inside patch diff Marc-André Lureau
2026-09-22 20:17 ` [PATCH 02/88] build-sys: bump minimum glib version to v2.68 Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 04/88] qom: auto-terminate interfaces array in OBJECT_DEFINE_TYPE macros Marc-André Lureau
` (86 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel
Cc: Kevin Wolf, Marc-André Lureau, Paolo Bonzini,
Daniel P. Berrangé, Pierrick Bouvier
It declares an autoptr for the instance.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
docs/devel/qom.rst | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/devel/qom.rst b/docs/devel/qom.rst
index 935bb1004a78..9e467b6df857 100644
--- a/docs/devel/qom.rst
+++ b/docs/devel/qom.rst
@@ -328,7 +328,7 @@ This is equivalent to the following:
typedef struct MyDevice MyDevice;
typedef struct MyDeviceClass MyDeviceClass;
- G_DEFINE_AUTOPTR_CLEANUP_FUNC(MyDeviceClass, object_unref)
+ G_DEFINE_AUTOPTR_CLEANUP_FUNC(MyDevice, object_unref)
#define MY_DEVICE_GET_CLASS(void *obj) \
OBJECT_GET_CLASS(MyDeviceClass, obj, TYPE_MY_DEVICE)
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 04/88] qom: auto-terminate interfaces array in OBJECT_DEFINE_TYPE macros
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (2 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 03/88] docs/devel: minor fix in qom documentation Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-23 12:26 ` BALATON Zoltan
2026-09-22 20:17 ` [PATCH 05/88] qemu-io: drop "qemu-io:" prefix in error-report Marc-André Lureau
` (85 subsequent siblings)
89 siblings, 1 reply; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel
Cc: Kevin Wolf, Marc-André Lureau, Gerd Hoffmann,
Stefano Garzarella, Ani Sinha, Michael S. Tsirkin, Igor Mammedov,
Peter Maydell, Maciej S. Szmigiero, Nicholas Piggin,
Harsh Prateek Bora, Amit Machhiwal, David Hildenbrand,
Paolo Bonzini, Daniel P. Berrangé, Peter Xu,
Philippe Mathieu-Daudé, Marcelo Tosatti, Halil Pasic,
Christian Borntraeger, Eric Farman, Matthew Rosato, Cornelia Huck,
Richard Henderson, Ilya Leoshkevich, qemu-ppc, kvm, qemu-s390x
The DO_OBJECT_DEFINE_TYPE_EXTENDED macro requires callers to manually
append a NULL sentinel to the interfaces list. Forgetting it causes
out-of-bounds reads during type registration, leading to run-time
crashes.
Append an empty initializer in the base macro so the sentinel is always
present, and drop the now-redundant manual terminators from all callers.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
backends/igvm-cfg.c | 3 +--
hw/acpi/pci.c | 6 ++----
hw/core/reset.c | 4 +++-
hw/core/resetcontainer.c | 5 ++++-
hw/hyperv/hv-balloon.c | 2 +-
hw/ppc/pef.c | 3 +--
hw/virtio/virtio-mem.c | 6 +++++-
include/qom/object.h | 6 +++---
system/ram-block-attributes.c | 3 +--
target/i386/kvm/tdx.c | 3 +--
target/s390x/kvm/pv.c | 3 +--
11 files changed, 23 insertions(+), 21 deletions(-)
diff --git a/backends/igvm-cfg.c b/backends/igvm-cfg.c
index 935ba54f54f3..8ec7d4ab6174 100644
--- a/backends/igvm-cfg.c
+++ b/backends/igvm-cfg.c
@@ -72,8 +72,7 @@ static void igvm_complete(UserCreatable *uc, Error **errp)
OBJECT_DEFINE_TYPE_WITH_INTERFACES(IgvmCfg, igvm_cfg, IGVM_CFG, OBJECT,
{ TYPE_USER_CREATABLE },
- { TYPE_RESETTABLE_INTERFACE },
- { NULL })
+ { TYPE_RESETTABLE_INTERFACE })
static void igvm_cfg_class_init(ObjectClass *oc, const void *data)
{
diff --git a/hw/acpi/pci.c b/hw/acpi/pci.c
index c82924be8620..5a96c0e77817 100644
--- a/hw/acpi/pci.c
+++ b/hw/acpi/pci.c
@@ -83,8 +83,7 @@ typedef struct AcpiGenericInitiatorClass {
OBJECT_DEFINE_TYPE_WITH_INTERFACES(AcpiGenericInitiator, acpi_generic_initiator,
ACPI_GENERIC_INITIATOR, OBJECT,
- { TYPE_USER_CREATABLE },
- { NULL })
+ { TYPE_USER_CREATABLE })
OBJECT_DECLARE_SIMPLE_TYPE(AcpiGenericInitiator, ACPI_GENERIC_INITIATOR)
@@ -199,8 +198,7 @@ typedef struct AcpiGenericPortClass {
OBJECT_DEFINE_TYPE_WITH_INTERFACES(AcpiGenericPort, acpi_generic_port,
ACPI_GENERIC_PORT, OBJECT,
- { TYPE_USER_CREATABLE },
- { NULL })
+ { TYPE_USER_CREATABLE })
OBJECT_DECLARE_SIMPLE_TYPE(AcpiGenericPort, ACPI_GENERIC_PORT)
diff --git a/hw/core/reset.c b/hw/core/reset.c
index e7230b49b704..c35ac9b9c9a7 100644
--- a/hw/core/reset.c
+++ b/hw/core/reset.c
@@ -58,7 +58,9 @@ struct LegacyReset {
bool skip_on_snapshot_load;
};
-OBJECT_DEFINE_SIMPLE_TYPE_WITH_INTERFACES(LegacyReset, legacy_reset, LEGACY_RESET, OBJECT, { TYPE_RESETTABLE_INTERFACE }, { })
+OBJECT_DEFINE_SIMPLE_TYPE_WITH_INTERFACES(LegacyReset, legacy_reset,
+ LEGACY_RESET, OBJECT,
+ { TYPE_RESETTABLE_INTERFACE })
static ResettableState *legacy_reset_get_state(Object *obj)
{
diff --git a/hw/core/resetcontainer.c b/hw/core/resetcontainer.c
index a4a6476a0363..cc46a1c62b82 100644
--- a/hw/core/resetcontainer.c
+++ b/hw/core/resetcontainer.c
@@ -24,7 +24,10 @@ struct ResettableContainer {
GPtrArray *children;
};
-OBJECT_DEFINE_SIMPLE_TYPE_WITH_INTERFACES(ResettableContainer, resettable_container, RESETTABLE_CONTAINER, OBJECT, { TYPE_RESETTABLE_INTERFACE }, { })
+OBJECT_DEFINE_SIMPLE_TYPE_WITH_INTERFACES(ResettableContainer,
+ resettable_container,
+ RESETTABLE_CONTAINER, OBJECT,
+ { TYPE_RESETTABLE_INTERFACE })
void resettable_container_add(ResettableContainer *rc, Object *obj)
{
diff --git a/hw/hyperv/hv-balloon.c b/hw/hyperv/hv-balloon.c
index b8664a246b47..36e54c6a4c26 100644
--- a/hw/hyperv/hv-balloon.c
+++ b/hw/hyperv/hv-balloon.c
@@ -160,7 +160,7 @@ typedef struct HvBalloon {
OBJECT_DEFINE_SIMPLE_TYPE_WITH_INTERFACES(HvBalloon, hv_balloon, \
HV_BALLOON, VMBUS_DEVICE, \
- { TYPE_MEMORY_DEVICE }, { })
+ { TYPE_MEMORY_DEVICE })
#define HV_BALLOON_SET_STATE(hvb, news) \
do { \
diff --git a/hw/ppc/pef.c b/hw/ppc/pef.c
index 39b4ce94f10b..a055774caebc 100644
--- a/hw/ppc/pef.c
+++ b/hw/ppc/pef.c
@@ -124,8 +124,7 @@ OBJECT_DEFINE_TYPE_WITH_INTERFACES(PefGuest,
pef_guest,
PEF_GUEST,
CONFIDENTIAL_GUEST_SUPPORT,
- { TYPE_USER_CREATABLE },
- { NULL })
+ { TYPE_USER_CREATABLE })
static void pef_guest_class_init(ObjectClass *oc, const void *data)
{
diff --git a/hw/virtio/virtio-mem.c b/hw/virtio/virtio-mem.c
index 7130ed852d9c..488ee25dec53 100644
--- a/hw/virtio/virtio-mem.c
+++ b/hw/virtio/virtio-mem.c
@@ -1681,7 +1681,11 @@ static void virtio_register_types(void)
type_init(virtio_register_types)
-OBJECT_DEFINE_SIMPLE_TYPE_WITH_INTERFACES(VirtioMemSystemReset, virtio_mem_system_reset, VIRTIO_MEM_SYSTEM_RESET, OBJECT, { TYPE_RESETTABLE_INTERFACE }, { })
+OBJECT_DEFINE_SIMPLE_TYPE_WITH_INTERFACES(VirtioMemSystemReset,
+ virtio_mem_system_reset,
+ VIRTIO_MEM_SYSTEM_RESET,
+ OBJECT,
+ { TYPE_RESETTABLE_INTERFACE })
static void virtio_mem_system_reset_init(Object *obj)
{
diff --git a/include/qom/object.h b/include/qom/object.h
index 328521866463..24727906ec02 100644
--- a/include/qom/object.h
+++ b/include/qom/object.h
@@ -294,7 +294,7 @@ struct Object
.class_size = CLASS_SIZE, \
.class_init = module_obj_name##_class_init, \
.abstract = ABSTRACT, \
- .interfaces = (const InterfaceInfo[]) { __VA_ARGS__ } , \
+ .interfaces = (const InterfaceInfo[]) { __VA_ARGS__, { } } , \
}; \
\
static void \
@@ -365,8 +365,8 @@ struct Object
* for the common case of a non-abstract type, with one or more implemented
* interfaces.
*
- * Note when passing the list of interfaces, be sure to include the final
- * NULL entry, e.g. { TYPE_USER_CREATABLE }, { NULL }
+ * The NULL terminator is added automatically by the macro, so only
+ * the actual interfaces need to be listed, e.g. { TYPE_USER_CREATABLE }
*/
#define OBJECT_DEFINE_TYPE_WITH_INTERFACES(ModuleObjName, module_obj_name, \
MODULE_OBJ_NAME, \
diff --git a/system/ram-block-attributes.c b/system/ram-block-attributes.c
index 59ec7a28eb05..4ef70b5a4082 100644
--- a/system/ram-block-attributes.c
+++ b/system/ram-block-attributes.c
@@ -18,8 +18,7 @@ OBJECT_DEFINE_SIMPLE_TYPE_WITH_INTERFACES(RamBlockAttributes,
ram_block_attributes,
RAM_BLOCK_ATTRIBUTES,
OBJECT,
- { TYPE_RAM_DISCARD_SOURCE },
- { })
+ { TYPE_RAM_DISCARD_SOURCE })
static size_t
ram_block_attributes_get_block_size(void)
diff --git a/target/i386/kvm/tdx.c b/target/i386/kvm/tdx.c
index 8294dbde3aa8..f1fa9e7ffe2b 100644
--- a/target/i386/kvm/tdx.c
+++ b/target/i386/kvm/tdx.c
@@ -1559,8 +1559,7 @@ OBJECT_DEFINE_TYPE_WITH_INTERFACES(TdxGuest,
TDX_GUEST,
X86_CONFIDENTIAL_GUEST,
{ TYPE_USER_CREATABLE },
- { TYPE_RESETTABLE_INTERFACE },
- { NULL })
+ { TYPE_RESETTABLE_INTERFACE })
static void tdx_guest_init(Object *obj)
{
diff --git a/target/s390x/kvm/pv.c b/target/s390x/kvm/pv.c
index 3d508165f348..8d4a7b5275e1 100644
--- a/target/s390x/kvm/pv.c
+++ b/target/s390x/kvm/pv.c
@@ -402,8 +402,7 @@ OBJECT_DEFINE_TYPE_WITH_INTERFACES(S390PVGuest,
s390_pv_guest,
S390_PV_GUEST,
CONFIDENTIAL_GUEST_SUPPORT,
- { TYPE_USER_CREATABLE },
- { NULL })
+ { TYPE_USER_CREATABLE })
static void s390_pv_guest_class_init(ObjectClass *oc, const void *data)
{
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* Re: [PATCH 04/88] qom: auto-terminate interfaces array in OBJECT_DEFINE_TYPE macros
2026-09-22 20:17 ` [PATCH 04/88] qom: auto-terminate interfaces array in OBJECT_DEFINE_TYPE macros Marc-André Lureau
@ 2026-09-23 12:26 ` BALATON Zoltan
0 siblings, 0 replies; 98+ messages in thread
From: BALATON Zoltan @ 2026-09-23 12:26 UTC (permalink / raw)
To: Marc-André Lureau
Cc: qemu-devel, Kevin Wolf, Gerd Hoffmann, Stefano Garzarella,
Ani Sinha, Michael S. Tsirkin, Igor Mammedov, Peter Maydell,
Maciej S. Szmigiero, Nicholas Piggin, Harsh Prateek Bora,
Amit Machhiwal, David Hildenbrand, Paolo Bonzini,
Daniel P. Berrangé, Peter Xu, Philippe Mathieu-Daudé,
Marcelo Tosatti, Halil Pasic, Christian Borntraeger, Eric Farman,
Matthew Rosato, Cornelia Huck, Richard Henderson,
Ilya Leoshkevich, qemu-ppc, kvm, qemu-s390x
[-- Attachment #1: Type: text/plain, Size: 897 bytes --]
On Wed, 23 Sep 2026, Marc-André Lureau wrote:
> The DO_OBJECT_DEFINE_TYPE_EXTENDED macro requires callers to manually
> append a NULL sentinel to the interfaces list. Forgetting it causes
> out-of-bounds reads during type registration, leading to run-time
> crashes.
>
> Append an empty initializer in the base macro so the sentinel is always
> present, and drop the now-redundant manual terminators from all callers.
This is nice however another similar common list, the TypeInfo.interfaces
still requires explicit NULL termination and now these are inconsistent
which can also lead to people get confused where to add NULL element and
where can it be omitted. Maybe we should consider adding a macro to make
interface lists that adds the terminating element and use that everywhere
or just stick to require explicit NULL at the end of interfaces list
everywhere?
Regards,
BALATON Zoltan
^ permalink raw reply [flat|nested] 98+ messages in thread
* [PATCH 05/88] qemu-io: drop "qemu-io:" prefix in error-report
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (3 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 04/88] qom: auto-terminate interfaces array in OBJECT_DEFINE_TYPE macros Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 21:04 ` Vladimir Sementsov-Ogievskiy
2026-09-22 20:17 ` [PATCH 06/88] monitor: allow a bare Monitor Marc-André Lureau
` (84 subsequent siblings)
89 siblings, 1 reply; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel
Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, Eric Blake,
Vladimir Sementsov-Ogievskiy, Markus Armbruster, qemu-block
qemu-io is still primarily an interactive program, and constantly
printing the name of the program you're interacting with has little
value.
Suggested-by: Kevin Wolf <kwolf@redhat.com>
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
qemu-io.c | 4 +
tests/qemu-iotests/004.out | 20 +-
tests/qemu-iotests/021.out | 60 ++--
tests/qemu-iotests/026.out | 396 ++++++++++-----------
tests/qemu-iotests/026.out.nocache | 168 ++++-----
tests/qemu-iotests/059.out | 6 +-
tests/qemu-iotests/060.out | 46 +--
tests/qemu-iotests/061.out | 4 +-
tests/qemu-iotests/069.out | 2 +-
tests/qemu-iotests/070.out | 2 +-
tests/qemu-iotests/071.out | 4 +-
tests/qemu-iotests/072.out | 2 +-
tests/qemu-iotests/075.out | 14 +-
tests/qemu-iotests/076.out | 6 +-
tests/qemu-iotests/078.out | 12 +-
tests/qemu-iotests/080.out | 44 +--
tests/qemu-iotests/081.out | 4 +-
tests/qemu-iotests/083.out | 104 +++---
tests/qemu-iotests/088.out | 12 +-
tests/qemu-iotests/089.out | 4 +-
tests/qemu-iotests/092.out | 24 +-
tests/qemu-iotests/103.out | 14 +-
tests/qemu-iotests/114.out | 4 +-
tests/qemu-iotests/116.out | 14 +-
tests/qemu-iotests/133.out | 30 +-
tests/qemu-iotests/134.out | 2 +-
tests/qemu-iotests/137.out | 30 +-
tests/qemu-iotests/140.out | 2 +-
tests/qemu-iotests/143.out | 4 +-
tests/qemu-iotests/153.out | 42 +--
tests/qemu-iotests/171.out | 68 ++--
tests/qemu-iotests/187.out | 6 +-
tests/qemu-iotests/188.out | 2 +-
tests/qemu-iotests/197.out | 2 +-
tests/qemu-iotests/205 | 4 +-
tests/qemu-iotests/214.out | 2 +-
tests/qemu-iotests/215.out | 2 +-
tests/qemu-iotests/220.out | 2 +-
tests/qemu-iotests/226.out | 16 +-
tests/qemu-iotests/244.out | 22 +-
tests/qemu-iotests/271.out | 14 +-
tests/qemu-iotests/289.out | 2 +-
tests/qemu-iotests/293.out | 30 +-
tests/qemu-iotests/294.out | 4 +-
tests/qemu-iotests/305.out | 2 +-
tests/qemu-iotests/307.out | 2 +-
tests/qemu-iotests/tests/file-io-error.out | 2 +-
tests/qemu-iotests/tests/image-fleecing.out | 12 +-
tests/qemu-iotests/tests/inactive-node-nbd.out | 10 +-
tests/qemu-iotests/tests/nbd-reconnect-on-open.out | 4 +-
tests/qemu-iotests/tests/parallels-bitmap.out | 4 +-
tests/qemu-iotests/tests/parallels-checks.out | 4 +-
util/error-report.c | 2 +-
53 files changed, 651 insertions(+), 647 deletions(-)
diff --git a/qemu-io.c b/qemu-io.c
index 598d5b1c9ca9..7d6a65a50814 100644
--- a/qemu-io.c
+++ b/qemu-io.c
@@ -628,6 +628,10 @@ int main(int argc, char **argv)
exit(1);
}
+ /* Compute the prompt before clearing prgname */
+ get_prompt();
+ g_set_prgname("");
+
qemu_init_main_loop(&error_fatal);
if (!trace_init_backends()) {
diff --git a/tests/qemu-iotests/004.out b/tests/qemu-iotests/004.out
index 37da6024809f..fb8593289f51 100644
--- a/tests/qemu-iotests/004.out
+++ b/tests/qemu-iotests/004.out
@@ -6,36 +6,36 @@ wrote 1048576/1048576 bytes at offset 133169152
1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
write into image boundary
-qemu-io: write failed: Input/output error
+write failed: Input/output error
write at image boundary
-qemu-io: write failed: Input/output error
+write failed: Input/output error
write past image boundary
-qemu-io: write failed: Input/output error
+write failed: Input/output error
pwrite past image boundary
-qemu-io: write failed: Input/output error
+write failed: Input/output error
writev past image boundary
-qemu-io: writev failed: Input/output error
+writev failed: Input/output error
read before image boundary
read 1048576/1048576 bytes at offset 133169152
1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
read into image boundary
-qemu-io: read failed: Input/output error
+read failed: Input/output error
read at image boundary
-qemu-io: read failed: Input/output error
+read failed: Input/output error
read past image boundary
-qemu-io: read failed: Input/output error
+read failed: Input/output error
pread past image boundary
-qemu-io: read failed: Input/output error
+read failed: Input/output error
readv past image boundary
-qemu-io: readv failed: Input/output error
+readv failed: Input/output error
*** done
diff --git a/tests/qemu-iotests/021.out b/tests/qemu-iotests/021.out
index dfdfeb503780..8533f8e58ae6 100644
--- a/tests/qemu-iotests/021.out
+++ b/tests/qemu-iotests/021.out
@@ -2,92 +2,92 @@ QA output created by 021
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
== testing writev -P -1 ==
-qemu-io: -1 is not a valid pattern byte
+-1 is not a valid pattern byte
== testing read -P -1 ==
-qemu-io: -1 is not a valid pattern byte
+-1 is not a valid pattern byte
== testing write -P -1 ==
-qemu-io: -1 is not a valid pattern byte
+-1 is not a valid pattern byte
== testing readv -P -1 ==
-qemu-io: -1 is not a valid pattern byte
+-1 is not a valid pattern byte
== testing aio_read -P -1 ==
-qemu-io: -1 is not a valid pattern byte
+-1 is not a valid pattern byte
== testing aio_write -P -1 ==
-qemu-io: -1 is not a valid pattern byte
+-1 is not a valid pattern byte
== testing writev -P 300 ==
-qemu-io: 300 is not a valid pattern byte
+300 is not a valid pattern byte
== testing read -P 300 ==
-qemu-io: 300 is not a valid pattern byte
+300 is not a valid pattern byte
== testing write -P 300 ==
-qemu-io: 300 is not a valid pattern byte
+300 is not a valid pattern byte
== testing readv -P 300 ==
-qemu-io: 300 is not a valid pattern byte
+300 is not a valid pattern byte
== testing aio_read -P 300 ==
-qemu-io: 300 is not a valid pattern byte
+300 is not a valid pattern byte
== testing aio_write -P 300 ==
-qemu-io: 300 is not a valid pattern byte
+300 is not a valid pattern byte
== testing writev -P 12m ==
-qemu-io: 12m is not a valid pattern byte
+12m is not a valid pattern byte
== testing read -P 12m ==
-qemu-io: 12m is not a valid pattern byte
+12m is not a valid pattern byte
== testing write -P 12m ==
-qemu-io: 12m is not a valid pattern byte
+12m is not a valid pattern byte
== testing readv -P 12m ==
-qemu-io: 12m is not a valid pattern byte
+12m is not a valid pattern byte
== testing aio_read -P 12m ==
-qemu-io: 12m is not a valid pattern byte
+12m is not a valid pattern byte
== testing aio_write -P 12m ==
-qemu-io: 12m is not a valid pattern byte
+12m is not a valid pattern byte
== testing writev -P 4k ==
-qemu-io: 4k is not a valid pattern byte
+4k is not a valid pattern byte
== testing read -P 4k ==
-qemu-io: 4k is not a valid pattern byte
+4k is not a valid pattern byte
== testing write -P 4k ==
-qemu-io: 4k is not a valid pattern byte
+4k is not a valid pattern byte
== testing readv -P 4k ==
-qemu-io: 4k is not a valid pattern byte
+4k is not a valid pattern byte
== testing aio_read -P 4k ==
-qemu-io: 4k is not a valid pattern byte
+4k is not a valid pattern byte
== testing aio_write -P 4k ==
-qemu-io: 4k is not a valid pattern byte
+4k is not a valid pattern byte
== testing writev -P route66 ==
-qemu-io: route66 is not a valid pattern byte
+route66 is not a valid pattern byte
== testing read -P route66 ==
-qemu-io: route66 is not a valid pattern byte
+route66 is not a valid pattern byte
== testing write -P route66 ==
-qemu-io: route66 is not a valid pattern byte
+route66 is not a valid pattern byte
== testing readv -P route66 ==
-qemu-io: route66 is not a valid pattern byte
+route66 is not a valid pattern byte
== testing aio_read -P route66 ==
-qemu-io: route66 is not a valid pattern byte
+route66 is not a valid pattern byte
== testing aio_write -P route66 ==
-qemu-io: route66 is not a valid pattern byte
+route66 is not a valid pattern byte
*** done
diff --git a/tests/qemu-iotests/026.out b/tests/qemu-iotests/026.out
index b998a9ac83da..050bbfa18863 100644
--- a/tests/qemu-iotests/026.out
+++ b/tests/qemu-iotests/026.out
@@ -4,442 +4,442 @@ Errors while writing 128 kB
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_update; errno: 5; imm: off; once: on; write
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_update; errno: 5; imm: off; once: on; write -b
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_update; errno: 5; imm: off; once: off; write
-qemu-io: write failed: Input/output error
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+write failed: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_update; errno: 5; imm: off; once: off; write -b
-qemu-io: write failed: Input/output error
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+write failed: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_update; errno: 28; imm: off; once: on; write
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_update; errno: 28; imm: off; once: on; write -b
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_update; errno: 28; imm: off; once: off; write
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_update; errno: 28; imm: off; once: off; write -b
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_load; errno: 5; imm: off; once: on; write
wrote 131072/131072 bytes at offset 0
128 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: write failed: Input/output error
-qemu-io: read failed: Input/output error
+write failed: Input/output error
+read failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_load; errno: 5; imm: off; once: on; write -b
wrote 131072/131072 bytes at offset 0
128 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: write failed: Input/output error
-qemu-io: read failed: Input/output error
+write failed: Input/output error
+read failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_load; errno: 5; imm: off; once: off; write
wrote 131072/131072 bytes at offset 0
128 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: write failed: Input/output error
-qemu-io: read failed: Input/output error
+write failed: Input/output error
+read failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_load; errno: 5; imm: off; once: off; write -b
wrote 131072/131072 bytes at offset 0
128 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: write failed: Input/output error
-qemu-io: read failed: Input/output error
+write failed: Input/output error
+read failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_load; errno: 28; imm: off; once: on; write
wrote 131072/131072 bytes at offset 0
128 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: write failed: No space left on device
-qemu-io: read failed: No space left on device
+write failed: No space left on device
+read failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_load; errno: 28; imm: off; once: on; write -b
wrote 131072/131072 bytes at offset 0
128 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: write failed: No space left on device
-qemu-io: read failed: No space left on device
+write failed: No space left on device
+read failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_load; errno: 28; imm: off; once: off; write
wrote 131072/131072 bytes at offset 0
128 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: write failed: No space left on device
-qemu-io: read failed: No space left on device
+write failed: No space left on device
+read failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_load; errno: 28; imm: off; once: off; write -b
wrote 131072/131072 bytes at offset 0
128 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: write failed: No space left on device
-qemu-io: read failed: No space left on device
+write failed: No space left on device
+read failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_update; errno: 5; imm: off; once: on; write
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_update; errno: 5; imm: off; once: on; write -b
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_update; errno: 5; imm: off; once: off; write
-qemu-io: write failed: Input/output error
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+write failed: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_update; errno: 5; imm: off; once: off; write -b
-qemu-io: write failed: Input/output error
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+write failed: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_update; errno: 28; imm: off; once: on; write
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_update; errno: 28; imm: off; once: on; write -b
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_update; errno: 28; imm: off; once: off; write
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_update; errno: 28; imm: off; once: off; write -b
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_alloc_write; errno: 5; imm: off; once: on; write
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_alloc_write; errno: 5; imm: off; once: on; write -b
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_alloc_write; errno: 5; imm: off; once: off; write
-qemu-io: write failed: Input/output error
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+write failed: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_alloc_write; errno: 5; imm: off; once: off; write -b
-qemu-io: write failed: Input/output error
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+write failed: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_alloc_write; errno: 28; imm: off; once: on; write
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_alloc_write; errno: 28; imm: off; once: on; write -b
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_alloc_write; errno: 28; imm: off; once: off; write
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_alloc_write; errno: 28; imm: off; once: off; write -b
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: write_aio; errno: 5; imm: off; once: on; write
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: write_aio; errno: 5; imm: off; once: on; write -b
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: write_aio; errno: 5; imm: off; once: off; write
-qemu-io: write failed: Input/output error
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+write failed: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: write_aio; errno: 5; imm: off; once: off; write -b
-qemu-io: write failed: Input/output error
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+write failed: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: write_aio; errno: 28; imm: off; once: on; write
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: write_aio; errno: 28; imm: off; once: on; write -b
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: write_aio; errno: 28; imm: off; once: off; write
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: write_aio; errno: 28; imm: off; once: off; write -b
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_load; errno: 5; imm: off; once: on; write
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_load; errno: 5; imm: off; once: on; write -b
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_load; errno: 5; imm: off; once: off; write
-qemu-io: write failed: Input/output error
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+write failed: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_load; errno: 5; imm: off; once: off; write -b
-qemu-io: write failed: Input/output error
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+write failed: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_load; errno: 28; imm: off; once: on; write
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_load; errno: 28; imm: off; once: on; write -b
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_load; errno: 28; imm: off; once: off; write
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_load; errno: 28; imm: off; once: off; write -b
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_update_part; errno: 5; imm: off; once: on; write
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_update_part; errno: 5; imm: off; once: on; write -b
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_update_part; errno: 5; imm: off; once: off; write
-qemu-io: write failed: Input/output error
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+write failed: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_update_part; errno: 5; imm: off; once: off; write -b
-qemu-io: write failed: Input/output error
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+write failed: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_update_part; errno: 28; imm: off; once: on; write
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_update_part; errno: 28; imm: off; once: on; write -b
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_update_part; errno: 28; imm: off; once: off; write
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_update_part; errno: 28; imm: off; once: off; write -b
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc; errno: 5; imm: off; once: on; write
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc; errno: 5; imm: off; once: on; write -b
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc; errno: 5; imm: off; once: off; write
-qemu-io: write failed: Input/output error
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+write failed: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc; errno: 5; imm: off; once: off; write -b
-qemu-io: write failed: Input/output error
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+write failed: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc; errno: 28; imm: off; once: on; write
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc; errno: 28; imm: off; once: on; write -b
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc; errno: 28; imm: off; once: off; write
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc; errno: 28; imm: off; once: off; write -b
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: cluster_alloc; errno: 5; imm: off; once: on; write
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: cluster_alloc; errno: 5; imm: off; once: on; write -b
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: cluster_alloc; errno: 5; imm: off; once: off; write
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: cluster_alloc; errno: 5; imm: off; once: off; write -b
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: cluster_alloc; errno: 28; imm: off; once: on; write
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: cluster_alloc; errno: 28; imm: off; once: on; write -b
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: cluster_alloc; errno: 28; imm: off; once: off; write
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: cluster_alloc; errno: 28; imm: off; once: off; write -b
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
=== Refcount table growth tests ===
@@ -447,122 +447,122 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_hookup; errno: 28; imm: off; once: on; write
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_hookup; errno: 28; imm: off; once: on; write -b
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_hookup; errno: 28; imm: off; once: off; write
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_hookup; errno: 28; imm: off; once: off; write -b
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_write; errno: 28; imm: off; once: on; write
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_write; errno: 28; imm: off; once: on; write -b
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_write; errno: 28; imm: off; once: off; write
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_write; errno: 28; imm: off; once: off; write -b
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_write_blocks; errno: 28; imm: off; once: on; write
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_write_blocks; errno: 28; imm: off; once: on; write -b
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_write_blocks; errno: 28; imm: off; once: off; write
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_write_blocks; errno: 28; imm: off; once: off; write -b
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_write_table; errno: 28; imm: off; once: on; write
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_write_table; errno: 28; imm: off; once: on; write -b
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_write_table; errno: 28; imm: off; once: off; write
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_write_table; errno: 28; imm: off; once: off; write -b
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_switch_table; errno: 28; imm: off; once: on; write
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_switch_table; errno: 28; imm: off; once: on; write -b
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_switch_table; errno: 28; imm: off; once: off; write
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_switch_table; errno: 28; imm: off; once: off; write -b
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
=== L1 growth tests ===
@@ -570,76 +570,76 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_grow_alloc_table; errno: 5; imm: off; once: on
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_grow_alloc_table; errno: 5; imm: off; once: off
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_grow_alloc_table; errno: 28; imm: off; once: on
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_grow_alloc_table; errno: 28; imm: off; once: off
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_grow_write_table; errno: 5; imm: off; once: on
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_grow_write_table; errno: 5; imm: off; once: off
-qemu-io: write failed: Input/output error
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+write failed: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_grow_write_table; errno: 28; imm: off; once: on
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_grow_write_table; errno: 28; imm: off; once: off
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_grow_activate_table; errno: 5; imm: off; once: on
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_grow_activate_table; errno: 5; imm: off; once: off
-qemu-io: write failed: Input/output error
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+write failed: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_grow_activate_table; errno: 28; imm: off; once: on
-qemu-io: write failed: No space left on device
+write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_grow_activate_table; errno: 28; imm: off; once: off
-qemu-io: write failed: No space left on device
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+write failed: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
No errors were found on the image.
=== Avoid cluster leaks after temporary failure ===
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
-qemu-io: write failed: Input/output error
+write failed: Input/output error
wrote 1048576/1048576 bytes at offset 0
1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
No errors were found on the image.
@@ -651,6 +651,6 @@ wrote 1024/1024 bytes at offset 0
1 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
wrote 1024/1024 bytes at offset 0
1 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
*** done
diff --git a/tests/qemu-iotests/026.out.nocache b/tests/qemu-iotests/026.out.nocache
index 9359d26d7e20..b46d00b35c85 100644
--- a/tests/qemu-iotests/026.out.nocache
+++ b/tests/qemu-iotests/026.out.nocache
@@ -14,15 +14,15 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_update; errno: 5; imm: off; once: off; write
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_update; errno: 5; imm: off; once: off; write -b
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
@@ -38,15 +38,15 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_update; errno: 28; imm: off; once: off; write
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_update; errno: 28; imm: off; once: off; write -b
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
@@ -128,16 +128,16 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_update; errno: 5; imm: off; once: off; write
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
wrote 131072/131072 bytes at offset 0
128 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_update; errno: 5; imm: off; once: off; write -b
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
wrote 131072/131072 bytes at offset 0
128 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
No errors were found on the image.
@@ -156,16 +156,16 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_update; errno: 28; imm: off; once: off; write
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
wrote 131072/131072 bytes at offset 0
128 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_update; errno: 28; imm: off; once: off; write -b
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
wrote 131072/131072 bytes at offset 0
128 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
No errors were found on the image.
@@ -182,15 +182,15 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_alloc_write; errno: 5; imm: off; once: off; write
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_alloc_write; errno: 5; imm: off; once: off; write -b
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
@@ -206,15 +206,15 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_alloc_write; errno: 28; imm: off; once: off; write
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l2_alloc_write; errno: 28; imm: off; once: off; write -b
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
@@ -230,15 +230,15 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: write_aio; errno: 5; imm: off; once: off; write
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: write_aio; errno: 5; imm: off; once: off; write -b
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
@@ -254,15 +254,15 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: write_aio; errno: 28; imm: off; once: off; write
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: write_aio; errno: 28; imm: off; once: off; write -b
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
@@ -278,15 +278,15 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_load; errno: 5; imm: off; once: off; write
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_load; errno: 5; imm: off; once: off; write -b
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
@@ -302,15 +302,15 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_load; errno: 28; imm: off; once: off; write
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_load; errno: 28; imm: off; once: off; write -b
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
@@ -326,15 +326,15 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_update_part; errno: 5; imm: off; once: off; write
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_update_part; errno: 5; imm: off; once: off; write -b
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
@@ -350,15 +350,15 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_update_part; errno: 28; imm: off; once: off; write
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_update_part; errno: 28; imm: off; once: off; write -b
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
@@ -374,15 +374,15 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc; errno: 5; imm: off; once: off; write
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc; errno: 5; imm: off; once: off; write -b
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
@@ -398,15 +398,15 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc; errno: 28; imm: off; once: off; write
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc; errno: 28; imm: off; once: off; write -b
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
@@ -465,15 +465,15 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_hookup; errno: 28; imm: off; once: off; write
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_hookup; errno: 28; imm: off; once: off; write -b
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
@@ -489,15 +489,15 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_write; errno: 28; imm: off; once: off; write
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_write; errno: 28; imm: off; once: off; write -b
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
@@ -513,15 +513,15 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_write_blocks; errno: 28; imm: off; once: off; write
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_write_blocks; errno: 28; imm: off; once: off; write -b
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
@@ -537,15 +537,15 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_write_table; errno: 28; imm: off; once: off; write
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_write_table; errno: 28; imm: off; once: off; write -b
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
@@ -561,15 +561,15 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_switch_table; errno: 28; imm: off; once: off; write
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: refblock_alloc_switch_table; errno: 28; imm: off; once: off; write -b
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
@@ -603,8 +603,8 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_grow_write_table; errno: 5; imm: off; once: off
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
@@ -615,8 +615,8 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_grow_write_table; errno: 28; imm: off; once: off
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
@@ -627,8 +627,8 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_grow_activate_table; errno: 5; imm: off; once: off
-qemu-io: Failed to flush the L2 table cache: Input/output error
-qemu-io: Failed to flush the refcount block cache: Input/output error
+Failed to flush the L2 table cache: Input/output error
+Failed to flush the refcount block cache: Input/output error
write failed: Input/output error
No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
@@ -639,8 +639,8 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1073741824
Event: l1_grow_activate_table; errno: 28; imm: off; once: off
-qemu-io: Failed to flush the L2 table cache: No space left on device
-qemu-io: Failed to flush the refcount block cache: No space left on device
+Failed to flush the L2 table cache: No space left on device
+Failed to flush the refcount block cache: No space left on device
write failed: No space left on device
No errors were found on the image.
diff --git a/tests/qemu-iotests/059.out b/tests/qemu-iotests/059.out
index 275ee7c7781a..be757ea2f211 100644
--- a/tests/qemu-iotests/059.out
+++ b/tests/qemu-iotests/059.out
@@ -2,15 +2,15 @@ QA output created by 059
=== Testing invalid granularity ===
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
-qemu-io: can't open device TEST_DIR/t.vmdk: Invalid granularity, image may be corrupt
+can't open device TEST_DIR/t.vmdk: Invalid granularity, image may be corrupt
=== Testing too big L2 table size ===
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
-qemu-io: can't open device TEST_DIR/t.vmdk: L2 table size too big
+can't open device TEST_DIR/t.vmdk: L2 table size too big
=== Testing too big L1 table size ===
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
-qemu-io: can't open device TEST_DIR/t.vmdk: L1 size too big
+can't open device TEST_DIR/t.vmdk: L1 size too big
=== Testing monolithicFlat creation and opening ===
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=2147483648
diff --git a/tests/qemu-iotests/060.out b/tests/qemu-iotests/060.out
index 27275fd6b70e..8870a478231c 100644
--- a/tests/qemu-iotests/060.out
+++ b/tests/qemu-iotests/060.out
@@ -9,7 +9,7 @@ ERROR cluster 3 refcount=1 reference=3
Data may be corrupted, or further writes to the image may corrupt it.
incompatible_features []
qcow2: Marking image as corrupt: Preventing invalid write on metadata (overlaps with active L1 table); further corruption events will be suppressed
-qemu-io: write failed: Input/output error
+write failed: Input/output error
incompatible_features [1]
image: TEST_DIR/t.IMGFMT
file format: IMGFMT
@@ -22,8 +22,8 @@ Format specific information:
refcount bits: 16
corrupt: true
extended l2: false
-qemu-io: can't open device TEST_DIR/t.IMGFMT: IMGFMT: Image is corrupt; cannot be opened read/write
-qemu-io: no file open, try 'help open'
+can't open device TEST_DIR/t.IMGFMT: IMGFMT: Image is corrupt; cannot be opened read/write
+no file open, try 'help open'
read 512/512 bytes at offset 0
512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
@@ -37,7 +37,7 @@ ERROR cluster 2 refcount=1 reference=2
Data may be corrupted, or further writes to the image may corrupt it.
incompatible_features []
qcow2: Marking image as corrupt: Preventing invalid write on metadata (overlaps with refcount block); further corruption events will be suppressed
-qemu-io: write failed: Input/output error
+write failed: Input/output error
incompatible_features [1]
ERROR refcount block 0 refcount=2
ERROR cluster 2 refcount=1 reference=2
@@ -73,7 +73,7 @@ Data may be corrupted, or further writes to the image may corrupt it.
This means waste of disk space, but no harm to data.
incompatible_features []
qcow2: Marking image as corrupt: Preventing invalid write on metadata (overlaps with inactive L2 table); further corruption events will be suppressed
-qemu-io: write failed: Input/output error
+write failed: Input/output error
incompatible_features [1]
ERROR cluster 4 refcount=1 reference=2
Leaked cluster 9 refcount=1 reference=0
@@ -108,8 +108,8 @@ wrote 65536/65536 bytes at offset 0
wrote 65536/65536 bytes at offset 536870912
64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
qcow2: Marking image as corrupt: Preventing invalid write on metadata (overlaps with active L2 table); further corruption events will be suppressed
-qemu-io: write failed: Input/output error
-qemu-io: aio_write failed: No medium found
+write failed: Input/output error
+aio_write failed: No medium found
blkdebug: Suspended request '0'
blkdebug: Resuming request '0'
@@ -119,7 +119,7 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
wrote 65536/65536 bytes at offset 0
64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
qcow2: Marking image as corrupt: Preventing invalid write on metadata (overlaps with qcow2_header); further corruption events will be suppressed
-qemu-io: write failed: Input/output error
+write failed: Input/output error
=== Testing unaligned L1 entry ===
@@ -127,7 +127,7 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
wrote 65536/65536 bytes at offset 0
64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
qcow2: Marking image as corrupt: L2 table offset 0x42a00 unaligned (L1 index: 0); further corruption events will be suppressed
-qemu-io: read failed: Input/output error
+read failed: Input/output error
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
wrote 65536/65536 bytes at offset 0
64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
@@ -140,7 +140,7 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
wrote 65536/65536 bytes at offset 0
64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
qcow2: Marking image as corrupt: Cluster allocation offset 0x52a00 unaligned (L2 offset: 0x40000, L2 index: 0); further corruption events will be suppressed
-qemu-io: read failed: Input/output error
+read failed: Input/output error
=== Testing unaligned pre-allocated zero cluster ===
@@ -154,7 +154,7 @@ qemu-img: Failed to turn zero into data clusters: Input/output error
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
qcow2: Marking image as corrupt: Refblock offset 0x22a00 unaligned (reftable index: 0); further corruption events will be suppressed
-qemu-io: write failed: Input/output error
+write failed: Input/output error
=== Testing non-fatal corruption on freeing ===
@@ -171,8 +171,8 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
wrote 65536/65536 bytes at offset 0
64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
qcow2: Image is corrupt: Cluster allocation offset 0x52a00 unaligned (L2 offset: 0x40000, L2 index: 0); further non-fatal corruption events will be suppressed
-qemu-io: read failed: Input/output error
-qemu-io: read failed: Input/output error
+read failed: Input/output error
+read failed: Input/output error
=== Testing non-fatal and then fatal corruption report ===
@@ -181,7 +181,7 @@ wrote 131072/131072 bytes at offset 0
128 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
qcow2: Image is corrupt: Cannot free unaligned cluster 0x52a00; further non-fatal corruption events will be suppressed
qcow2: Marking image as corrupt: Cluster allocation offset 0x62a00 unaligned (L2 offset: 0x40000, L2 index: 0x1); further corruption events will be suppressed
-qemu-io: read failed: Input/output error
+read failed: Input/output error
discard 65536/65536 bytes at offset 0
64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
@@ -189,7 +189,7 @@ discard 65536/65536 bytes at offset 0
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
qcow2: Marking image as corrupt: Preventing invalid write on metadata (overlaps with refcount table); further corruption events will be suppressed
-qemu-io: write failed: Input/output error
+write failed: Input/output error
ERROR cluster 0 refcount=0 reference=1
ERROR cluster 1 refcount=0 reference=1
ERROR cluster 3 refcount=0 reference=1
@@ -209,7 +209,7 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
wrote 65536/65536 bytes at offset 0
64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
qcow2: Marking image as corrupt: Preventing invalid allocation of refcount block at offset 0; further corruption events will be suppressed
-qemu-io: write failed: Input/output error
+write failed: Input/output error
ERROR cluster 0 refcount=0 reference=1
ERROR cluster 1 refcount=0 reference=1
ERROR cluster 3 refcount=0 reference=1
@@ -229,7 +229,7 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
qcow2: Marking image as corrupt: Preventing invalid allocation of L2 table at offset 0; further corruption events will be suppressed
-qemu-io: write failed: Input/output error
+write failed: Input/output error
ERROR cluster 0 refcount=0 reference=1
ERROR cluster 1 refcount=0 reference=1
ERROR cluster 2 refcount=0 reference=1
@@ -251,7 +251,7 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
wrote 65536/65536 bytes at offset 65536
64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
qcow2: Marking image as corrupt: Preventing invalid allocation of compressed cluster at offset 0; further corruption events will be suppressed
-qemu-io: write failed: Input/output error
+write failed: Input/output error
ERROR cluster 0 refcount=0 reference=1
ERROR cluster 1 refcount=0 reference=1
ERROR cluster 2 refcount=0 reference=1
@@ -270,7 +270,7 @@ No errors were found on the image.
=== Testing zero refcount table size ===
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
-qemu-io: can't open device TEST_DIR/t.IMGFMT: Image does not contain a reference count table
+can't open device TEST_DIR/t.IMGFMT: Image does not contain a reference count table
ERROR cluster 0 refcount=0 reference=1
ERROR cluster 3 refcount=0 reference=1
Rebuilding refcount structure
@@ -286,7 +286,7 @@ No errors were found on the image.
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
qcow2: Marking image as corrupt: Preventing invalid allocation of L2 table at offset 0; further corruption events will be suppressed
-qemu-io: write failed: Input/output error
+write failed: Input/output error
=== Testing dirty corrupt image ===
@@ -299,7 +299,7 @@ Can't get refcount for cluster 2: Input/output error
Can't get refcount for cluster 3: Input/output error
Rebuilding refcount structure
Repairing cluster 1 refcount=1 reference=0
-qemu-io: can't open device TEST_DIR/t.IMGFMT: Could not repair dirty image: Input/output error
+can't open device TEST_DIR/t.IMGFMT: Could not repair dirty image: Input/output error
--- Repairing ---
Leaked cluster 1 refcount=1 reference=0
Repairing cluster 1 refcount=1 reference=0
@@ -319,7 +319,7 @@ wrote 65536/65536 bytes at offset 0
discard 65536/65536 bytes at offset 0
64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
qcow2: Marking image as corrupt: Preallocated zero cluster offset 0x2a00 unaligned (guest offset: 0); further corruption events will be suppressed
-qemu-io: write failed: Input/output error
+write failed: Input/output error
--- Repairing ---
Repairing offset=2a00: Preallocated cluster is not properly aligned; L2 entry corrupted.
The following inconsistencies were found and repaired:
@@ -337,7 +337,7 @@ wrote 131072/131072 bytes at offset 0
128 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
qcow2: Marking image as corrupt: Refblock offset 0x2a00 unaligned (reftable index: 0); further corruption events will be suppressed
qcow2_free_clusters failed: Input/output error
-qemu-io: discard failed: No medium found
+discard failed: No medium found
--- Repairing ---
ERROR refcount block 0 is not cluster aligned; refcount table entry corrupted
qcow2: Marking image as corrupt: Refblock offset 0x2a00 unaligned (reftable index: 0); further corruption events will be suppressed
diff --git a/tests/qemu-iotests/061.out b/tests/qemu-iotests/061.out
index 951c6bf3e62c..7e34a6fd9c28 100644
--- a/tests/qemu-iotests/061.out
+++ b/tests/qemu-iotests/061.out
@@ -545,7 +545,7 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
qemu-img: data-file can only be set for images that use an external data file
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864 data_file=TEST_DIR/t.IMGFMT.data
-qemu-io: can't open device TEST_DIR/t.IMGFMT: Could not open 'foo': No such file or directory
+can't open device TEST_DIR/t.IMGFMT: Could not open 'foo': No such file or directory
read 4096/4096 bytes at offset 0
4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
image: TEST_DIR/t.IMGFMT
@@ -562,7 +562,7 @@ Format specific information:
corrupt: false
extended l2: false
-qemu-io: can't open device TEST_DIR/t.IMGFMT: 'data-file' is required for this image
+can't open device TEST_DIR/t.IMGFMT: 'data-file' is required for this image
read 4096/4096 bytes at offset 0
4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
image: TEST_DIR/t.IMGFMT
diff --git a/tests/qemu-iotests/069.out b/tests/qemu-iotests/069.out
index 126b4d2d519b..0409b4700e0f 100644
--- a/tests/qemu-iotests/069.out
+++ b/tests/qemu-iotests/069.out
@@ -4,5 +4,5 @@ QA output created by 069
Formatting 'TEST_DIR/t.IMGFMT.base', fmt=IMGFMT size=131072
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=131072 backing_file=TEST_DIR/t.IMGFMT.base backing_fmt=IMGFMT
-qemu-io: can't open device TEST_DIR/t.IMGFMT: Could not open backing file: Could not open 'TEST_DIR/t.IMGFMT.base': No such file or directory
+can't open device TEST_DIR/t.IMGFMT: Could not open backing file: Could not open 'TEST_DIR/t.IMGFMT.base': No such file or directory
*** done
diff --git a/tests/qemu-iotests/070.out b/tests/qemu-iotests/070.out
index 2fbfd7eaf334..287f16de2a6f 100644
--- a/tests/qemu-iotests/070.out
+++ b/tests/qemu-iotests/070.out
@@ -1,7 +1,7 @@
QA output created by 070
=== Verify open image read-only fails, due to dirty log ===
-qemu-io: can't open device TEST_DIR/iotest-dirtylog-10G-4M.vhdx: VHDX image file 'TEST_DIR/iotest-dirtylog-10G-4M.vhdx' opened read-only, but contains a log that needs to be replayed
+can't open device TEST_DIR/iotest-dirtylog-10G-4M.vhdx: VHDX image file 'TEST_DIR/iotest-dirtylog-10G-4M.vhdx' opened read-only, but contains a log that needs to be replayed
To replay the log, run:
qemu-img check -r all 'TEST_DIR/iotest-dirtylog-10G-4M.vhdx'
=== Verify open image replays log ===
diff --git a/tests/qemu-iotests/071.out b/tests/qemu-iotests/071.out
index f2d015d8ccae..15353aba08b9 100644
--- a/tests/qemu-iotests/071.out
+++ b/tests/qemu-iotests/071.out
@@ -30,11 +30,11 @@ blkverify: read offset=0 bytes=512 contents mismatch at offset 0
=== Testing blkdebug through filename ===
-qemu-io: read failed: Input/output error
+read failed: Input/output error
=== Testing blkdebug through file blockref ===
-qemu-io: read failed: Input/output error
+read failed: Input/output error
=== Testing blkdebug on existing block device ===
diff --git a/tests/qemu-iotests/072.out b/tests/qemu-iotests/072.out
index d7ce24da1f7a..fe949d47817a 100644
--- a/tests/qemu-iotests/072.out
+++ b/tests/qemu-iotests/072.out
@@ -15,7 +15,7 @@ read 512/512 bytes at offset 512
512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
read 512/512 bytes at offset 1024
512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: Pattern verification failed at offset 0, 512 bytes
+Pattern verification failed at offset 0, 512 bytes
read 512/512 bytes at offset 0
512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
*** done
diff --git a/tests/qemu-iotests/075.out b/tests/qemu-iotests/075.out
index 4f3871d33717..b234b758e026 100644
--- a/tests/qemu-iotests/075.out
+++ b/tests/qemu-iotests/075.out
@@ -9,23 +9,23 @@ read 512/512 bytes at offset 1048064
512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
== block_size must be a multiple of 512 ==
-qemu-io: can't open device TEST_DIR/simple-pattern.cloop: block_size 513 must be a multiple of 512
+can't open device TEST_DIR/simple-pattern.cloop: block_size 513 must be a multiple of 512
== block_size cannot be zero ==
-qemu-io: can't open device TEST_DIR/simple-pattern.cloop: block_size cannot be zero
+can't open device TEST_DIR/simple-pattern.cloop: block_size cannot be zero
== huge block_size ===
-qemu-io: can't open device TEST_DIR/simple-pattern.cloop: block_size 4294966784 must be 64 MB or less
+can't open device TEST_DIR/simple-pattern.cloop: block_size 4294966784 must be 64 MB or less
== offsets_size overflow ===
-qemu-io: can't open device TEST_DIR/simple-pattern.cloop: n_blocks 4294967295 must be 536870911 or less
+can't open device TEST_DIR/simple-pattern.cloop: n_blocks 4294967295 must be 536870911 or less
== refuse images that require too many offsets ===
-qemu-io: can't open device TEST_DIR/simple-pattern.cloop: image requires too many offsets, try increasing block size
+can't open device TEST_DIR/simple-pattern.cloop: image requires too many offsets, try increasing block size
== refuse images with non-monotonically increasing offsets ==
-qemu-io: can't open device TEST_DIR/simple-pattern.cloop: offsets not monotonically increasing at index 1, image file is corrupt
+can't open device TEST_DIR/simple-pattern.cloop: offsets not monotonically increasing at index 1, image file is corrupt
== refuse images with invalid compressed block size ==
-qemu-io: can't open device TEST_DIR/simple-pattern.cloop: invalid compressed block size at index 1, image file is corrupt
+can't open device TEST_DIR/simple-pattern.cloop: invalid compressed block size at index 1, image file is corrupt
*** done
diff --git a/tests/qemu-iotests/076.out b/tests/qemu-iotests/076.out
index 2de8a710a55d..9c66c5fb46b7 100644
--- a/tests/qemu-iotests/076.out
+++ b/tests/qemu-iotests/076.out
@@ -5,13 +5,13 @@ read 65536/65536 bytes at offset 0
64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
== Negative catalog size ==
-qemu-io: can't open device TEST_DIR/parallels-v1: Catalog too large
+can't open device TEST_DIR/parallels-v1: Catalog too large
== Overflow in catalog allocation ==
-qemu-io: can't open device TEST_DIR/parallels-v1: Catalog too large
+can't open device TEST_DIR/parallels-v1: Catalog too large
== Zero sectors per track ==
-qemu-io: can't open device TEST_DIR/parallels-v1: Invalid image: Zero sectors per track
+can't open device TEST_DIR/parallels-v1: Invalid image: Zero sectors per track
== Read from a valid v2 image ==
read 65536/65536 bytes at offset 0
diff --git a/tests/qemu-iotests/078.out b/tests/qemu-iotests/078.out
index 4a82e1779fe3..c3d6aa4fe465 100644
--- a/tests/qemu-iotests/078.out
+++ b/tests/qemu-iotests/078.out
@@ -5,18 +5,18 @@ read 512/512 bytes at offset 0
512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
== Negative catalog size ==
-qemu-io: can't open device TEST_DIR/empty.bochs: Catalog size is too large
+can't open device TEST_DIR/empty.bochs: Catalog size is too large
== Overflow for catalog size * sizeof(uint32_t) ==
-qemu-io: can't open device TEST_DIR/empty.bochs: Catalog size is too large
+can't open device TEST_DIR/empty.bochs: Catalog size is too large
== Too small catalog bitmap for image size ==
-qemu-io: can't open device TEST_DIR/empty.bochs: Catalog size is too small for this disk size
-qemu-io: can't open device TEST_DIR/empty.bochs: Catalog size is too small for this disk size
+can't open device TEST_DIR/empty.bochs: Catalog size is too small for this disk size
+can't open device TEST_DIR/empty.bochs: Catalog size is too small for this disk size
== Negative extent size ==
-qemu-io: can't open device TEST_DIR/empty.bochs: Extent size 2147483648 is too large
+can't open device TEST_DIR/empty.bochs: Extent size 2147483648 is too large
== Zero extent size ==
-qemu-io: can't open device TEST_DIR/empty.bochs: Extent size must be at least 512
+can't open device TEST_DIR/empty.bochs: Extent size must be at least 512
*** done
diff --git a/tests/qemu-iotests/080.out b/tests/qemu-iotests/080.out
index b20c21faf6a9..bf0ede4e206f 100644
--- a/tests/qemu-iotests/080.out
+++ b/tests/qemu-iotests/080.out
@@ -2,34 +2,34 @@ QA output created by 080
== Huge header size ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
-qemu-io: can't open device TEST_DIR/t.qcow2: qcow2 header exceeds cluster size
-qemu-io: can't open device TEST_DIR/t.qcow2: qcow2 header exceeds cluster size
+can't open device TEST_DIR/t.qcow2: qcow2 header exceeds cluster size
+can't open device TEST_DIR/t.qcow2: qcow2 header exceeds cluster size
== Huge unknown header extension ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
-qemu-io: can't open device TEST_DIR/t.qcow2: Invalid backing file offset
-qemu-io: can't open device TEST_DIR/t.qcow2: Header extension too large
-qemu-io: can't open device TEST_DIR/t.qcow2: Header extension too large
+can't open device TEST_DIR/t.qcow2: Invalid backing file offset
+can't open device TEST_DIR/t.qcow2: Header extension too large
+can't open device TEST_DIR/t.qcow2: Header extension too large
== Huge refcount table size ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
-qemu-io: can't open device TEST_DIR/t.qcow2: Reference count table too large
-qemu-io: can't open device TEST_DIR/t.qcow2: Reference count table too large
+can't open device TEST_DIR/t.qcow2: Reference count table too large
+can't open device TEST_DIR/t.qcow2: Reference count table too large
== Misaligned refcount table ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
-qemu-io: can't open device TEST_DIR/t.qcow2: Reference count table offset invalid
+can't open device TEST_DIR/t.qcow2: Reference count table offset invalid
== Huge refcount offset ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
-qemu-io: can't open device TEST_DIR/t.qcow2: Reference count table offset invalid
+can't open device TEST_DIR/t.qcow2: Reference count table offset invalid
== Invalid snapshot table ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
-qemu-io: can't open device TEST_DIR/t.qcow2: Snapshot table too large
-qemu-io: can't open device TEST_DIR/t.qcow2: Snapshot table too large
-qemu-io: can't open device TEST_DIR/t.qcow2: Snapshot table offset invalid
-qemu-io: can't open device TEST_DIR/t.qcow2: Snapshot table offset invalid
+can't open device TEST_DIR/t.qcow2: Snapshot table too large
+can't open device TEST_DIR/t.qcow2: Snapshot table too large
+can't open device TEST_DIR/t.qcow2: Snapshot table offset invalid
+can't open device TEST_DIR/t.qcow2: Snapshot table offset invalid
== Hitting snapshot table size limit ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
@@ -39,10 +39,10 @@ read 512/512 bytes at offset 0
== Invalid L1 table ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
-qemu-io: can't open device TEST_DIR/t.qcow2: Active L1 table too large
-qemu-io: can't open device TEST_DIR/t.qcow2: Active L1 table too large
-qemu-io: can't open device TEST_DIR/t.qcow2: Active L1 table offset invalid
-qemu-io: can't open device TEST_DIR/t.qcow2: Active L1 table offset invalid
+can't open device TEST_DIR/t.qcow2: Active L1 table too large
+can't open device TEST_DIR/t.qcow2: Active L1 table too large
+can't open device TEST_DIR/t.qcow2: Active L1 table offset invalid
+can't open device TEST_DIR/t.qcow2: Active L1 table offset invalid
== Invalid L1 table (with internal snapshot in the image) ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
@@ -50,7 +50,7 @@ qemu-img: Could not open 'TEST_DIR/t.IMGFMT': L1 table is too small
== Invalid backing file size ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
-qemu-io: can't open device TEST_DIR/t.qcow2: Backing file name too long
+can't open device TEST_DIR/t.qcow2: Backing file name too long
== Invalid L2 entry (huge physical offset) ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
@@ -66,8 +66,8 @@ wrote 512/512 bytes at offset 0
qemu-img: Failed to load snapshot: Snapshot L1 table offset invalid
qemu-img: Snapshot L1 table offset invalid
qemu-img: Failed to turn zero into data clusters: Invalid argument
-qemu-io: write failed: Invalid argument
-qemu-io: Failed to flush the refcount block cache: Invalid argument
+write failed: Invalid argument
+Failed to flush the refcount block cache: Invalid argument
qemu-img: Snapshot L1 table offset invalid
qemu-img: Could not apply snapshot 'test': Failed to load snapshot: Invalid argument
qemu-img: Could not delete snapshot 'test': Snapshot L1 table offset invalid
@@ -89,8 +89,8 @@ wrote 512/512 bytes at offset 0
qemu-img: Failed to load snapshot: Snapshot L1 table too large
qemu-img: Snapshot L1 table too large
qemu-img: Failed to turn zero into data clusters: File too large
-qemu-io: write failed: File too large
-qemu-io: Failed to flush the refcount block cache: File too large
+write failed: File too large
+Failed to flush the refcount block cache: File too large
qemu-img: Snapshot L1 table too large
qemu-img: Could not apply snapshot 'test': Failed to load snapshot: File too large
qemu-img: Could not delete snapshot 'test': Snapshot L1 table too large
diff --git a/tests/qemu-iotests/081.out b/tests/qemu-iotests/081.out
index bc902bd81832..084b6fbff66a 100644
--- a/tests/qemu-iotests/081.out
+++ b/tests/qemu-iotests/081.out
@@ -81,7 +81,7 @@ wrote 10485760/10485760 bytes at offset 0
10 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
== checking that quorum is broken ==
-qemu-io: read failed: Input/output error
+read failed: Input/output error
== checking the blkverify mode with broken content ==
quorum: offset=0 bytes=10485760 contents mismatch at offset 0
@@ -97,7 +97,7 @@ read 10485760/10485760 bytes at offset 0
10 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
== checking the blkverify mode with invalid settings ==
-qemu-io: can't open: blkverify=on can only be set if there are exactly two files and vote-threshold is 2
+can't open: blkverify=on can only be set if there are exactly two files and vote-threshold is 2
== dynamically adding a child to a quorum ==
Testing:
diff --git a/tests/qemu-iotests/083.out b/tests/qemu-iotests/083.out
index a1c446d5365e..70696dae1180 100644
--- a/tests/qemu-iotests/083.out
+++ b/tests/qemu-iotests/083.out
@@ -1,83 +1,83 @@
QA output created by 083
=== Check disconnect before neg1 ===
-qemu-io: can't open device nbd+tcp://127.0.0.1:PORT/foo
+can't open device nbd+tcp://127.0.0.1:PORT/foo
=== Check disconnect after neg1 ===
-qemu-io: can't open device nbd+tcp://127.0.0.1:PORT/foo
+can't open device nbd+tcp://127.0.0.1:PORT/foo
=== Check disconnect 8 neg1 ===
-qemu-io: can't open device nbd+tcp://127.0.0.1:PORT/foo
+can't open device nbd+tcp://127.0.0.1:PORT/foo
=== Check disconnect 16 neg1 ===
-qemu-io: can't open device nbd+tcp://127.0.0.1:PORT/foo
+can't open device nbd+tcp://127.0.0.1:PORT/foo
=== Check disconnect before export ===
-qemu-io: can't open device nbd+tcp://127.0.0.1:PORT/foo
+can't open device nbd+tcp://127.0.0.1:PORT/foo
=== Check disconnect after export ===
-qemu-io: can't open device nbd+tcp://127.0.0.1:PORT/foo
+can't open device nbd+tcp://127.0.0.1:PORT/foo
=== Check disconnect 4 export ===
-qemu-io: can't open device nbd+tcp://127.0.0.1:PORT/foo
+can't open device nbd+tcp://127.0.0.1:PORT/foo
=== Check disconnect 12 export ===
-qemu-io: can't open device nbd+tcp://127.0.0.1:PORT/foo
+can't open device nbd+tcp://127.0.0.1:PORT/foo
=== Check disconnect 16 export ===
-qemu-io: can't open device nbd+tcp://127.0.0.1:PORT/foo
+can't open device nbd+tcp://127.0.0.1:PORT/foo
=== Check disconnect before neg2 ===
-qemu-io: can't open device nbd+tcp://127.0.0.1:PORT/foo
+can't open device nbd+tcp://127.0.0.1:PORT/foo
=== Check disconnect after neg2 ===
-qemu-io: read failed: Input/output error
+read failed: Input/output error
=== Check disconnect 8 neg2 ===
-qemu-io: can't open device nbd+tcp://127.0.0.1:PORT/foo
+can't open device nbd+tcp://127.0.0.1:PORT/foo
=== Check disconnect 10 neg2 ===
-qemu-io: can't open device nbd+tcp://127.0.0.1:PORT/foo
+can't open device nbd+tcp://127.0.0.1:PORT/foo
=== Check disconnect before request ===
-qemu-io: read failed: Input/output error
+read failed: Input/output error
=== Check disconnect after request ===
-qemu-io: read failed: Input/output error
+read failed: Input/output error
=== Check disconnect before reply ===
-qemu-io: read failed: Input/output error
+read failed: Input/output error
=== Check disconnect after reply ===
-qemu-io: read failed: Input/output error
+read failed: Input/output error
=== Check disconnect 4 reply ===
-qemu-io: read failed: Input/output error
+read failed: Input/output error
=== Check disconnect 8 reply ===
-qemu-io: read failed: Input/output error
+read failed: Input/output error
=== Check disconnect before data ===
-qemu-io: read failed: Input/output error
+read failed: Input/output error
=== Check disconnect after data ===
@@ -86,107 +86,107 @@ read 512/512 bytes at offset 0
=== Check disconnect before neg-classic ===
-qemu-io: can't open device nbd+tcp://127.0.0.1:PORT/
+can't open device nbd+tcp://127.0.0.1:PORT/
=== Check disconnect 8 neg-classic ===
-qemu-io: can't open device nbd+tcp://127.0.0.1:PORT/
+can't open device nbd+tcp://127.0.0.1:PORT/
=== Check disconnect 16 neg-classic ===
-qemu-io: can't open device nbd+tcp://127.0.0.1:PORT/
+can't open device nbd+tcp://127.0.0.1:PORT/
=== Check disconnect 24 neg-classic ===
-qemu-io: can't open device nbd+tcp://127.0.0.1:PORT/
+can't open device nbd+tcp://127.0.0.1:PORT/
=== Check disconnect 28 neg-classic ===
-qemu-io: can't open device nbd+tcp://127.0.0.1:PORT/
+can't open device nbd+tcp://127.0.0.1:PORT/
=== Check disconnect after neg-classic ===
-qemu-io: read failed: Input/output error
+read failed: Input/output error
=== Check disconnect before neg1 ===
-qemu-io: can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
+can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
=== Check disconnect after neg1 ===
-qemu-io: can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
+can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
=== Check disconnect 8 neg1 ===
-qemu-io: can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
+can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
=== Check disconnect 16 neg1 ===
-qemu-io: can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
+can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
=== Check disconnect before export ===
-qemu-io: can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
+can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
=== Check disconnect after export ===
-qemu-io: can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
+can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
=== Check disconnect 4 export ===
-qemu-io: can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
+can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
=== Check disconnect 12 export ===
-qemu-io: can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
+can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
=== Check disconnect 16 export ===
-qemu-io: can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
+can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
=== Check disconnect before neg2 ===
-qemu-io: can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
+can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
=== Check disconnect after neg2 ===
-qemu-io: read failed: Input/output error
+read failed: Input/output error
=== Check disconnect 8 neg2 ===
-qemu-io: can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
+can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
=== Check disconnect 10 neg2 ===
-qemu-io: can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
+can't open device nbd+unix:///foo?socket=SOCK_DIR/nbd.sock
=== Check disconnect before request ===
-qemu-io: read failed: Input/output error
+read failed: Input/output error
=== Check disconnect after request ===
-qemu-io: read failed: Input/output error
+read failed: Input/output error
=== Check disconnect before reply ===
-qemu-io: read failed: Input/output error
+read failed: Input/output error
=== Check disconnect after reply ===
-qemu-io: read failed: Input/output error
+read failed: Input/output error
=== Check disconnect 4 reply ===
-qemu-io: read failed: Input/output error
+read failed: Input/output error
=== Check disconnect 8 reply ===
-qemu-io: read failed: Input/output error
+read failed: Input/output error
=== Check disconnect before data ===
-qemu-io: read failed: Input/output error
+read failed: Input/output error
=== Check disconnect after data ===
@@ -195,26 +195,26 @@ read 512/512 bytes at offset 0
=== Check disconnect before neg-classic ===
-qemu-io: can't open device nbd+unix:///?socket=SOCK_DIR/nbd.sock
+can't open device nbd+unix:///?socket=SOCK_DIR/nbd.sock
=== Check disconnect 8 neg-classic ===
-qemu-io: can't open device nbd+unix:///?socket=SOCK_DIR/nbd.sock
+can't open device nbd+unix:///?socket=SOCK_DIR/nbd.sock
=== Check disconnect 16 neg-classic ===
-qemu-io: can't open device nbd+unix:///?socket=SOCK_DIR/nbd.sock
+can't open device nbd+unix:///?socket=SOCK_DIR/nbd.sock
=== Check disconnect 24 neg-classic ===
-qemu-io: can't open device nbd+unix:///?socket=SOCK_DIR/nbd.sock
+can't open device nbd+unix:///?socket=SOCK_DIR/nbd.sock
=== Check disconnect 28 neg-classic ===
-qemu-io: can't open device nbd+unix:///?socket=SOCK_DIR/nbd.sock
+can't open device nbd+unix:///?socket=SOCK_DIR/nbd.sock
=== Check disconnect after neg-classic ===
-qemu-io: read failed: Input/output error
+read failed: Input/output error
*** done
diff --git a/tests/qemu-iotests/088.out b/tests/qemu-iotests/088.out
index 814be7181dc5..1f6bcf0abc97 100644
--- a/tests/qemu-iotests/088.out
+++ b/tests/qemu-iotests/088.out
@@ -2,10 +2,10 @@ QA output created by 088
== Invalid block size ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
-qemu-io: can't open device TEST_DIR/t.vpc: Invalid block size 0
-qemu-io: can't open device TEST_DIR/t.vpc: Invalid block size 0
-qemu-io: can't open device TEST_DIR/t.vpc: Invalid block size 128
-qemu-io: can't open device TEST_DIR/t.vpc: Invalid block size 128
-qemu-io: can't open device TEST_DIR/t.vpc: Invalid block size 305419896
-qemu-io: can't open device TEST_DIR/t.vpc: Invalid block size 305419896
+can't open device TEST_DIR/t.vpc: Invalid block size 0
+can't open device TEST_DIR/t.vpc: Invalid block size 0
+can't open device TEST_DIR/t.vpc: Invalid block size 128
+can't open device TEST_DIR/t.vpc: Invalid block size 128
+can't open device TEST_DIR/t.vpc: Invalid block size 305419896
+can't open device TEST_DIR/t.vpc: Invalid block size 305419896
*** done
diff --git a/tests/qemu-iotests/089.out b/tests/qemu-iotests/089.out
index a29e19b12d7e..c53fc4823a16 100644
--- a/tests/qemu-iotests/089.out
+++ b/tests/qemu-iotests/089.out
@@ -16,7 +16,7 @@ read 512/512 bytes at offset 512
512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
read 512/512 bytes at offset 1024
512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: Pattern verification failed at offset 0, 512 bytes
+Pattern verification failed at offset 0, 512 bytes
read 512/512 bytes at offset 0
512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
@@ -33,7 +33,7 @@ read 512/512 bytes at offset 0
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
wrote 512/512 bytes at offset 229376
512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: read failed: Input/output error
+read failed: Input/output error
=== Testing qemu-img info output ===
diff --git a/tests/qemu-iotests/092.out b/tests/qemu-iotests/092.out
index 3e799148735f..6eda321fc6bc 100644
--- a/tests/qemu-iotests/092.out
+++ b/tests/qemu-iotests/092.out
@@ -2,25 +2,25 @@ QA output created by 092
== Invalid cluster size ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
-qemu-io: can't open device TEST_DIR/t.qcow: Cluster size must be between 512 and 64k
-qemu-io: can't open device TEST_DIR/t.qcow: Cluster size must be between 512 and 64k
-qemu-io: can't open device TEST_DIR/t.qcow: Cluster size must be between 512 and 64k
-qemu-io: can't open device TEST_DIR/t.qcow: Cluster size must be between 512 and 64k
+can't open device TEST_DIR/t.qcow: Cluster size must be between 512 and 64k
+can't open device TEST_DIR/t.qcow: Cluster size must be between 512 and 64k
+can't open device TEST_DIR/t.qcow: Cluster size must be between 512 and 64k
+can't open device TEST_DIR/t.qcow: Cluster size must be between 512 and 64k
== Invalid L2 table size ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
-qemu-io: can't open device TEST_DIR/t.qcow: L2 table size must be between 512 and 64k
-qemu-io: can't open device TEST_DIR/t.qcow: L2 table size must be between 512 and 64k
-qemu-io: can't open device TEST_DIR/t.qcow: L2 table size must be between 512 and 64k
-qemu-io: can't open device TEST_DIR/t.qcow: L2 table size must be between 512 and 64k
+can't open device TEST_DIR/t.qcow: L2 table size must be between 512 and 64k
+can't open device TEST_DIR/t.qcow: L2 table size must be between 512 and 64k
+can't open device TEST_DIR/t.qcow: L2 table size must be between 512 and 64k
+can't open device TEST_DIR/t.qcow: L2 table size must be between 512 and 64k
== Invalid size ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
-qemu-io: can't open device TEST_DIR/t.qcow: Image too large
-qemu-io: can't open device TEST_DIR/t.qcow: Image too large
+can't open device TEST_DIR/t.qcow: Image too large
+can't open device TEST_DIR/t.qcow: Image too large
== Invalid backing file length ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
-qemu-io: can't open device TEST_DIR/t.qcow: Backing file name too long
-qemu-io: can't open device TEST_DIR/t.qcow: Backing file name too long
+can't open device TEST_DIR/t.qcow: Backing file name too long
+can't open device TEST_DIR/t.qcow: Backing file name too long
*** done
diff --git a/tests/qemu-iotests/103.out b/tests/qemu-iotests/103.out
index 16704cf499a0..bd9eec325028 100644
--- a/tests/qemu-iotests/103.out
+++ b/tests/qemu-iotests/103.out
@@ -5,13 +5,13 @@ wrote 65536/65536 bytes at offset 0
=== Testing invalid option combinations ===
-qemu-io: can't open device TEST_DIR/t.IMGFMT: cache-size, l2-cache-size and refcount-cache-size may not be set at the same time
-qemu-io: can't open device TEST_DIR/t.IMGFMT: l2-cache-size may not exceed cache-size
-qemu-io: can't open device TEST_DIR/t.IMGFMT: refcount-cache-size may not exceed cache-size
-qemu-io: can't open device TEST_DIR/t.IMGFMT: cache-size, l2-cache-size and refcount-cache-size may not be set at the same time
-qemu-io: can't open device TEST_DIR/t.IMGFMT: L2 cache entry size must be a power of two between 512 and the cluster size (65536)
-qemu-io: can't open device TEST_DIR/t.IMGFMT: L2 cache entry size must be a power of two between 512 and the cluster size (65536)
-qemu-io: can't open device TEST_DIR/t.IMGFMT: L2 cache entry size must be a power of two between 512 and the cluster size (65536)
+can't open device TEST_DIR/t.IMGFMT: cache-size, l2-cache-size and refcount-cache-size may not be set at the same time
+can't open device TEST_DIR/t.IMGFMT: l2-cache-size may not exceed cache-size
+can't open device TEST_DIR/t.IMGFMT: refcount-cache-size may not exceed cache-size
+can't open device TEST_DIR/t.IMGFMT: cache-size, l2-cache-size and refcount-cache-size may not be set at the same time
+can't open device TEST_DIR/t.IMGFMT: L2 cache entry size must be a power of two between 512 and the cluster size (65536)
+can't open device TEST_DIR/t.IMGFMT: L2 cache entry size must be a power of two between 512 and the cluster size (65536)
+can't open device TEST_DIR/t.IMGFMT: L2 cache entry size must be a power of two between 512 and the cluster size (65536)
=== Testing valid option combinations ===
diff --git a/tests/qemu-iotests/114.out b/tests/qemu-iotests/114.out
index 80220e440eca..c629db04e02f 100644
--- a/tests/qemu-iotests/114.out
+++ b/tests/qemu-iotests/114.out
@@ -10,8 +10,8 @@ virtual size: 64 MiB (67108864 bytes)
cluster_size: 65536
backing file: TEST_DIR/t.IMGFMT.base
backing file format: foo
-qemu-io: can't open device TEST_DIR/t.qcow2: Could not open backing file: Unknown driver 'foo'
-qemu-io: no file open, try 'help open'
+can't open device TEST_DIR/t.qcow2: Could not open backing file: Unknown driver 'foo'
+no file open, try 'help open'
read 4096/4096 bytes at offset 0
4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
qemu-img: Could not change the backing file to 'TEST_DIR/t.qcow2.base': backing format must be specified
diff --git a/tests/qemu-iotests/116.out b/tests/qemu-iotests/116.out
index 5f6c6fffcaf2..6d9f5488063d 100644
--- a/tests/qemu-iotests/116.out
+++ b/tests/qemu-iotests/116.out
@@ -2,29 +2,29 @@ QA output created by 116
== truncated header cluster ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
-qemu-io: can't open device TEST_DIR/t.qed: QED table offset is invalid
+can't open device TEST_DIR/t.qed: QED table offset is invalid
== invalid header magic ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
-qemu-io: can't open device TEST_DIR/t.qed: Image not in QED format
+can't open device TEST_DIR/t.qed: Image not in QED format
== invalid cluster size ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
-qemu-io: can't open device TEST_DIR/t.qed: QED cluster size is invalid
+can't open device TEST_DIR/t.qed: QED cluster size is invalid
== invalid table size ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
-qemu-io: can't open device TEST_DIR/t.qed: QED table size is invalid
+can't open device TEST_DIR/t.qed: QED table size is invalid
== invalid header size ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
-qemu-io: can't open device TEST_DIR/t.qed: QED table offset is invalid
+can't open device TEST_DIR/t.qed: QED table offset is invalid
== invalid L1 table offset ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
-qemu-io: can't open device TEST_DIR/t.qed: QED table offset is invalid
+can't open device TEST_DIR/t.qed: QED table offset is invalid
== invalid image size ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
-qemu-io: can't open device TEST_DIR/t.qed: QED image size is invalid
+can't open device TEST_DIR/t.qed: QED image size is invalid
*** done
diff --git a/tests/qemu-iotests/133.out b/tests/qemu-iotests/133.out
index d70c2e8041ce..8934c32dadd0 100644
--- a/tests/qemu-iotests/133.out
+++ b/tests/qemu-iotests/133.out
@@ -4,18 +4,18 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864 backing_file=TEST_DIR/t
=== Check that node-name can't be changed ===
-qemu-io: Cannot change the option 'node-name'
-qemu-io: Cannot change the option 'node-name'
-qemu-io: Cannot change the option 'node-name'
+Cannot change the option 'node-name'
+Cannot change the option 'node-name'
+Cannot change the option 'node-name'
=== Check that unchanged node-name is okay ===
=== Check that driver can't be changed ===
-qemu-io: Cannot change the option 'driver'
-qemu-io: Cannot change the option 'driver'
-qemu-io: Cannot change the option 'driver'
+Cannot change the option 'driver'
+Cannot change the option 'driver'
+Cannot change the option 'driver'
=== Check that unchanged driver is okay ===
@@ -27,16 +27,16 @@ format name: null-co
=== Check that mixing -c/-r/-w and their corresponding options is forbidden ===
-qemu-io: Cannot set both -r/-w and 'read-only'
-qemu-io: Cannot set both -r/-w and 'read-only'
-qemu-io: Cannot set both -c and the cache options
-qemu-io: Cannot set both -c and the cache options
-qemu-io: Cannot set both -c and the cache options
+Cannot set both -r/-w and 'read-only'
+Cannot set both -r/-w and 'read-only'
+Cannot set both -c and the cache options
+Cannot set both -c and the cache options
+Cannot set both -c and the cache options
=== Check that invalid options are handled correctly ===
-qemu-io: Parameter 'read-only' expects 'on' or 'off'
-qemu-io: Parameter 'cache.no-flush' expects 'on' or 'off'
-qemu-io: Parameter 'cache.direct' expects 'on' or 'off'
-qemu-io: Parameter 'auto-read-only' expects 'on' or 'off'
+Parameter 'read-only' expects 'on' or 'off'
+Parameter 'cache.no-flush' expects 'on' or 'off'
+Parameter 'cache.direct' expects 'on' or 'off'
+Parameter 'auto-read-only' expects 'on' or 'off'
*** done
diff --git a/tests/qemu-iotests/134.out b/tests/qemu-iotests/134.out
index ce2a0df166ee..4abc5b5f7da6 100644
--- a/tests/qemu-iotests/134.out
+++ b/tests/qemu-iotests/134.out
@@ -24,7 +24,7 @@ read 134217728/134217728 bytes at offset 0
128 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
== verify pattern failure with wrong password ==
-qemu-io: Pattern verification failed at offset 0, 134217728 bytes
+Pattern verification failed at offset 0, 134217728 bytes
read 134217728/134217728 bytes at offset 0
128 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
*** done
diff --git a/tests/qemu-iotests/137.out b/tests/qemu-iotests/137.out
index 1947c1a1bd7c..b22d4aeb747f 100644
--- a/tests/qemu-iotests/137.out
+++ b/tests/qemu-iotests/137.out
@@ -15,30 +15,30 @@ read 33554432/33554432 bytes at offset 0
=== Try setting some invalid values ===
-qemu-io: Parameter 'lazy-refcounts' expects 'on' or 'off'
-qemu-io: cache-size, l2-cache-size and refcount-cache-size may not be set at the same time
-qemu-io: l2-cache-size may not exceed cache-size
-qemu-io: refcount-cache-size may not exceed cache-size
-qemu-io: L2 cache entry size must be a power of two between 512 and the cluster size (65536)
-qemu-io: L2 cache entry size must be a power of two between 512 and the cluster size (65536)
-qemu-io: Refcount cache size too big
-qemu-io: Conflicting values for qcow2 options 'overlap-check' ('constant') and 'overlap-check.template' ('all')
-qemu-io: Unsupported value 'blubb' for qcow2 option 'overlap-check'. Allowed are any of the following: none, constant, cached, all
-qemu-io: Unsupported value 'blubb' for qcow2 option 'overlap-check'. Allowed are any of the following: none, constant, cached, all
-qemu-io: Cache clean interval too big
+Parameter 'lazy-refcounts' expects 'on' or 'off'
+cache-size, l2-cache-size and refcount-cache-size may not be set at the same time
+l2-cache-size may not exceed cache-size
+refcount-cache-size may not exceed cache-size
+L2 cache entry size must be a power of two between 512 and the cluster size (65536)
+L2 cache entry size must be a power of two between 512 and the cluster size (65536)
+Refcount cache size too big
+Conflicting values for qcow2 options 'overlap-check' ('constant') and 'overlap-check.template' ('all')
+Unsupported value 'blubb' for qcow2 option 'overlap-check'. Allowed are any of the following: none, constant, cached, all
+Unsupported value 'blubb' for qcow2 option 'overlap-check'. Allowed are any of the following: none, constant, cached, all
+Cache clean interval too big
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=36028797018963968
-qemu-io: L2 cache size too big
+L2 cache size too big
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
=== Test transaction semantics ===
-qemu-io: Unsupported value 'blubb' for qcow2 option 'overlap-check'. Allowed are any of the following: none, constant, cached, all
+Unsupported value 'blubb' for qcow2 option 'overlap-check'. Allowed are any of the following: none, constant, cached, all
wrote 512/512 bytes at offset 0
512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
./common.rc: Killed ( VALGRIND_QEMU="${VALGRIND_QEMU_IO}" _qemu_proc_exec "${VALGRIND_LOGFILE}" "$QEMU_IO_PROG" $QEMU_IO_ARGS "$@" )
OK: Dirty bit not set
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
-qemu-io: Parameter 'lazy-refcounts' expects 'on' or 'off'
+Parameter 'lazy-refcounts' expects 'on' or 'off'
qcow2: Marking image as corrupt: Preventing invalid allocation of L2 table at offset 0; further corruption events will be suppressed
-qemu-io: write failed: Input/output error
+write failed: Input/output error
*** done
diff --git a/tests/qemu-iotests/140.out b/tests/qemu-iotests/140.out
index 32866440aed3..c2a75fd5f7e8 100644
--- a/tests/qemu-iotests/140.out
+++ b/tests/qemu-iotests/140.out
@@ -16,7 +16,7 @@ read 65536/65536 bytes at offset 0
{ 'execute': 'eject',
'arguments': { 'device': 'drv' }}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "BLOCK_EXPORT_DELETED", "data": {"id": "drv"}}
-qemu-io: can't open device nbd+unix:///drv?socket=SOCK_DIR/nbd: Requested export not available
+can't open device nbd+unix:///drv?socket=SOCK_DIR/nbd: Requested export not available
server reported: export 'drv' not present
{ 'execute': 'quit' }
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
diff --git a/tests/qemu-iotests/143.out b/tests/qemu-iotests/143.out
index d6afa32abc54..5e685a06415b 100644
--- a/tests/qemu-iotests/143.out
+++ b/tests/qemu-iotests/143.out
@@ -5,9 +5,9 @@ QA output created by 143
'arguments': { 'addr': { 'type': 'unix',
'data': { 'path': 'SOCK_DIR/nbd' }}}}
{"return": {}}
-qemu-io: can't open device nbd+unix:///no_such_export?socket=SOCK_DIR/nbd: Requested export not available
+can't open device nbd+unix:///no_such_export?socket=SOCK_DIR/nbd: Requested export not available
server reported: export 'no_such_export' not present
-qemu-io: can't open device nbd+unix:///aa--aa1?socket=SOCK_DIR/nbd: Requested export not available
+can't open device nbd+unix:///aa--aa1?socket=SOCK_DIR/nbd: Requested export not available
server reported: export 'aa--aa...' not present
{ 'execute': 'quit' }
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
diff --git a/tests/qemu-iotests/153.out b/tests/qemu-iotests/153.out
index e235d9e59e35..1607a79b36b7 100644
--- a/tests/qemu-iotests/153.out
+++ b/tests/qemu-iotests/153.out
@@ -23,22 +23,22 @@ Is another process using the image [TEST_DIR/t.qcow2]?
== Running utility commands ==
_qemu_io_wrapper -c read 0 512 TEST_DIR/t.qcow2
-qemu-io: can't open device TEST_DIR/t.qcow2: Failed to get "write" lock
+can't open device TEST_DIR/t.qcow2: Failed to get "write" lock
Is another process using the image [TEST_DIR/t.qcow2]?
_qemu_io_wrapper -r -c read 0 512 TEST_DIR/t.qcow2
-qemu-io: can't open device TEST_DIR/t.qcow2: Failed to get shared "write" lock
+can't open device TEST_DIR/t.qcow2: Failed to get shared "write" lock
Is another process using the image [TEST_DIR/t.qcow2]?
_qemu_io_wrapper -c open TEST_DIR/t.qcow2 -c read 0 512
-qemu-io: can't open device TEST_DIR/t.qcow2: Failed to get "write" lock
+can't open device TEST_DIR/t.qcow2: Failed to get "write" lock
Is another process using the image [TEST_DIR/t.qcow2]?
-qemu-io: no file open, try 'help open'
+no file open, try 'help open'
_qemu_io_wrapper -c open -r TEST_DIR/t.qcow2 -c read 0 512
-qemu-io: can't open device TEST_DIR/t.qcow2: Failed to get shared "write" lock
+can't open device TEST_DIR/t.qcow2: Failed to get shared "write" lock
Is another process using the image [TEST_DIR/t.qcow2]?
-qemu-io: no file open, try 'help open'
+no file open, try 'help open'
_qemu_img_wrapper info TEST_DIR/t.qcow2
qemu-img: Could not open 'TEST_DIR/t.qcow2': Failed to get shared "write" lock
@@ -101,13 +101,13 @@ backing file format: IMGFMT
== Running utility commands -U ==
_qemu_io_wrapper -U -c read 0 512 TEST_DIR/t.qcow2
-qemu-io: can't open device TEST_DIR/t.qcow2: force-share=on can only be used with read-only images
+can't open device TEST_DIR/t.qcow2: force-share=on can only be used with read-only images
_qemu_io_wrapper -U -r -c read 0 512 TEST_DIR/t.qcow2
_qemu_io_wrapper -c open -U TEST_DIR/t.qcow2 -c read 0 512
-qemu-io: can't open device TEST_DIR/t.qcow2: force-share=on can only be used with read-only images
-qemu-io: no file open, try 'help open'
+can't open device TEST_DIR/t.qcow2: force-share=on can only be used with read-only images
+no file open, try 'help open'
_qemu_io_wrapper -c open -r -U TEST_DIR/t.qcow2 -c read 0 512
@@ -168,15 +168,15 @@ Is another process using the image [TEST_DIR/t.qcow2]?
== Running utility commands ==
_qemu_io_wrapper -c read 0 512 TEST_DIR/t.qcow2
-qemu-io: can't open device TEST_DIR/t.qcow2: Failed to get "write" lock
+can't open device TEST_DIR/t.qcow2: Failed to get "write" lock
Is another process using the image [TEST_DIR/t.qcow2]?
_qemu_io_wrapper -r -c read 0 512 TEST_DIR/t.qcow2
_qemu_io_wrapper -c open TEST_DIR/t.qcow2 -c read 0 512
-qemu-io: can't open device TEST_DIR/t.qcow2: Failed to get "write" lock
+can't open device TEST_DIR/t.qcow2: Failed to get "write" lock
Is another process using the image [TEST_DIR/t.qcow2]?
-qemu-io: no file open, try 'help open'
+no file open, try 'help open'
_qemu_io_wrapper -c open -r TEST_DIR/t.qcow2 -c read 0 512
@@ -225,13 +225,13 @@ backing file format: IMGFMT
== Running utility commands -U ==
_qemu_io_wrapper -U -c read 0 512 TEST_DIR/t.qcow2
-qemu-io: can't open device TEST_DIR/t.qcow2: force-share=on can only be used with read-only images
+can't open device TEST_DIR/t.qcow2: force-share=on can only be used with read-only images
_qemu_io_wrapper -U -r -c read 0 512 TEST_DIR/t.qcow2
_qemu_io_wrapper -c open -U TEST_DIR/t.qcow2 -c read 0 512
-qemu-io: can't open device TEST_DIR/t.qcow2: force-share=on can only be used with read-only images
-qemu-io: no file open, try 'help open'
+can't open device TEST_DIR/t.qcow2: force-share=on can only be used with read-only images
+no file open, try 'help open'
_qemu_io_wrapper -c open -r -U TEST_DIR/t.qcow2 -c read 0 512
@@ -330,13 +330,13 @@ backing file format: IMGFMT
== Running utility commands -U ==
_qemu_io_wrapper -U -c read 0 512 TEST_DIR/t.qcow2
-qemu-io: can't open device TEST_DIR/t.qcow2: force-share=on can only be used with read-only images
+can't open device TEST_DIR/t.qcow2: force-share=on can only be used with read-only images
_qemu_io_wrapper -U -r -c read 0 512 TEST_DIR/t.qcow2
_qemu_io_wrapper -c open -U TEST_DIR/t.qcow2 -c read 0 512
-qemu-io: can't open device TEST_DIR/t.qcow2: force-share=on can only be used with read-only images
-qemu-io: no file open, try 'help open'
+can't open device TEST_DIR/t.qcow2: force-share=on can only be used with read-only images
+no file open, try 'help open'
_qemu_io_wrapper -c open -r -U TEST_DIR/t.qcow2 -c read 0 512
@@ -430,7 +430,7 @@ Adding drive
{"return": "OKrn"}
_qemu_io_wrapper TEST_DIR/t.qcow2 -c write 0 512
-qemu-io: can't open device TEST_DIR/t.qcow2: Failed to get "write" lock
+can't open device TEST_DIR/t.qcow2: Failed to get "write" lock
Is another process using the image [TEST_DIR/t.qcow2]?
Creating overlay with qemu-img when the guest is running should be allowed
@@ -455,7 +455,7 @@ _qemu_img_wrapper info TEST_DIR/t.qcow2
{"return": ""}
_qemu_io_wrapper TEST_DIR/t.qcow2 -c write 0 512
-qemu-io: can't open device TEST_DIR/t.qcow2: Failed to get "write" lock
+can't open device TEST_DIR/t.qcow2: Failed to get "write" lock
Is another process using the image [TEST_DIR/t.qcow2]?
Closing the other
{ 'execute': 'human-monitor-command',
@@ -478,5 +478,5 @@ qemu-img: --force-share/-U conflicts with image options
No conflict:
Conflict:
-qemu-io: -U conflicts with image options
+-U conflicts with image options
*** done
diff --git a/tests/qemu-iotests/171.out b/tests/qemu-iotests/171.out
index 67ef9b884152..ec3363b4f440 100644
--- a/tests/qemu-iotests/171.out
+++ b/tests/qemu-iotests/171.out
@@ -21,32 +21,32 @@ wrote 1/1 bytes at offset 3583
1 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
write across image boundary
-qemu-io: write failed: Input/output error
+write failed: Input/output error
write at image boundary
-qemu-io: write failed: Input/output error
+write failed: Input/output error
write after image boundary
-qemu-io: write failed: Input/output error
+write failed: Input/output error
writev before/after image boundary
-qemu-io: writev failed: Input/output error
+writev failed: Input/output error
read before image boundary
read 1/1 bytes at offset 3583
1 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
read across image boundary
-qemu-io: read failed: Input/output error
+read failed: Input/output error
read at image boundary
-qemu-io: read failed: Input/output error
+read failed: Input/output error
read after image boundary
-qemu-io: read failed: Input/output error
+read failed: Input/output error
readv before/after image boundary
-qemu-io: readv failed: Input/output error
+readv failed: Input/output error
fill image with pattern
wrote 4096/4096 bytes at offset 0
@@ -60,7 +60,7 @@ read 4/4 bytes at offset 510
4 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
write zeroes across image boundary
-qemu-io: write failed: Input/output error
+write failed: Input/output error
write zeroes at image boundary and check
wrote 2/2 bytes at offset 3582
@@ -68,7 +68,7 @@ wrote 2/2 bytes at offset 3582
00000ffe: 00 00 ..
read 2/2 bytes at offset 4094
2 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: read failed: Input/output error
+read failed: Input/output error
fill image with pattern
wrote 4096/4096 bytes at offset 0
@@ -82,7 +82,7 @@ read 4/4 bytes at offset 510
4 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
discard across image boundary
-qemu-io: discard failed: Input/output error
+discard failed: Input/output error
discard at image boundary and check
discard 2/2 bytes at offset 3582
@@ -90,7 +90,7 @@ discard 2/2 bytes at offset 3582
00000ffe: 00 00 ..
read 2/2 bytes at offset 4094
2 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: read failed: Input/output error
+read failed: Input/output error
== test 'offset' and 'size' options ==
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=4096
@@ -113,32 +113,32 @@ wrote 1/1 bytes at offset 2047
1 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
write across image boundary
-qemu-io: write failed: Input/output error
+write failed: Input/output error
write at image boundary
-qemu-io: write failed: Input/output error
+write failed: Input/output error
write after image boundary
-qemu-io: write failed: Input/output error
+write failed: Input/output error
writev before/after image boundary
-qemu-io: writev failed: Input/output error
+writev failed: Input/output error
read before image boundary
read 1/1 bytes at offset 2047
1 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
read across image boundary
-qemu-io: read failed: Input/output error
+read failed: Input/output error
read at image boundary
-qemu-io: read failed: Input/output error
+read failed: Input/output error
read after image boundary
-qemu-io: read failed: Input/output error
+read failed: Input/output error
readv before/after image boundary
-qemu-io: readv failed: Input/output error
+readv failed: Input/output error
fill image with pattern
wrote 4096/4096 bytes at offset 0
@@ -152,7 +152,7 @@ read 4/4 bytes at offset 510
4 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
write zeroes across image boundary
-qemu-io: write failed: Input/output error
+write failed: Input/output error
write zeroes at image boundary and check
wrote 2/2 bytes at offset 2046
@@ -176,7 +176,7 @@ read 4/4 bytes at offset 510
4 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
discard across image boundary
-qemu-io: discard failed: Input/output error
+discard failed: Input/output error
discard at image boundary and check
discard 2/2 bytes at offset 2046
@@ -209,32 +209,32 @@ wrote 1/1 bytes at offset 2047
1 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
write across image boundary
-qemu-io: write failed: Input/output error
+write failed: Input/output error
write at image boundary
-qemu-io: write failed: Input/output error
+write failed: Input/output error
write after image boundary
-qemu-io: write failed: Input/output error
+write failed: Input/output error
writev before/after image boundary
-qemu-io: writev failed: Input/output error
+writev failed: Input/output error
read before image boundary
read 1/1 bytes at offset 2047
1 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
read across image boundary
-qemu-io: read failed: Input/output error
+read failed: Input/output error
read at image boundary
-qemu-io: read failed: Input/output error
+read failed: Input/output error
read after image boundary
-qemu-io: read failed: Input/output error
+read failed: Input/output error
readv before/after image boundary
-qemu-io: readv failed: Input/output error
+readv failed: Input/output error
fill image with pattern
wrote 4096/4096 bytes at offset 0
@@ -248,7 +248,7 @@ read 4/4 bytes at offset 8
4 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
write zeroes across image boundary
-qemu-io: write failed: Input/output error
+write failed: Input/output error
write zeroes at image boundary and check
wrote 2/2 bytes at offset 2046
@@ -272,7 +272,7 @@ read 4/4 bytes at offset 8
4 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
discard across image boundary
-qemu-io: discard failed: Input/output error
+discard failed: Input/output error
discard at image boundary and check
discard 2/2 bytes at offset 2046
@@ -290,12 +290,12 @@ wrote 512/512 bytes at offset 0
512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
wrote 1/1 bytes at offset 511
1 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: write failed: Input/output error
+write failed: Input/output error
wrote 1024/1024 bytes at offset 0
1 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
wrote 1/1 bytes at offset 1023
1 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: write failed: Input/output error
+write failed: Input/output error
checking boundaries
000001fe: 00 00 0a 0a ....
read 4/4 bytes at offset 510
diff --git a/tests/qemu-iotests/187.out b/tests/qemu-iotests/187.out
index 86203d8abcb0..30b987f71f8d 100644
--- a/tests/qemu-iotests/187.out
+++ b/tests/qemu-iotests/187.out
@@ -3,16 +3,16 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
Start from read-only
-qemu-io: Block node is read-only
+Block node is read-only
wrote 65536/65536 bytes at offset 0
64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: Block node is read-only
+Block node is read-only
Start from read-write
wrote 65536/65536 bytes at offset 0
64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: Block node is read-only
+Block node is read-only
wrote 65536/65536 bytes at offset 0
64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
*** done
diff --git a/tests/qemu-iotests/188.out b/tests/qemu-iotests/188.out
index 5426861b180c..0f05a6901419 100644
--- a/tests/qemu-iotests/188.out
+++ b/tests/qemu-iotests/188.out
@@ -14,7 +14,7 @@ read 16777216/16777216 bytes at offset 0
16 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
== verify open failure with wrong password ==
-qemu-io: can't open: Invalid password, cannot unlock any keyslot
+can't open: Invalid password, cannot unlock any keyslot
== verify that has_zero_init returns false when preallocating ==
Formatting 'TEST_DIR/t.IMGFMT.orig', fmt=IMGFMT size=16777216
diff --git a/tests/qemu-iotests/197.out b/tests/qemu-iotests/197.out
index 86c57b51d303..ebb20da95f6e 100644
--- a/tests/qemu-iotests/197.out
+++ b/tests/qemu-iotests/197.out
@@ -16,7 +16,7 @@ read 2147483136/2147483136 bytes at offset 1024
2 GiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
read 1024/1024 bytes at offset 3221226496
1 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: can't open device TEST_DIR/t.wrap.qcow2: Can't use copy-on-read on read-only device
+can't open device TEST_DIR/t.wrap.qcow2: Can't use copy-on-read on read-only device
2 GiB (0x80010000) bytes allocated at offset 0 bytes (0x0)
1023.938 MiB (0x3fff0000) bytes not allocated at offset 2 GiB (0x80010000)
64 KiB (0x10000) bytes allocated at offset 3 GiB (0xc0000000)
diff --git a/tests/qemu-iotests/205 b/tests/qemu-iotests/205
index 3ed3ed233ac9..947de270c8e7 100755
--- a/tests/qemu-iotests/205
+++ b/tests/qemu-iotests/205
@@ -75,11 +75,11 @@ class TestNbdServerRemove(iotests.QMPTestCase):
def assertReadFailed(self, qemu_io_output):
self.assertEqual(filter_qemu_io(qemu_io_output).strip(),
- 'qemu-io: read failed: Input/output error')
+ 'read failed: Input/output error')
def assertConnectFailed(self, qemu_io_output):
self.assertEqual(filter_qemu_io(qemu_io_output).strip(),
- "qemu-io: can't open device " + nbd_uri +
+ "can't open device " + nbd_uri +
": Requested export not available\n"
"server reported: export 'exp' not present")
diff --git a/tests/qemu-iotests/214.out b/tests/qemu-iotests/214.out
index 26056938ee9e..9fc67287f8e1 100644
--- a/tests/qemu-iotests/214.out
+++ b/tests/qemu-iotests/214.out
@@ -7,7 +7,7 @@ wrote 2097152/2097152 bytes at offset 0
2 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
wrote 2097152/2097152 bytes at offset 2097152
2 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: read failed: Input/output error
+read failed: Input/output error
No errors were found on the image.
read 4194304/4194304 bytes at offset 0
4 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
diff --git a/tests/qemu-iotests/215.out b/tests/qemu-iotests/215.out
index 5a2fe40d0314..70b0f5fb1956 100644
--- a/tests/qemu-iotests/215.out
+++ b/tests/qemu-iotests/215.out
@@ -16,7 +16,7 @@ read 2147483136/2147483136 bytes at offset 1024
2 GiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
read 1024/1024 bytes at offset 3221226496
1 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: can't open device TEST_DIR/t.wrap.qcow2: Block node is read-only
+can't open device TEST_DIR/t.wrap.qcow2: Block node is read-only
2 GiB (0x80010000) bytes allocated at offset 0 bytes (0x0)
1023.938 MiB (0x3fff0000) bytes not allocated at offset 2 GiB (0x80010000)
64 KiB (0x10000) bytes allocated at offset 3 GiB (0xc0000000)
diff --git a/tests/qemu-iotests/220.out b/tests/qemu-iotests/220.out
index 6f200ec89479..33b994b8a14b 100644
--- a/tests/qemu-iotests/220.out
+++ b/tests/qemu-iotests/220.out
@@ -38,7 +38,7 @@ wrote 2097152/2097152 bytes at offset 37748736
No errors were found on the image.
image size 39845888
== Trying to write compressed cluster ==
-qemu-io: write failed: File too large
+write failed: File too large
image size 562949957615616
== Writing normal cluster ==
wrote 2097152/2097152 bytes at offset 0
diff --git a/tests/qemu-iotests/226.out b/tests/qemu-iotests/226.out
index 55504d29c4b3..14d1be50f748 100644
--- a/tests/qemu-iotests/226.out
+++ b/tests/qemu-iotests/226.out
@@ -3,24 +3,24 @@ QA output created by 226
=== Testing with driver:file ===
== Testing RO ==
-qemu-io: can't open: 'file' driver requires 'TEST_DIR/t.IMGFMT' to be a regular file
-qemu-io: can't open: 'file' driver requires '/dev/null' to be a regular file
+can't open: 'file' driver requires 'TEST_DIR/t.IMGFMT' to be a regular file
+can't open: 'file' driver requires '/dev/null' to be a regular file
== Testing RW ==
-qemu-io: can't open: Could not open 'TEST_DIR/t.IMGFMT': Is a directory
-qemu-io: can't open: 'file' driver requires '/dev/null' to be a regular file
+can't open: Could not open 'TEST_DIR/t.IMGFMT': Is a directory
+can't open: 'file' driver requires '/dev/null' to be a regular file
=== Testing with driver:host_device ===
== Testing RO ==
-qemu-io: can't open: 'host_device' driver requires 'TEST_DIR/t.IMGFMT' to be either a character or block device
+can't open: 'host_device' driver requires 'TEST_DIR/t.IMGFMT' to be either a character or block device
== Testing RW ==
-qemu-io: can't open: Could not open 'TEST_DIR/t.IMGFMT': Is a directory
+can't open: Could not open 'TEST_DIR/t.IMGFMT': Is a directory
=== Testing with driver:host_cdrom ===
== Testing RO ==
-qemu-io: can't open: 'host_cdrom' driver requires 'TEST_DIR/t.IMGFMT' to be either a character or block device
+can't open: 'host_cdrom' driver requires 'TEST_DIR/t.IMGFMT' to be either a character or block device
== Testing RW ==
-qemu-io: can't open: Could not open 'TEST_DIR/t.IMGFMT': Is a directory
+can't open: Could not open 'TEST_DIR/t.IMGFMT': Is a directory
*** done
diff --git a/tests/qemu-iotests/244.out b/tests/qemu-iotests/244.out
index c5e62146c930..6b7fbb3a4168 100644
--- a/tests/qemu-iotests/244.out
+++ b/tests/qemu-iotests/244.out
@@ -9,23 +9,23 @@ read 65536/65536 bytes at offset 0
64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
read 65536/65536 bytes at offset 0
64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: can't open device TEST_DIR/t.qcow2: Could not open 'inexistent': No such file or directory
-qemu-io: no file open, try 'help open'
+can't open device TEST_DIR/t.qcow2: Could not open 'inexistent': No such file or directory
+no file open, try 'help open'
Data file required, but without data file name in the image:
-qemu-io: can't open device TEST_DIR/t.qcow2: 'data-file' is required for this image
-qemu-io: no file open, try 'help open'
+can't open device TEST_DIR/t.qcow2: 'data-file' is required for this image
+no file open, try 'help open'
read 65536/65536 bytes at offset 0
64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: can't open device TEST_DIR/t.qcow2: Could not open 'inexistent': No such file or directory
-qemu-io: no file open, try 'help open'
+can't open device TEST_DIR/t.qcow2: Could not open 'inexistent': No such file or directory
+no file open, try 'help open'
Setting data-file for an image with internal data:
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
-qemu-io: can't open device TEST_DIR/t.qcow2: 'data-file' can only be set for images with an external data file
-qemu-io: no file open, try 'help open'
-qemu-io: can't open device TEST_DIR/t.qcow2: Could not open 'inexistent': No such file or directory
-qemu-io: no file open, try 'help open'
+can't open device TEST_DIR/t.qcow2: 'data-file' can only be set for images with an external data file
+no file open, try 'help open'
+can't open device TEST_DIR/t.qcow2: Could not open 'inexistent': No such file or directory
+no file open, try 'help open'
=== Conflicting features ===
@@ -37,7 +37,7 @@ qemu-img: error while writing at byte 0: Operation not supported
Convert uncompressed, then write compressed data manually:
Images are identical.
-qemu-io: write failed: Operation not supported
+write failed: Operation not supported
No errors were found on the image.
Take an internal snapshot:
diff --git a/tests/qemu-iotests/271.out b/tests/qemu-iotests/271.out
index da92d4b5b1ab..0b24d501595b 100644
--- a/tests/qemu-iotests/271.out
+++ b/tests/qemu-iotests/271.out
@@ -456,7 +456,7 @@ L2 entry #0: 0x8000000000050001 0000000000000001
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1048576
L2 entry #1: 0x8000000000060000 00000001ffffffff
qcow2: Marking image as corrupt: Invalid cluster entry found (L2 offset: 0x40000, L2 index: 0x1); further corruption events will be suppressed
-qemu-io: read failed: Input/output error
+read failed: Input/output error
### Corrupted L2 entries - read test (unallocated) ###
@@ -471,14 +471,14 @@ L2 entry #0: 0x0000000000000001 0000000000000000
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1048576
L2 entry #0: 0x0000000000000000 0000000000000001
qcow2: Marking image as corrupt: Invalid cluster entry found (L2 offset: 0x40000, L2 index: 0); further corruption events will be suppressed
-qemu-io: read failed: Input/output error
+read failed: Input/output error
# Both 'subcluster is zero' and 'subcluster is allocated' bits set
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1048576
L2 entry #1: 0x0000000000000000 0000000100000001
qcow2: Marking image as corrupt: Invalid cluster entry found (L2 offset: 0x40000, L2 index: 0x1); further corruption events will be suppressed
-qemu-io: read failed: Input/output error
+read failed: Input/output error
### Compressed cluster with subcluster bitmap != 0 - read test ###
@@ -501,7 +501,7 @@ L2 entry #0: 0x8000000000050001 0000000000000001
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1048576
L2 entry #1: 0x8000000000060000 00000001ffffffff
qcow2: Marking image as corrupt: Invalid cluster entry found (L2 offset: 0x40000, L2 index: 0x1); further corruption events will be suppressed
-qemu-io: write failed: Input/output error
+write failed: Input/output error
### Corrupted L2 entries - write test (unallocated) ###
@@ -516,14 +516,14 @@ L2 entry #0: 0x8000000000060000 0000000000000001
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1048576
L2 entry #0: 0x0000000000000000 0000000000000001
qcow2: Marking image as corrupt: Invalid cluster entry found (L2 offset: 0x40000, L2 index: 0); further corruption events will be suppressed
-qemu-io: write failed: Input/output error
+write failed: Input/output error
# Both 'subcluster is zero' and 'subcluster is allocated' bits set
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1048576
L2 entry #1: 0x0000000000000000 0000000100000001
qcow2: Marking image as corrupt: Invalid cluster entry found (L2 offset: 0x40000, L2 index: 0x1); further corruption events will be suppressed
-qemu-io: write failed: Input/output error
+write failed: Input/output error
### Compressed cluster with subcluster bitmap != 0 - write test ###
@@ -555,7 +555,7 @@ Double checking the fixed image now...
1 errors were found on the image.
Data may be corrupted, or further writes to the image may corrupt it.
qcow2: Marking image as corrupt: Cluster allocation offset 0x50200 unaligned (L2 offset: 0x40000, L2 index: 0); further corruption events will be suppressed
-qemu-io: read failed: Input/output error
+read failed: Input/output error
# Corrupted L2 entry, no allocated subclusters #
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=131072 backing_file=TEST_DIR/t.IMGFMT.base backing_fmt=raw
Repairing offset=50200: Preallocated cluster is not properly aligned; L2 entry corrupted.
diff --git a/tests/qemu-iotests/289.out b/tests/qemu-iotests/289.out
index 58e4f4942f0c..e54e2629d4dc 100644
--- a/tests/qemu-iotests/289.out
+++ b/tests/qemu-iotests/289.out
@@ -3,6 +3,6 @@ QA output created by 289
=== Avoid freeing external data clusters on failure ===
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=65536 data_file=TEST_DIR/t.IMGFMT.data_file
-qemu-io: write failed: Input/output error
+write failed: Input/output error
No errors were found on the image.
*** done
diff --git a/tests/qemu-iotests/293.out b/tests/qemu-iotests/293.out
index 72607831260c..5e5b0d8d54b8 100644
--- a/tests/qemu-iotests/293.out
+++ b/tests/qemu-iotests/293.out
@@ -23,10 +23,10 @@ read 4096/4096 bytes at offset 0
4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
== erase slot 0 and try it ==
-qemu-io: can't open: Invalid password, cannot unlock any keyslot
+can't open: Invalid password, cannot unlock any keyslot
== erase slot 2 and try it ==
-qemu-io: can't open: Invalid password, cannot unlock any keyslot
+can't open: Invalid password, cannot unlock any keyslot
== filling 4 slots with secret 2 ==
@@ -54,9 +54,9 @@ read 4096/4096 bytes at offset 0
qemu-img: All the active keyslots match the (old) password that was given and erasing them will erase all the data in the image irreversibly - refusing operation
== only secret3 should work now ==
-qemu-io: can't open: Invalid password, cannot unlock any keyslot
-qemu-io: can't open: Invalid password, cannot unlock any keyslot
-qemu-io: can't open: Invalid password, cannot unlock any keyslot
+can't open: Invalid password, cannot unlock any keyslot
+can't open: Invalid password, cannot unlock any keyslot
+can't open: Invalid password, cannot unlock any keyslot
read 4096/4096 bytes at offset 0
4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
@@ -66,9 +66,9 @@ read 4096/4096 bytes at offset 0
== only secret0 should work now ==
read 4096/4096 bytes at offset 0
4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: can't open: Invalid password, cannot unlock any keyslot
-qemu-io: can't open: Invalid password, cannot unlock any keyslot
-qemu-io: can't open: Invalid password, cannot unlock any keyslot
+can't open: Invalid password, cannot unlock any keyslot
+can't open: Invalid password, cannot unlock any keyslot
+can't open: Invalid password, cannot unlock any keyslot
== replace secret0 with secret1 (should fail) ==
qemu-img: Refusing to overwrite active keyslot 0 - please erase it first
@@ -76,11 +76,11 @@ qemu-img: Refusing to overwrite active keyslot 0 - please erase it first
== replace secret0 with secret1 with force (should work) ==
== only secret1 should work now ==
-qemu-io: can't open: Invalid password, cannot unlock any keyslot
+can't open: Invalid password, cannot unlock any keyslot
read 4096/4096 bytes at offset 0
4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: can't open: Invalid password, cannot unlock any keyslot
-qemu-io: can't open: Invalid password, cannot unlock any keyslot
+can't open: Invalid password, cannot unlock any keyslot
+can't open: Invalid password, cannot unlock any keyslot
== erase last secret (should fail) ==
qemu-img: Attempt to erase the only active keyslot 0 which will erase all the data in the image irreversibly - refusing operation
@@ -92,8 +92,8 @@ qemu-img: No keyslots match given (old) password for erase operation
== erase last secret with force by slot (should work) ==
== we have no secrets now, data is lost forever ==
-qemu-io: can't open: Invalid password, cannot unlock any keyslot
-qemu-io: can't open: Invalid password, cannot unlock any keyslot
-qemu-io: can't open: Invalid password, cannot unlock any keyslot
-qemu-io: can't open: Invalid password, cannot unlock any keyslot
+can't open: Invalid password, cannot unlock any keyslot
+can't open: Invalid password, cannot unlock any keyslot
+can't open: Invalid password, cannot unlock any keyslot
+can't open: Invalid password, cannot unlock any keyslot
*** done
diff --git a/tests/qemu-iotests/294.out b/tests/qemu-iotests/294.out
index 994ae873081c..6aeabb43f604 100644
--- a/tests/qemu-iotests/294.out
+++ b/tests/qemu-iotests/294.out
@@ -15,14 +15,14 @@ read 4096/4096 bytes at offset 0
== erase slot 0 ==
== test that key 0 doesn't open the image ==
-qemu-io: can't open: Invalid password, cannot unlock any keyslot
+can't open: Invalid password, cannot unlock any keyslot
== 'restore' the image header ==
1+0 records in
1+0 records out
== test that key 0 still doesn't open the image (key material is erased) ==
-qemu-io: can't open: Invalid password, cannot unlock any keyslot
+can't open: Invalid password, cannot unlock any keyslot
== test that key 1 still works ==
read 4096/4096 bytes at offset 0
diff --git a/tests/qemu-iotests/305.out b/tests/qemu-iotests/305.out
index af09d6a3ff48..538019e72601 100644
--- a/tests/qemu-iotests/305.out
+++ b/tests/qemu-iotests/305.out
@@ -12,5 +12,5 @@ discard 1024/1024 bytes at offset 125952
### Corrupt the offset of the second refcount block
### Try to allocate the discarded clusters again
qcow2: Marking image as corrupt: Refblock offset 0x20600 unaligned (reftable index: 0x1); further corruption events will be suppressed
-qemu-io: write failed: Input/output error
+write failed: Input/output error
*** done
diff --git a/tests/qemu-iotests/307.out b/tests/qemu-iotests/307.out
index 608b407a6fc5..a9b37d3ac119 100644
--- a/tests/qemu-iotests/307.out
+++ b/tests/qemu-iotests/307.out
@@ -127,7 +127,7 @@ exports available: 1
{"error": {"class": "GenericError", "desc": "export 'export1' still in use"}}
{"execute": "block-export-del", "arguments": {"id": "export1", "mode": "hard"}}
{"return": {}}
-qemu-io: read failed: Input/output error
+read failed: Input/output error
{"execute": "query-block-exports", "arguments": {}}
{"return": []}
diff --git a/tests/qemu-iotests/tests/file-io-error.out b/tests/qemu-iotests/tests/file-io-error.out
index bf8c0018ba5a..0f46455a94a7 100644
--- a/tests/qemu-iotests/tests/file-io-error.out
+++ b/tests/qemu-iotests/tests/file-io-error.out
@@ -21,7 +21,7 @@ QA output created by file-io-error
}}
{"return": {}}
-qemu-io: write failed: Input/output error
+write failed: Input/output error
{'execute': 'block-export-del',
'arguments': {'id': 'exp0'}}
diff --git a/tests/qemu-iotests/tests/image-fleecing.out b/tests/qemu-iotests/tests/image-fleecing.out
index dc788f1e20a4..acfc89ff0e99 100644
--- a/tests/qemu-iotests/tests/image-fleecing.out
+++ b/tests/qemu-iotests/tests/image-fleecing.out
@@ -238,13 +238,13 @@ read -P0xd5 1M 64k
read -P0xdc 32M 64k
read -P0xcd 0x3ff0000 64k
read -P0 0x00f8000 32k
-qemu-io: read failed: Invalid argument
+read failed: Invalid argument
read -P0 0x2010000 32k
-qemu-io: read failed: Invalid argument
+read failed: Invalid argument
read -P0 0x3fe0000 64k
-qemu-io: read failed: Invalid argument
+read failed: Invalid argument
--- Testing COW ---
@@ -265,13 +265,13 @@ read -P0xd5 1M 64k
read -P0xdc 32M 64k
read -P0xcd 0x3ff0000 64k
read -P0 0x00f8000 32k
-qemu-io: read failed: Invalid argument
+read failed: Invalid argument
read -P0 0x2010000 32k
-qemu-io: read failed: Invalid argument
+read failed: Invalid argument
read -P0 0x3fe0000 64k
-qemu-io: read failed: Invalid argument
+read failed: Invalid argument
--- Cleanup ---
diff --git a/tests/qemu-iotests/tests/inactive-node-nbd.out b/tests/qemu-iotests/tests/inactive-node-nbd.out
index 96af7608ded2..cdb5bfbaac5b 100644
--- a/tests/qemu-iotests/tests/inactive-node-nbd.out
+++ b/tests/qemu-iotests/tests/inactive-node-nbd.out
@@ -215,16 +215,16 @@ target-fmt active: True
read 65536/65536 bytes at offset 0
64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-qemu-io: write failed: Operation not permitted
+write failed: Operation not permitted
-qemu-io: write failed: Operation not permitted
+write failed: Operation not permitted
-qemu-io: write failed: Operation not permitted
+write failed: Operation not permitted
-qemu-io: discard failed: Operation not permitted
+discard failed: Operation not permitted
-qemu-io: Failed to get allocation status: Operation not permitted
+Failed to get allocation status: Operation not permitted
=== Inactivating a read-only node ===
diff --git a/tests/qemu-iotests/tests/nbd-reconnect-on-open.out b/tests/qemu-iotests/tests/nbd-reconnect-on-open.out
index b3dd90f2a3cd..69544c38a560 100644
--- a/tests/qemu-iotests/tests/nbd-reconnect-on-open.out
+++ b/tests/qemu-iotests/tests/nbd-reconnect-on-open.out
@@ -2,10 +2,10 @@ read 1048576/1048576 bytes at offset 0
1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
Check fail to connect with 0 seconds of timeout
-qemu-io: can't open: Failed to connect to 'SOCK_DIR/PID-nbd-sock': No such file or directory
+can't open: Failed to connect to 'SOCK_DIR/PID-nbd-sock': No such file or directory
qemu_io finished in 0..0.2 seconds, OK
Check fail to connect with 1 seconds of timeout
-qemu-io: can't open: Failed to connect to 'SOCK_DIR/PID-nbd-sock': No such file or directory
+can't open: Failed to connect to 'SOCK_DIR/PID-nbd-sock': No such file or directory
qemu_io finished in 1..1.2 seconds, OK
diff --git a/tests/qemu-iotests/tests/parallels-bitmap.out b/tests/qemu-iotests/tests/parallels-bitmap.out
index df6f6761062e..580296d179ba 100644
--- a/tests/qemu-iotests/tests/parallels-bitmap.out
+++ b/tests/qemu-iotests/tests/parallels-bitmap.out
@@ -82,10 +82,10 @@ qemu-img: Operation add on bitmap 9b7b8b2e-1c4a-4d3f-8e6a-1f2d3c4b5a69 failed: B
in use after deactivation: False
in use after activation: True
--- a bitmap which can not be written is reported, not lost in silence
- qemu-io: Lost persistent bitmaps during inactivation of node 'NODE_NAME': Can't save dirty bitmap 9b7b8b2e-1c4a-4d3f-8e6a-1f2d3c4b5a69: IO error: Input/output error
+ Lost persistent bitmaps during inactivation of node 'NODE_NAME': Can't save dirty bitmap 9b7b8b2e-1c4a-4d3f-8e6a-1f2d3c4b5a69: IO error: Input/output error
in use after the failure: True
--- but the guest data went through, and the image says it is in use
-qemu-io: warning: Dropping the Format Extension of node 'NODE_NAME', which does not look like one: Wrong parallels Format Extension magic: 0x1111111111111111, expected: 0xab234cef23dcea87
+warning: Dropping the Format Extension of node 'NODE_NAME', which does not look like one: Wrong parallels Format Extension magic: 0x1111111111111111, expected: 0xab234cef23dcea87
read 65536/65536 bytes at offset 0
64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
diff --git a/tests/qemu-iotests/tests/parallels-checks.out b/tests/qemu-iotests/tests/parallels-checks.out
index f6806f82fa76..bc77ce1f5347 100644
--- a/tests/qemu-iotests/tests/parallels-checks.out
+++ b/tests/qemu-iotests/tests/parallels-checks.out
@@ -146,7 +146,7 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=4194304
== open must fail cleanly instead of aborting ==
qemu-img: Could not open 'TEST_DIR/t.IMGFMT': Invalid image: Catalog size too small for advertised disk size
== write into the uncovered range must fail cleanly too ==
-qemu-io: can't open device TEST_DIR/t.parallels: Invalid image: Catalog size too small for advertised disk size
+can't open device TEST_DIR/t.parallels: Invalid image: Catalog size too small for advertised disk size
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=4194304
== TEST BAT ENTRY POINTING OUTSIDE IMAGE ==
== corrupt image: point first cluster far outside the file ==
@@ -307,7 +307,7 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=4194304
== a guest write may reuse the extension cluster, so clobber it ==
== pretend the image was not closed correctly ==
== the image opens, the extension is dropped ==
-qemu-io: warning: Dropping the Format Extension of node 'NODE_NAME', which does not look like one: Wrong parallels Format Extension magic: 0xaaaaaaaaaaaaaaaa, expected: 0xab234cef23dcea87
+warning: Dropping the Format Extension of node 'NODE_NAME', which does not look like one: Wrong parallels Format Extension magic: 0xaaaaaaaaaaaaaaaa, expected: 0xab234cef23dcea87
Repairing image was not closed correctly
Repairing space leaked at the end of the image 1048576
wrote 65536/65536 bytes at offset 0
diff --git a/util/error-report.c b/util/error-report.c
index 8932beebfb9f..451ee2af4599 100644
--- a/util/error-report.c
+++ b/util/error-report.c
@@ -185,7 +185,7 @@ static void print_loc(MonitorHMP *hmp)
int i;
const char *const *argp;
- if (!hmp && g_get_prgname()) {
+ if (!hmp && g_get_prgname() && *g_get_prgname()) {
fprintf(stderr, "%s:", g_get_prgname());
sep = " ";
}
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* Re: [PATCH 05/88] qemu-io: drop "qemu-io:" prefix in error-report
2026-09-22 20:17 ` [PATCH 05/88] qemu-io: drop "qemu-io:" prefix in error-report Marc-André Lureau
@ 2026-09-22 21:04 ` Vladimir Sementsov-Ogievskiy
0 siblings, 0 replies; 98+ messages in thread
From: Vladimir Sementsov-Ogievskiy @ 2026-09-22 21:04 UTC (permalink / raw)
To: Marc-André Lureau, qemu-devel
Cc: Kevin Wolf, Hanna Reitz, Eric Blake, Markus Armbruster,
qemu-block
On 22.09.26 23:17, Marc-André Lureau wrote:
> qemu-io is still primarily an interactive program, and constantly
> printing the name of the program you're interacting with has little
> value.
>
> Suggested-by: Kevin Wolf<kwolf@redhat.com>
> Signed-off-by: Marc-André Lureau<marcandre.lureau@redhat.com>
Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>
--
Best regards,
Vladimir
^ permalink raw reply [flat|nested] 98+ messages in thread
* [PATCH 06/88] monitor: allow a bare Monitor
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (4 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 05/88] qemu-io: drop "qemu-io:" prefix in error-report Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 07/88] qemu-print: use monitor_puts() for any non-QMP monitor Marc-André Lureau
` (83 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel
Cc: Kevin Wolf, Marc-André Lureau, Dr. David Alan Gilbert,
Markus Armbruster
For qemu-io commands, we want to capture qemu_printf() output. Let's
allow to instantiate a bare monitor and steal its output.
We move UserCreatable to the leaf HMP & QMP monitors, to only allow
-object on these.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
include/monitor/monitor.h | 2 ++
monitor/hmp.c | 12 ++++--------
monitor/monitor.c | 28 ++++++++++++++++------------
monitor/qmp.c | 12 ++++--------
4 files changed, 26 insertions(+), 28 deletions(-)
diff --git a/include/monitor/monitor.h b/include/monitor/monitor.h
index 2a550aec023f..e8216b2f4cbf 100644
--- a/include/monitor/monitor.h
+++ b/include/monitor/monitor.h
@@ -29,6 +29,7 @@ void monitor_new_qmp(const char *id, const char *chardev_id,
bool pretty, Error **errp);
int monitor_new(MonitorOptions *opts, bool allow_hmp, Error **errp);
int monitor_new_opts(QemuOpts *opts, Error **errp);
+bool monitor_complete(Monitor *mon, Error **errp);
void monitor_cleanup(void);
void monitor_suspend(Monitor *mon);
@@ -39,6 +40,7 @@ int monitor_fd_param(Monitor *mon, const char *fdname, Error **errp);
int monitor_puts(Monitor *mon, const char *str);
void monitor_flush(Monitor *mon);
+GString *monitor_steal_output(Monitor *mon);
int monitor_puts_locked(Monitor *mon, const char *str);
void monitor_flush_locked(Monitor *mon);
diff --git a/monitor/hmp.c b/monitor/hmp.c
index 488ec23937df..53d84d160992 100644
--- a/monitor/hmp.c
+++ b/monitor/hmp.c
@@ -46,7 +46,9 @@
#include "system/block-backend.h"
#include "trace.h"
-OBJECT_DEFINE_TYPE(MonitorHMP, monitor_hmp, MONITOR_HMP, MONITOR);
+OBJECT_DEFINE_TYPE_WITH_INTERFACES(MonitorHMP, monitor_hmp,
+ MONITOR_HMP, MONITOR,
+ { TYPE_USER_CREATABLE });
MonitorHMP *monitor_cur_hmp(void)
{
@@ -1629,17 +1631,11 @@ void monitor_new_hmp(const char *id, const char *chardev_id,
static void monitor_hmp_complete(UserCreatable *uc, Error **errp)
{
MonitorHMP *hmp = MONITOR_HMP(uc);
- UserCreatableClass *ucc_parent =
- USER_CREATABLE_CLASS(
- object_class_get_parent(
- OBJECT_CLASS(MONITOR_HMP_GET_CLASS(hmp))));
ERRP_GUARD();
- ucc_parent->complete(uc, errp);
- if (*errp) {
+ if (!monitor_complete(MONITOR(uc), errp)) {
return;
}
-
if (hmp->parent_obj.chardev_id) {
if (hmp->use_readline) {
hmp->rs = readline_init(monitor_readline_printf,
diff --git a/monitor/monitor.c b/monitor/monitor.c
index 2654b81890dd..ee462cade7d1 100644
--- a/monitor/monitor.c
+++ b/monitor/monitor.c
@@ -79,8 +79,7 @@ static bool monitor_destroyed;
int monitor_device_index;
-OBJECT_DEFINE_TYPE_EXTENDED(Monitor, monitor, MONITOR, OBJECT, true,
- { TYPE_USER_CREATABLE }, {});
+OBJECT_DEFINE_TYPE(Monitor, monitor, MONITOR, OBJECT)
static void monitor_finalize(Object *obj)
{
@@ -110,17 +109,11 @@ static void monitor_set_chardev_id(Object *obj, const char *str, Error **errp)
mon->chardev_id = g_strdup(str);
}
-static void monitor_complete(UserCreatable *uc, Error **errp);
-
static void monitor_class_init(ObjectClass *cls, const void *data)
{
- UserCreatableClass *ucc = USER_CREATABLE_CLASS(cls);
-
object_class_property_add_str(cls, "chardev",
monitor_get_chardev_id,
monitor_set_chardev_id);
-
- ucc->complete = monitor_complete;
}
static void monitor_init(Object *obj)
@@ -273,6 +266,16 @@ int monitor_puts(Monitor *mon, const char *str)
return monitor_puts_locked(mon, str);
}
+GString *monitor_steal_output(Monitor *mon)
+{
+ GString *output;
+
+ QEMU_LOCK_GUARD(&mon->mon_lock);
+ output = mon->outbuf;
+ mon->outbuf = g_string_new(NULL);
+ return output;
+}
+
static MonitorQAPIEventConf monitor_qapi_event_conf[QAPI_EVENT__MAX] = {
/* Limit guest-triggerable events to 1 per second */
[QAPI_EVENT_RTC_CHANGE] = { 1000 * SCALE_MS },
@@ -658,20 +661,20 @@ char *monitor_compat_id(void)
return g_strdup_printf("compat_monitor%d", monitor_device_index++);
}
-static void monitor_complete(UserCreatable *uc, Error **errp)
+bool monitor_complete(Monitor *mon, Error **errp)
{
- Monitor *mon = MONITOR(uc);
AioContext *ctx;
+ assert(!mon->accept_input_bh);
if (mon->chardev_id) {
Chardev *chr = qemu_chr_find(mon->chardev_id);
if (chr == NULL) {
error_setg(errp, "chardev \"%s\" not found", mon->chardev_id);
- return;
+ return false;
}
if (!qemu_chr_fe_init(&mon->chr, chr, errp)) {
- return;
+ return false;
}
}
@@ -685,6 +688,7 @@ static void monitor_complete(UserCreatable *uc, Error **errp)
ctx = qemu_get_aio_context();
}
mon->accept_input_bh = aio_bh_new(ctx, monitor_accept_input, mon);
+ return true;
}
int monitor_new(MonitorOptions *opts, bool allow_hmp, Error **errp)
diff --git a/monitor/qmp.c b/monitor/qmp.c
index aec03157750c..00126ae0983c 100644
--- a/monitor/qmp.c
+++ b/monitor/qmp.c
@@ -77,7 +77,9 @@ QmpCommandList qmp_commands, qmp_cap_negotiation_commands;
/* Monitor being serviced by the dispatcher. Protected by BQL. */
static MonitorQMP *qmp_dispatcher_current_mon;
-OBJECT_DEFINE_TYPE(MonitorQMP, monitor_qmp, MONITOR_QMP, MONITOR);
+OBJECT_DEFINE_TYPE_WITH_INTERFACES(MonitorQMP, monitor_qmp,
+ MONITOR_QMP, MONITOR,
+ { TYPE_USER_CREATABLE });
static void monitor_qmp_cleanup_req_queue_locked(MonitorQMP *mon);
@@ -704,17 +706,11 @@ void monitor_new_qmp(const char *id, const char *chardev_id,
static void monitor_qmp_complete(UserCreatable *uc, Error **errp)
{
MonitorQMP *mon = MONITOR_QMP(uc);
- UserCreatableClass *ucc_parent =
- USER_CREATABLE_CLASS(
- object_class_get_parent(
- OBJECT_CLASS(MONITOR_QMP_GET_CLASS(mon))));
ERRP_GUARD();
- ucc_parent->complete(uc, errp);
- if (*errp) {
+ if (!monitor_complete(MONITOR(uc), errp)) {
return;
}
-
qemu_chr_fe_set_echo(&mon->parent_obj.chr, true);
if (monitor_requires_iothread(MONITOR(mon))) {
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 07/88] qemu-print: use monitor_puts() for any non-QMP monitor
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (5 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 06/88] monitor: allow a bare Monitor Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 08/88] block/monitor: capture x-qemu-io output Marc-André Lureau
` (82 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel
Cc: Kevin Wolf, Marc-André Lureau, Paolo Bonzini,
Dr. David Alan Gilbert
Instead of requiring a MonitorHMP and going through
monitor_hmp_vprintf(), use monitor_puts() on the base Monitor class.
This allows qemu_printf() to work with any monitor type that
isn't QMP, which will be needed to capture output via a bare
Monitor used as a buffer.
Add monitor_puts() since qemu_printf() is in libqemuutil.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
stubs/meson.build | 1 +
stubs/monitor-puts.c | 9 +++++++++
util/qemu-print.c | 16 +++++-----------
3 files changed, 15 insertions(+), 11 deletions(-)
diff --git a/stubs/meson.build b/stubs/meson.build
index 29b6644b2549..52c733e32a91 100644
--- a/stubs/meson.build
+++ b/stubs/meson.build
@@ -9,6 +9,7 @@ stub_ss.add(files('is-daemonized.c'))
stub_ss.add(files('monitor-core.c'))
stub_ss.add(files('monitor-cur.c'))
stub_ss.add(files('monitor-hmp.c'))
+stub_ss.add(files('monitor-puts.c'))
stub_ss.add(files('qapi-event-emit.c'))
stub_ss.add(files('replay-mode.c'))
stub_ss.add(files('trace-control.c'))
diff --git a/stubs/monitor-puts.c b/stubs/monitor-puts.c
new file mode 100644
index 000000000000..c4cf4f632845
--- /dev/null
+++ b/stubs/monitor-puts.c
@@ -0,0 +1,9 @@
+/* SPDX-License-Identifier: GPL-2.0-or-later */
+
+#include "qemu/osdep.h"
+#include "monitor/monitor.h"
+
+int monitor_puts(Monitor *mon, const char *str)
+{
+ abort();
+}
diff --git a/util/qemu-print.c b/util/qemu-print.c
index ab09dd8600ec..323789f265f9 100644
--- a/util/qemu-print.c
+++ b/util/qemu-print.c
@@ -19,25 +19,19 @@
/*
* Print like vprintf().
* Print to current monitor if we have one, else to stdout.
- * (if the monitor is QMP, fail without printing anything)
+ * QMP monitors are rejected (return -1) since they don't accept
+ * free-form text output.
*/
int qemu_vprintf(const char *fmt, va_list ap)
{
Monitor *cur_mon = monitor_cur();
- /* for all monitors: QMP & HMP */
if (cur_mon) {
-#ifdef CONFIG_HMP
- /* don't use monitor_cur_hmp(), to avoid a second lookup */
- MonitorHMP *hmp = (MonitorHMP *)
- object_dynamic_cast(OBJECT(cur_mon), TYPE_MONITOR_HMP);
- if (!hmp) {
+ if (object_dynamic_cast(OBJECT(cur_mon), TYPE_MONITOR_QMP)) {
return -1;
}
- return monitor_hmp_vprintf(hmp, fmt, ap);
-#else
- return -1;
-#endif
+ g_autofree char *buf = g_strdup_vprintf(fmt, ap);
+ return monitor_puts(cur_mon, buf);
}
return vprintf(fmt, ap);
}
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 08/88] block/monitor: capture x-qemu-io output
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (6 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 07/88] qemu-print: use monitor_puts() for any non-QMP monitor Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 09/88] qemu-iotests/iotests: filter x-qemu-io messages Marc-André Lureau
` (81 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel
Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, Eric Blake,
Markus Armbruster, Fabiano Rosas, Laurent Vivier, Paolo Bonzini,
qemu-block
Use a bare monitor to capture qemuio_command() printf output. Return it
as HumanReadableText.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
block/monitor/block-hmp-cmds.c | 14 +++++---
block/monitor/qmp-cmds.c | 49 +++++++++++++++++++++++-----
qapi/block.json | 3 ++
qemu-io-cmds.c | 74 ++++++++++++++++++++++--------------------
system/qtest.c | 4 ++-
tests/qemu-iotests/iotests.py | 2 +-
6 files changed, 95 insertions(+), 51 deletions(-)
diff --git a/block/monitor/block-hmp-cmds.c b/block/monitor/block-hmp-cmds.c
index 7bae4d425c6d..ed071c0f4144 100644
--- a/block/monitor/block-hmp-cmds.c
+++ b/block/monitor/block-hmp-cmds.c
@@ -543,12 +543,18 @@ void hmp_qemu_io(MonitorHMP *hmp, const QDict *qdict)
bool qdev = qdict_get_try_bool(qdict, "qdev", false);
const char *device = qdict_get_str(qdict, "device");
const char *command = qdict_get_str(qdict, "command");
+ g_autoptr(HumanReadableText) out = NULL;
Error *err = NULL;
- qmp_x_qemu_io(qdev ? NULL : device,
- qdev ? device : NULL,
- command, &err);
- hmp_handle_error(hmp, err);
+ out = qmp_x_qemu_io(qdev ? NULL : device,
+ qdev ? device : NULL,
+ command, &err);
+ if (hmp_handle_error(hmp, err)) {
+ return;
+ }
+
+ /* use stdout and not monitor_puts() for compatiblity reasons */
+ printf("%s", out->human_readable_text);
}
static void print_block_info(MonitorHMP *hmp, BlockInfo *info,
diff --git a/block/monitor/qmp-cmds.c b/block/monitor/qmp-cmds.c
index e5759d824f13..4ea4d5985833 100644
--- a/block/monitor/qmp-cmds.c
+++ b/block/monitor/qmp-cmds.c
@@ -5,44 +5,51 @@
#include "block/block_int.h"
#include "qapi/qapi-commands-block.h"
#include "qapi/error.h"
+#include "qapi/type-helpers.h"
+#include "monitor/monitor.h"
#include "qemu-io.h"
-void qmp_x_qemu_io(const char *device, const char *qdev,
- const char *command, Error **errp)
+HumanReadableText *qmp_x_qemu_io(const char *device, const char *qdev,
+ const char *command, Error **errp)
{
+ ERRP_GUARD();
BlockBackend *blk = NULL;
BlockBackend *local_blk = NULL;
BlockDriverState *bs = NULL;
- int ret;
+ g_autoptr(Monitor) capture_mon = NULL;
+ g_autoptr(GString) str = NULL;
+ Monitor *old_mon = NULL;
+ HumanReadableText *ret = NULL;
+ int r;
if (!device && !qdev) {
error_setg(errp, "Must specify either device or qdev");
- return;
+ return NULL;
}
if (qdev && device) {
error_setg(errp, "Cannot specify both qdev and device");
- return;
+ return NULL;
}
if (qdev) {
blk = blk_by_qdev_id(qdev, errp);
if (!blk) {
- return;
+ return NULL;
}
} else {
blk = blk_by_name(device);
if (!blk) {
bs = bdrv_lookup_bs(NULL, device, errp);
if (!bs) {
- return;
+ return NULL;
}
}
}
if (bs) {
blk = local_blk = blk_new(bdrv_get_aio_context(bs), 0, BLK_PERM_ALL);
- ret = blk_insert_bs(blk, bs, errp);
- if (ret < 0) {
+ r = blk_insert_bs(blk, bs, errp);
+ if (r < 0) {
goto fail;
}
}
@@ -72,8 +79,32 @@ void qmp_x_qemu_io(const char *device, const char *qdev,
* extended, possibly resulting in a read-only guest device keeping write
* permissions. Ugly, but it appears to be the lesser evil.
*/
+
+ /*
+ * qemuio_command() doesn't return structured output, so we need
+ * to capture the monitor output, use a bare monitor for that.
+ */
+ capture_mon = MONITOR(object_new(TYPE_MONITOR));
+ old_mon = monitor_set_cur(qemu_coroutine_self(), capture_mon);
+
qemuio_command(blk, command, errp);
+ monitor_set_cur(qemu_coroutine_self(), old_mon);
+
+ if (*errp) {
+ goto fail;
+ }
+
+ str = monitor_steal_output(capture_mon);
+
+ /*
+ * monitor_puts_locked() adds \r before \n for terminal display;
+ * strip those from captured output
+ */
+ g_string_replace(str, "\r", "", 0);
+ ret = human_readable_text_from_str(str);
+
fail:
blk_unref(local_blk);
+ return ret;
}
diff --git a/qapi/block.json b/qapi/block.json
index 012a9d73333b..da135f419386 100644
--- a/qapi/block.json
+++ b/qapi/block.json
@@ -618,6 +618,8 @@
#
# @command: the qemu-io command string to execute.
#
+# Returns: qemu-io output as a string
+#
# Features:
#
# @unstable: This command is for testing only.
@@ -635,5 +637,6 @@
'data': { '*device': 'str',
'*qdev': 'str',
'command': 'str' },
+ 'returns': 'HumanReadableText',
'features': [ 'unstable' ],
'allow-preconfig': true }
diff --git a/qemu-io-cmds.c b/qemu-io-cmds.c
index aa795fd87a14..28b810c25e58 100644
--- a/qemu-io-cmds.c
+++ b/qemu-io-cmds.c
@@ -17,6 +17,7 @@
#include "block/block_int.h" /* for info_f() */
#include "block/qapi.h"
#include "qemu/error-report.h"
+#include "qemu/qemu-print.h"
#include "qemu/main-loop.h"
#include "qemu/option.h"
#include "qemu/timer.h"
@@ -52,7 +53,7 @@ void qemuio_add_command(const cmdinfo_t *ci)
void qemuio_command_usage(const cmdinfo_t *ci)
{
- printf("%s %s -- %s\n", ci->name, ci->args, ci->oneline);
+ qemu_printf("%s %s -- %s\n", ci->name, ci->args, ci->oneline);
}
static int init_check_command(BlockBackend *blk, const cmdinfo_t *ct,
@@ -453,19 +454,19 @@ static void dump_buffer(const void *buffer, int64_t offset, int64_t len)
for (i = 0, p = buffer; i < len; i += 16) {
const uint8_t *s = p;
- printf("%08" PRIx64 ": ", offset + i);
+ qemu_printf("%08" PRIx64 ": ", offset + i);
for (j = 0; j < 16 && i + j < len; j++, p++) {
- printf("%02x ", *p);
+ qemu_printf("%02x ", *p);
}
- printf(" ");
+ qemu_printf(" ");
for (j = 0; j < 16 && i + j < len; j++, s++) {
if (isalnum(*s)) {
- printf("%c", *s);
+ qemu_printf("%c", *s);
} else {
- printf(".");
+ qemu_printf(".");
}
}
- printf("\n");
+ qemu_printf("\n");
}
}
@@ -478,12 +479,12 @@ static void print_report(const char *op, struct timespec *t, int64_t offset,
if (!Cflag) {
cvtstr((double)total, s1, sizeof(s1));
cvtstr(tdiv((double)total, *t), s2, sizeof(s2));
- printf("%s %"PRId64"/%"PRId64" bytes at offset %" PRId64 "\n",
+ qemu_printf("%s %"PRId64"/%"PRId64" bytes at offset %" PRId64 "\n",
op, total, count, offset);
- printf("%s, %d ops; %s (%s/sec and %.4f ops/sec)\n",
+ qemu_printf("%s, %d ops; %s (%s/sec and %.4f ops/sec)\n",
s1, cnt, ts, s2, tdiv((double)cnt, *t));
} else {/* bytes,ops,time,bytes/sec,ops/sec */
- printf("%"PRId64",%d,%s,%.3f,%.3f\n",
+ qemu_printf("%"PRId64",%d,%s,%.3f,%.3f\n",
total, cnt, ts,
tdiv((double)total, *t),
tdiv((double)cnt, *t));
@@ -674,7 +675,7 @@ static int do_aio_writev(BlockBackend *blk, QEMUIOVector *qiov,
static void read_help(void)
{
- printf(
+ qemu_printf(
"\n"
" reads a range of bytes from the given offset\n"
"\n"
@@ -877,7 +878,7 @@ out:
static void readv_help(void)
{
- printf(
+ qemu_printf(
"\n"
" reads a range of bytes from the given offset into multiple buffers\n"
"\n"
@@ -1012,7 +1013,7 @@ out:
static void write_help(void)
{
- printf(
+ qemu_printf(
"\n"
" writes a range of bytes from the given offset\n"
"\n"
@@ -1239,7 +1240,7 @@ out:
static void
writev_help(void)
{
- printf(
+ qemu_printf(
"\n"
" writes a range of bytes from the given offset source from multiple buffers\n"
"\n"
@@ -1449,7 +1450,7 @@ out:
static void aio_read_help(void)
{
- printf(
+ qemu_printf(
"\n"
" asynchronously reads a range of bytes from the given offset\n"
"\n"
@@ -1504,7 +1505,7 @@ static int aio_read_f(BlockBackend *blk, int argc, char **argv, Error **errp)
}
break;
case 'i':
- printf("injecting invalid read request\n");
+ qemu_printf("injecting invalid read request\n");
block_acct_invalid(blk_get_stats(blk), BLOCK_ACCT_READ);
g_free(ctx);
return 0;
@@ -1558,7 +1559,7 @@ static int aio_read_f(BlockBackend *blk, int argc, char **argv, Error **errp)
static void aio_write_help(void)
{
- printf(
+ qemu_printf(
"\n"
" asynchronously writes a range of bytes from the given offset source\n"
" from multiple buffers\n"
@@ -1629,7 +1630,7 @@ static int aio_write_f(BlockBackend *blk, int argc, char **argv, Error **errp)
}
break;
case 'i':
- printf("injecting invalid write request\n");
+ qemu_printf("injecting invalid write request\n");
block_acct_invalid(blk_get_stats(blk), BLOCK_ACCT_WRITE);
g_free(ctx);
return 0;
@@ -1780,7 +1781,7 @@ static int zone_report_f(BlockBackend *blk, int argc, char **argv, Error **errp)
error_setg(errp, "zone report failed: %s", strerror(-ret));
} else {
for (int i = 0; i < nr_zones; ++i) {
- printf("start: 0x%" PRIx64 ", len 0x%" PRIx64 ", "
+ qemu_printf("start: 0x%" PRIx64 ", len 0x%" PRIx64 ", "
"cap"" 0x%" PRIx64 ", wptr 0x%" PRIx64 ", "
"zcond:%u, [type: %u]\n",
tosector(zones[i].start), tosector(zones[i].length),
@@ -1986,7 +1987,7 @@ static int zone_append_f(BlockBackend *blk, int argc, char **argv, Error **errp)
}
if (pflag) {
- printf("After zap done, the append sector is 0x%" PRIx64 "\n",
+ qemu_printf("After zap done, the append sector is 0x%" PRIx64 "\n",
tosector(offset));
}
@@ -2072,7 +2073,7 @@ static int length_f(BlockBackend *blk, int argc, char **argv, Error **errp)
}
cvtstr(size, s1, sizeof(s1));
- printf("%s\n", s1);
+ qemu_printf("%s\n", s1);
return 0;
}
@@ -2098,10 +2099,10 @@ static int info_f(BlockBackend *blk, int argc, char **argv, Error **errp)
GRAPH_RDLOCK_GUARD_MAINLOOP();
if (bs->drv && bs->drv->format_name) {
- printf("format name: %s\n", bs->drv->format_name);
+ qemu_printf("format name: %s\n", bs->drv->format_name);
}
if (bs->drv && bs->drv->protocol_name) {
- printf("format name: %s\n", bs->drv->protocol_name);
+ qemu_printf("format name: %s\n", bs->drv->protocol_name);
}
ret = bdrv_get_info(bs, &bdi);
@@ -2112,8 +2113,8 @@ static int info_f(BlockBackend *blk, int argc, char **argv, Error **errp)
cvtstr(bdi.cluster_size, s1, sizeof(s1));
cvtstr(bdi.vm_state_offset, s2, sizeof(s2));
- printf("cluster size: %s\n", s1);
- printf("vm state offset: %s\n", s2);
+ qemu_printf("cluster size: %s\n", s1);
+ qemu_printf("vm state offset: %s\n", s2);
spec_info = bdrv_get_specific_info(bs, errp);
if (*errp) {
@@ -2140,7 +2141,7 @@ static const cmdinfo_t info_cmd = {
static void discard_help(void)
{
- printf(
+ qemu_printf(
"\n"
" discards a range of bytes from the given offset\n"
"\n"
@@ -2230,7 +2231,7 @@ static int discard_f(BlockBackend *blk, int argc, char **argv, Error **errp)
static void aio_discard_help(void)
{
- printf(
+ qemu_printf(
"\n"
" asynchronously discards a range of bytes from the given offset\n"
"\n"
@@ -2388,7 +2389,7 @@ static int alloc_f(BlockBackend *blk, int argc, char **argv, Error **errp)
cvtstr(start, s1, sizeof(s1));
- printf("%"PRId64"/%"PRId64" bytes allocated at offset %s\n",
+ qemu_printf("%"PRId64"/%"PRId64" bytes allocated at offset %s\n",
sum_alloc, count, s1);
return 0;
}
@@ -2462,8 +2463,9 @@ static int map_f(BlockBackend *blk, int argc, char **argv, Error **errp)
retstr = ret ? " allocated" : "not allocated";
cvtstr(num, s1, sizeof(s1));
cvtstr(offset, s2, sizeof(s2));
- printf("%s (0x%" PRIx64 ") bytes %s at offset %s (0x%" PRIx64 ")\n",
- s1, num, retstr, s2, offset);
+ qemu_printf("%s (0x%" PRIx64 ") bytes %s"
+ " at offset %s (0x%" PRIx64 ")\n",
+ s1, num, retstr, s2, offset);
offset += num;
bytes -= num;
@@ -2483,7 +2485,7 @@ static const cmdinfo_t map_cmd = {
static void reopen_help(void)
{
- printf(
+ qemu_printf(
"\n"
" Changes the open options of an already opened image\n"
"\n"
@@ -2729,7 +2731,7 @@ static const cmdinfo_t abort_cmd = {
static void sigraise_help(void)
{
- printf(
+ qemu_printf(
"\n"
" raises the given signal\n"
"\n"
@@ -2819,12 +2821,12 @@ static const cmdinfo_t sleep_cmd = {
static void help_oneline(const char *cmd, const cmdinfo_t *ct)
{
- printf("%s ", cmd);
+ qemu_printf("%s ", cmd);
if (ct->args) {
- printf("%s ", ct->args);
+ qemu_printf("%s ", ct->args);
}
- printf("-- %s\n", ct->oneline);
+ qemu_printf("-- %s\n", ct->oneline);
}
static void help_onecmd(const char *cmd, const cmdinfo_t *ct)
@@ -2842,7 +2844,7 @@ static void help_all(void)
for (ct = cmdtab; ct < &cmdtab[ncmds]; ct++) {
help_oneline(ct->name, ct);
}
- printf("\nUse 'help commandname' for extended help.\n");
+ qemu_printf("\nUse 'help commandname' for extended help.\n");
}
static int help_f(BlockBackend *blk, int argc, char **argv, Error **errp)
diff --git a/system/qtest.c b/system/qtest.c
index 47c954838dd0..e07c7acf34fc 100644
--- a/system/qtest.c
+++ b/system/qtest.c
@@ -801,13 +801,15 @@ static void qtest_process_command(CharFrontend *chr, gchar **words)
} else if (strcmp(words[0], "qemu-io") == 0) {
const char *io_dev;
g_autofree char *io_cmd = NULL;
+ /* ignore multi-line output for now */
+ g_autoptr(HumanReadableText) out = NULL;
Error *err = NULL;
g_assert(words[1] && words[2]);
io_dev = words[1];
io_cmd = g_strjoinv(" ", &words[2]);
- qmp_x_qemu_io(io_dev, NULL, io_cmd, &err);
+ out = qmp_x_qemu_io(io_dev, NULL, io_cmd, &err);
qtest_sendf(chr, err ? "FAIL %s\n" : "OK\n",
err ? error_get_pretty(err) : NULL);
error_free(err);
diff --git a/tests/qemu-iotests/iotests.py b/tests/qemu-iotests/iotests.py
index 7d5a77a85e58..445a22a8659a 100644
--- a/tests/qemu-iotests/iotests.py
+++ b/tests/qemu-iotests/iotests.py
@@ -965,7 +965,7 @@ def qmp_qemu_io(self, drive: str, cmd: str,
res = self.qmp_log('x-qemu-io', **kwargs)
else:
res = self.qmp('x-qemu-io', **kwargs)
- return res.get('error', {}).get('desc', '')
+ return res.get('return', {}).get('human-readable-text', '')
def flatten_qmp_object(self, obj, output=None, basestr=''):
if output is None:
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 09/88] qemu-iotests/iotests: filter x-qemu-io messages
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (7 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 08/88] block/monitor: capture x-qemu-io output Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 10/88] tests/qemu-iotests: do no interpret backslash as escape Marc-André Lureau
` (80 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/iotests.py | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/tests/qemu-iotests/iotests.py b/tests/qemu-iotests/iotests.py
index 445a22a8659a..5d9b5ded64ac 100644
--- a/tests/qemu-iotests/iotests.py
+++ b/tests/qemu-iotests/iotests.py
@@ -708,6 +708,13 @@ def _filter(_key, value):
return value
return filter_qmp(qmsg, _filter)
+def filter_x_qemu_io(qmsg):
+ def _filter(_key, value):
+ if is_str(value):
+ return filter_qemu_io(value)
+ return value
+ return filter_qmp(qmsg, _filter)
+
def filter_nbd_exports(output: str) -> str:
return re.sub(r'((min|opt|max) block): [0-9]+', r'\1: XXX', output)
@@ -962,7 +969,8 @@ def qmp_qemu_io(self, drive: str, cmd: str,
else:
kwargs['device'] = drive
if use_log:
- res = self.qmp_log('x-qemu-io', **kwargs)
+ res = self.qmp_log('x-qemu-io',
+ filters=(filter_x_qemu_io,), **kwargs)
else:
res = self.qmp('x-qemu-io', **kwargs)
return res.get('return', {}).get('human-readable-text', '')
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 10/88] tests/qemu-iotests: do no interpret backslash as escape
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (8 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 09/88] qemu-iotests/iotests: filter x-qemu-io messages Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 11/88] tests/qemu-iotests: filter all generated node ids Marc-André Lureau
` (79 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
\n in the JSON becomes just n. Fix read command output using -r.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/common.qemu | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tests/qemu-iotests/common.qemu b/tests/qemu-iotests/common.qemu
index 0f1fecc68edf..e5b6a6a87494 100644
--- a/tests/qemu-iotests/common.qemu
+++ b/tests/qemu-iotests/common.qemu
@@ -90,7 +90,7 @@ _timed_wait_for()
read_timeout=
fi
- while IFS= read ${read_timeout} resp <&${QEMU_OUT[$h]}
+ while IFS= read -r ${read_timeout} resp <&${QEMU_OUT[$h]}
do
if [ -n "$capture_events" ]; then
capture=0
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 11/88] tests/qemu-iotests: filter all generated node ids
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (9 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 10/88] tests/qemu-iotests: do no interpret backslash as escape Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 12/88] qemu-iotests/216: migrate away from HMP Marc-André Lureau
` (78 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/common.filter | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tests/qemu-iotests/common.filter b/tests/qemu-iotests/common.filter
index ce4213cb974a..f6d94f993691 100644
--- a/tests/qemu-iotests/common.filter
+++ b/tests/qemu-iotests/common.filter
@@ -32,7 +32,7 @@ _filter_vmstate_size()
_filter_generated_node_ids()
{
- sed -Ee 's/\#block[0-9]{3,}/NODE_NAME/'
+ sed -Ee 's/\#block[0-9]{3,}/NODE_NAME/g'
}
_filter_qom_path()
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 12/88] qemu-iotests/216: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (10 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 11/88] tests/qemu-iotests: filter all generated node ids Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 13/88] qemu-iotests/310: " Marc-André Lureau
` (77 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Log command, although this is not strictly needed.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/216 | 6 ++----
tests/qemu-iotests/216.out | 3 ++-
2 files changed, 4 insertions(+), 5 deletions(-)
diff --git a/tests/qemu-iotests/216 b/tests/qemu-iotests/216
index 4eabada9b35d..2d32b0f126ce 100755
--- a/tests/qemu-iotests/216
+++ b/tests/qemu-iotests/216
@@ -25,8 +25,7 @@ from iotests import log, qemu_img, qemu_io
# Need backing file support
iotests.script_initialize(supported_fmts=['qcow2', 'qcow', 'qed', 'vmdk'],
- supported_platforms=['linux'],
- require_hmp=True)
+ supported_platforms=['linux'])
log('')
log('=== Copy-on-read across nodes ===')
@@ -102,8 +101,7 @@ with iotests.FilePath('base.img') as base_img_path, \
}))
# Trigger COR
- log(vm.qmp('human-monitor-command',
- command_line='qemu-io node0 "read 0 64M"'))
+ vm.qmp_qemu_io('node0', 'read 0 64M', use_log=True)
vm.shutdown()
diff --git a/tests/qemu-iotests/216.out b/tests/qemu-iotests/216.out
index a70aa5cdaeb9..c2d8101e8858 100644
--- a/tests/qemu-iotests/216.out
+++ b/tests/qemu-iotests/216.out
@@ -8,7 +8,8 @@ Done
--- Doing COR ---
{"return": {}}
-{"return": ""}
+{"execute": "x-qemu-io", "arguments": {"command": "read 0 64M", "device": "node0"}}
+{"return": {"human-readable-text": "read 67108864/67108864 bytes at offset 0\n64 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
--- Checking COR result ---
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 13/88] qemu-iotests/310: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (11 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 12/88] qemu-iotests/216: migrate away from HMP Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 14/88] qemu-iotests/283: " Marc-André Lureau
` (76 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/310 | 6 ++----
tests/qemu-iotests/310.out | 3 ++-
2 files changed, 4 insertions(+), 5 deletions(-)
diff --git a/tests/qemu-iotests/310 b/tests/qemu-iotests/310
index 7f290898fea0..5ca59fda8706 100755
--- a/tests/qemu-iotests/310
+++ b/tests/qemu-iotests/310
@@ -25,8 +25,7 @@ from iotests import log, qemu_img, qemu_io
# Need backing file support
iotests.script_initialize(supported_fmts=['qcow2'],
- supported_platforms=['linux'],
- require_hmp=True)
+ supported_platforms=['linux'])
log('')
log('=== Copy-on-read across nodes ===')
@@ -96,8 +95,7 @@ with iotests.FilePath('base.img') as base_img_path, \
}))
# Trigger COR
- log(vm.qmp('human-monitor-command',
- command_line='qemu-io node0 "read 0 5M"'))
+ vm.qmp_qemu_io('node0', 'read 0 5M', use_log=True)
vm.shutdown()
diff --git a/tests/qemu-iotests/310.out b/tests/qemu-iotests/310.out
index a70aa5cdaeb9..b15bb93281eb 100644
--- a/tests/qemu-iotests/310.out
+++ b/tests/qemu-iotests/310.out
@@ -8,7 +8,8 @@ Done
--- Doing COR ---
{"return": {}}
-{"return": ""}
+{"execute": "x-qemu-io", "arguments": {"command": "read 0 5M", "device": "node0"}}
+{"return": {"human-readable-text": "read 5242880/5242880 bytes at offset 0\n5 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
--- Checking COR result ---
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 14/88] qemu-iotests/283: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (12 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 13/88] qemu-iotests/310: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 15/88] qemu-iotests/281: " Marc-André Lureau
` (75 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/283 | 4 +---
tests/qemu-iotests/283.out | 4 ++--
2 files changed, 3 insertions(+), 5 deletions(-)
diff --git a/tests/qemu-iotests/283 b/tests/qemu-iotests/283
index 6d341d3e9745..d06edcdd7ae8 100755
--- a/tests/qemu-iotests/283
+++ b/tests/qemu-iotests/283
@@ -24,7 +24,6 @@ import iotests
# The test is unrelated to formats, restrict it to qcow2 to avoid extra runs
iotests.script_initialize(
supported_fmts=['qcow2'],
- require_hmp=True,
)
size = 1024 * 1024
@@ -137,8 +136,7 @@ vm.event_wait('BLOCK_JOB_COMPLETED', 5.0)
# The filter should be gone now. Check that by trying to access it
# with qemu-io (which will most likely crash qemu if it is still
# there.).
-vm.qmp_log('human-monitor-command',
- command_line='qemu-io backup-filter "write 0 1M"')
+vm.qmp_log('x-qemu-io', device='backup-filter', command='write 0 1M')
# (Also, do an explicit check.)
assert vm.node_info('backup-filter') is None
diff --git a/tests/qemu-iotests/283.out b/tests/qemu-iotests/283.out
index 5e4f456db55c..1c12c8fad7df 100644
--- a/tests/qemu-iotests/283.out
+++ b/tests/qemu-iotests/283.out
@@ -17,7 +17,7 @@
{"return": {}}
{"execute": "job-finalize", "arguments": {"id": "backup"}}
{"return": {}}
-{"execute": "human-monitor-command", "arguments": {"command-line": "qemu-io backup-filter \"write 0 1M\""}}
-{"return": "Error: Cannot find device='' nor node-name='backup-filter'\r\n"}
+{"execute": "x-qemu-io", "arguments": {"command": "write 0 1M", "device": "backup-filter"}}
+{"error": {"class": "GenericError", "desc": "Cannot find device='' nor node-name='backup-filter'"}}
{"execute": "job-dismiss", "arguments": {"id": "backup"}}
{"return": {}}
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 15/88] qemu-iotests/281: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (13 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 14/88] qemu-iotests/283: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 16/88] qemu-iotests/reopen-file: " Marc-André Lureau
` (74 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/281 | 11 +++--------
1 file changed, 3 insertions(+), 8 deletions(-)
diff --git a/tests/qemu-iotests/281 b/tests/qemu-iotests/281
index 5f3050f50d0b..65d34b427a43 100755
--- a/tests/qemu-iotests/281
+++ b/tests/qemu-iotests/281
@@ -273,9 +273,7 @@ class TestYieldingAndTimers(iotests.QMPTestCase):
self.stop_nbd_export()
self.create_nbd_export()
- result = self.vm.qmp('human-monitor-command',
- command_line='qemu-io nbd "write 0 512"')
- self.assert_qmp(result, 'return', '')
+ self.vm.qmp_qemu_io('nbd', 'write 0 512')
# Reconnect is done, so the reconnect delay timer should be gone.
# (This is similar to how the open timer should be gone after open,
@@ -303,9 +301,7 @@ class TestYieldingAndTimers(iotests.QMPTestCase):
# Do some I/O that will be throttled by the QSD, so that the network
# connection hopefully will yield here. When it is resumed, it must
# then be resumed in the I/O thread's AioContext.
- result = self.vm.qmp('human-monitor-command',
- command_line='qemu-io nbd "read 0 128K"')
- self.assert_qmp(result, 'return', '')
+ self.vm.qmp_qemu_io('nbd', 'read 0 128K')
def create_nbd_export(self):
assert self.qsd is None
@@ -336,5 +332,4 @@ class TestYieldingAndTimers(iotests.QMPTestCase):
if __name__ == '__main__':
iotests.main(supported_fmts=['qcow2'],
supported_protocols=['file'],
- unsupported_imgopts=['compat'],
- require_hmp=True)
+ unsupported_imgopts=['compat'])
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 16/88] qemu-iotests/reopen-file: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (14 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 15/88] qemu-iotests/281: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 17/88] qemu-iotests/mirror-ready-cancel-error: " Marc-André Lureau
` (73 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/tests/reopen-file | 12 +++---------
1 file changed, 3 insertions(+), 9 deletions(-)
diff --git a/tests/qemu-iotests/tests/reopen-file b/tests/qemu-iotests/tests/reopen-file
index f8812320ea8f..98b0f9e98e73 100755
--- a/tests/qemu-iotests/tests/reopen-file
+++ b/tests/qemu-iotests/tests/reopen-file
@@ -72,18 +72,12 @@ class TestReopenFile(QMPTestCase):
# Do some I/O to the image to see whether it still works
# (Pattern verification will be checked by tearDown())
- result = self.vm.qmp('human-monitor-command',
- command_line='qemu-io format "write -P 42 0 64k"')
- self.assert_qmp(result, 'return', '')
-
- result = self.vm.qmp('human-monitor-command',
- command_line='qemu-io format "read -P 42 0 64k"')
- self.assert_qmp(result, 'return', '')
+ self.vm.qmp_qemu_io('format', 'write -P 42 0 64k')
+ self.vm.qmp_qemu_io('format', 'read -P 42 0 64k')
if __name__ == '__main__':
# Must support creating images and reopen
iotests.main(supported_fmts=['qcow', 'qcow2', 'qed', 'raw', 'vdi', 'vhdx',
'vmdk', 'vpc'],
- supported_protocols=['file'],
- require_hmp=True)
+ supported_protocols=['file'])
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 17/88] qemu-iotests/mirror-ready-cancel-error: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (15 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 16/88] qemu-iotests/reopen-file: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 18/88] qemu-iotests/copy-before-write: " Marc-André Lureau
` (72 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/tests/mirror-ready-cancel-error | 7 ++-----
1 file changed, 2 insertions(+), 5 deletions(-)
diff --git a/tests/qemu-iotests/tests/mirror-ready-cancel-error b/tests/qemu-iotests/tests/mirror-ready-cancel-error
index ffa045af2191..06ca8871327b 100755
--- a/tests/qemu-iotests/tests/mirror-ready-cancel-error
+++ b/tests/qemu-iotests/tests/mirror-ready-cancel-error
@@ -96,9 +96,7 @@ class TestMirrorReadyCancelError(iotests.QMPTestCase):
# Write something so will not leave the job immediately, but
# flush first (which will fail, thanks to blkdebug)
- res = self.vm.qmp('human-monitor-command',
- command_line='qemu-io mirror-top "write -P 2 0 64k"')
- self.assert_qmp(res, 'return', '')
+ self.vm.qmp_qemu_io('mirror-top', 'write -P 2 0 64k')
# Drain status change events
while self.vm.event_wait('JOB_STATUS_CHANGE', timeout=0.0) is not None:
@@ -139,5 +137,4 @@ if __name__ == '__main__':
# LUKS would require special key-secret handling in add_blockdevs()
iotests.main(supported_fmts=['generic'],
unsupported_fmts=['luks'],
- supported_protocols=['file'],
- require_hmp=True)
+ supported_protocols=['file'])
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 18/88] qemu-iotests/copy-before-write: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (16 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 17/88] qemu-iotests/mirror-ready-cancel-error: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 19/88] qemu-iotests/132: " Marc-André Lureau
` (71 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
This test doesn't use iotests.VM presumably because it sets up qtest,
conflicting with -machine none.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/tests/copy-before-write | 130 +++++++++++++----------------
1 file changed, 59 insertions(+), 71 deletions(-)
diff --git a/tests/qemu-iotests/tests/copy-before-write b/tests/qemu-iotests/tests/copy-before-write
index 5531ad8a4c0d..59ab96738d6d 100755
--- a/tests/qemu-iotests/tests/copy-before-write
+++ b/tests/qemu-iotests/tests/copy-before-write
@@ -32,6 +32,9 @@ size = '1M'
class TestCbwError(iotests.QMPTestCase):
+ def qemu_io_result(self, res):
+ return iotests.filter_qemu_io(res['return']['human-readable-text'])
+
def tearDown(self):
self.vm.shutdown()
os.remove(temp_img)
@@ -85,19 +88,14 @@ class TestCbwError(iotests.QMPTestCase):
'file': 'cbw'
})
- result = self.vm.qmp('human-monitor-command',
- command_line='qemu-io cbw "write 0 1M"')
- write_res = result['return']
-
- result = self.vm.qmp('human-monitor-command',
- command_line='qemu-io access "read 0 1M"')
- read_res = result['return']
+ write_res = self.vm.qmp('x-qemu-io', device='cbw',
+ command='write 0 1M')
+ read_res = self.vm.qmp('x-qemu-io', device='access',
+ command='read 0 1M')
self.vm.shutdown()
- log = self.vm.get_log()
- log = iotests.filter_qtest(log)
- log = iotests.filter_qemu_io(log)
- return log, write_res, read_res
+ self.assertEqual(self.vm.get_log(), '')
+ return write_res, read_res
def do_cbw_error_via_blockdev_backup(self, on_cbw_error=None):
self.vm.cmd('blockdev-add', {
@@ -148,43 +146,37 @@ class TestCbwError(iotests.QMPTestCase):
'file': 'cbw'
})
- result = self.vm.qmp('human-monitor-command',
- command_line='qemu-io cbw "write 0 1M"')
- write_res = result['return']
-
- result = self.vm.qmp('human-monitor-command',
- command_line='qemu-io access "read 0 1M"')
- read_res = result['return']
+ write_res = self.vm.qmp('x-qemu-io', device='cbw',
+ command='write 0 1M')
+ read_res = self.vm.qmp('x-qemu-io', device='access',
+ command='read 0 1M')
self.vm.shutdown()
- log = self.vm.get_log()
- log = iotests.filter_qemu_io(log)
- return log, write_res, read_res
+ self.assertEqual(self.vm.get_log(), '')
+ return write_res, read_res
def test_break_snapshot_on_cbw_error(self):
"""break-snapshot behavior:
Guest write succeed, but further snapshot-read fails, as snapshot is
broken.
"""
- log, write_res, read_res = self.do_cbw_error('break-snapshot')
- self.assertEqual(write_res, '')
- self.assertIn('read failed: Permission denied', read_res)
-
- self.assertEqual(log, """\
+ write_res, read_res = self.do_cbw_error('break-snapshot')
+ self.assertEqual(self.qemu_io_result(write_res), """\
wrote 1048576/1048576 bytes at offset 0
1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
""")
+ self.assertIn('read failed: Permission denied',
+ read_res['error']['desc'])
def test_break_guest_write_on_cbw_error(self):
"""break-guest-write behavior:
Guest write fails, but snapshot-access continues working and further
snapshot-read succeeds.
"""
- log, write_res, read_res = self.do_cbw_error('break-guest-write')
- self.assertIn('write failed: Input/output error', write_res)
- self.assertEqual(read_res, '')
-
- self.assertEqual(log, """\
+ write_res, read_res = self.do_cbw_error('break-guest-write')
+ self.assertIn('write failed: Input/output error',
+ write_res['error']['desc'])
+ self.assertEqual(self.qemu_io_result(read_res), """\
read 1048576/1048576 bytes at offset 0
1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
""")
@@ -193,24 +185,24 @@ read 1048576/1048576 bytes at offset 0
"""Ensure CBW filter accepts break-snapshot policy
specified in blockdev-backup QMP command.
"""
- log, write_res, read_res = \
+ write_res, read_res = \
self.do_cbw_error_via_blockdev_backup('break-snapshot')
- self.assertEqual(write_res, '')
- self.assertIn('read failed: Permission denied', read_res)
- self.assertEqual(log, """\
+ self.assertEqual(self.qemu_io_result(write_res), """\
wrote 1048576/1048576 bytes at offset 0
1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
""")
+ self.assertIn('read failed: Permission denied',
+ read_res['error']['desc'])
def test_break_guest_write_policy_forwarding(self):
"""Ensure CBW filter accepts break-guest-write policy
specified in blockdev-backup QMP command.
"""
- log, write_res, read_res = \
+ write_res, read_res = \
self.do_cbw_error_via_blockdev_backup('break-guest-write')
- self.assertIn('write failed: Input/output error', write_res)
- self.assertEqual(read_res, '')
- self.assertEqual(log, """\
+ self.assertIn('write failed: Input/output error',
+ write_res['error']['desc'])
+ self.assertEqual(self.qemu_io_result(read_res), """\
read 1048576/1048576 bytes at offset 0
1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
""")
@@ -219,11 +211,11 @@ read 1048576/1048576 bytes at offset 0
"""Ensure break-guest-write policy is used by default when
on-cbw-error is not explicitly specified.
"""
- log, write_res, read_res = \
+ write_res, read_res = \
self.do_cbw_error_via_blockdev_backup()
- self.assertIn('write failed: Input/output error', write_res)
- self.assertEqual(read_res, '')
- self.assertEqual(log, """\
+ self.assertIn('write failed: Input/output error',
+ write_res['error']['desc'])
+ self.assertEqual(self.qemu_io_result(read_res), """\
read 1048576/1048576 bytes at offset 0
1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
""")
@@ -266,60 +258,56 @@ read 1048576/1048576 bytes at offset 0
'file': 'cbw'
})
- result = self.vm.qmp('human-monitor-command',
- command_line='qemu-io cbw "write 0 512K"')
- write1_res = result['return']
+ write1_res = self.vm.qmp('x-qemu-io', device='cbw',
+ command='write 0 512K')
# We need second write to trigger throttling
- result = self.vm.qmp('human-monitor-command',
- command_line='qemu-io cbw "write 512K 512K"')
- write2_res = result['return']
-
- result = self.vm.qmp('human-monitor-command',
- command_line='qemu-io access "read 0 1M"')
- read_res = result['return']
+ write2_res = self.vm.qmp('x-qemu-io', device='cbw',
+ command='write 512K 512K')
+ read_res = self.vm.qmp('x-qemu-io', device='access',
+ command='read 0 1M')
self.vm.shutdown()
log = self.vm.get_log()
log = re.sub(r'^\[I \d+\.\d+\] OPENED\n', '', log)
log = re.sub(r'\[I \+\d+\.\d+\] CLOSED\n?$', '', log)
- log = iotests.filter_qemu_io(log)
- return log, write1_res, write2_res, read_res
+ self.assertEqual(log, '')
+ return write1_res, write2_res, read_res
def test_timeout_break_guest(self):
- log, write1_res, write2_res, read_res = \
+ write1_res, write2_res, read_res = \
self.do_cbw_timeout('break-guest-write')
- self.assertEqual(write1_res, '')
+ self.assertEqual(self.qemu_io_result(write1_res), """\
+wrote 524288/524288 bytes at offset 0
+512 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
+""")
# macOS and FreeBSD tend to represent ETIMEDOUT as
# "Operation timed out", when Linux prefer
# "Connection timed out"
- write2_res = write2_res.replace('Operation timed out',
- 'Connection timed out')
- self.assertIn('write failed: Connection timed out', write2_res)
- self.assertEqual(read_res, '')
- self.assertEqual(log, """\
-wrote 524288/524288 bytes at offset 0
-512 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
+ write2_err = write2_res['error']['desc'].replace(
+ 'Operation timed out', 'Connection timed out')
+ self.assertIn('write failed: Connection timed out', write2_err)
+ self.assertEqual(self.qemu_io_result(read_res), """\
read 1048576/1048576 bytes at offset 0
1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
""")
def test_timeout_break_snapshot(self):
- log, write1_res, write2_res, read_res = \
+ write1_res, write2_res, read_res = \
self.do_cbw_timeout('break-snapshot')
- self.assertEqual(write1_res, '')
- self.assertEqual(write2_res, '')
- self.assertIn('read failed: Permission denied', read_res)
- self.assertEqual(log, """\
+ self.assertEqual(self.qemu_io_result(write1_res), """\
wrote 524288/524288 bytes at offset 0
512 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
+""")
+ self.assertEqual(self.qemu_io_result(write2_res), """\
wrote 524288/524288 bytes at offset 524288
512 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
""")
+ self.assertIn('read failed: Permission denied',
+ read_res['error']['desc'])
if __name__ == '__main__':
iotests.main(supported_fmts=['qcow2'],
supported_protocols=['file'],
- required_fmts=['copy-before-write'],
- require_hmp=True)
+ required_fmts=['copy-before-write'])
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 19/88] qemu-iotests/132: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (17 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 18/88] qemu-iotests/copy-before-write: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 20/88] qemu-iotests/152: " Marc-André Lureau
` (70 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/132 | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/tests/qemu-iotests/132 b/tests/qemu-iotests/132
index 3756573a57c0..579f6a3bdd09 100755
--- a/tests/qemu-iotests/132
+++ b/tests/qemu-iotests/132
@@ -49,7 +49,7 @@ class TestSingleDrive(iotests.QMPTestCase):
def test_mirror_discard(self):
self.vm.cmd('drive-mirror', device='drive0', sync='full',
target=target_img)
- self.vm.hmp_qemu_io('drive0', 'discard 0 64k')
+ self.vm.qmp_qemu_io('drive0', 'discard 0 64k')
self.complete_and_wait('drive0')
self.vm.shutdown()
self.assertTrue(iotests.compare_images(test_img, target_img),
@@ -57,5 +57,4 @@ class TestSingleDrive(iotests.QMPTestCase):
if __name__ == '__main__':
iotests.main(supported_fmts=['raw', 'qcow2'],
- supported_protocols=['file'],
- require_hmp=True)
+ supported_protocols=['file'])
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 20/88] qemu-iotests/152: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (18 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 19/88] qemu-iotests/132: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 21/88] qemu-iotests/254: " Marc-André Lureau
` (69 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/152 | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/tests/qemu-iotests/152 b/tests/qemu-iotests/152
index d9170359213a..f25c706273a3 100755
--- a/tests/qemu-iotests/152
+++ b/tests/qemu-iotests/152
@@ -52,7 +52,7 @@ class TestUnaligned(iotests.QMPTestCase):
self.vm.cmd('drive-mirror', device='drive0', sync='full',
granularity=65536, target=target_img)
self.wait_ready()
- self.vm.hmp_qemu_io('drive0', 'write 0 512')
+ self.vm.qmp_qemu_io('drive0', 'write 0 512')
self.complete_and_wait(wait_ready=False)
self.vm.shutdown()
self.assertEqual(iotests.image_size(test_img), iotests.image_size(target_img),
@@ -61,5 +61,4 @@ class TestUnaligned(iotests.QMPTestCase):
if __name__ == '__main__':
iotests.main(supported_fmts=['raw', 'qcow2'],
- supported_protocols=['file'],
- require_hmp=True)
+ supported_protocols=['file'])
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 21/88] qemu-iotests/254: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (19 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 20/88] qemu-iotests/152: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 22/88] qemu-iotests/264: " Marc-André Lureau
` (68 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/254 | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/tests/qemu-iotests/254 b/tests/qemu-iotests/254
index d3d18a1bbf1f..0f49548b6226 100755
--- a/tests/qemu-iotests/254
+++ b/tests/qemu-iotests/254
@@ -24,7 +24,7 @@ from iotests import qemu_img_create, file_path, log
iotests.script_initialize(supported_fmts=['qcow2'],
unsupported_imgopts=['compat'],
- require_hmp=True)
+)
disk, top = file_path('disk', 'top')
size = 1024 * 1024
@@ -40,7 +40,7 @@ vm.qmp_log('block-dirty-bitmap-add', node='drive0', name='bitmap1',
vm.qmp_log('block-dirty-bitmap-add', node='drive0', name='bitmap2',
persistent=True)
-vm.hmp_qemu_io('drive0', 'write 0 512K')
+vm.qmp_qemu_io('drive0', 'write 0 512K')
vm.qmp_log('transaction', indent=2, actions=[
{'type': 'blockdev-snapshot-sync',
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 22/88] qemu-iotests/264: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (20 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 21/88] qemu-iotests/254: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 23/88] qemu-iotests/304: " Marc-André Lureau
` (67 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/264 | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/tests/qemu-iotests/264 b/tests/qemu-iotests/264
index b621f11ab427..4b1fb67e1b4b 100755
--- a/tests/qemu-iotests/264
+++ b/tests/qemu-iotests/264
@@ -38,7 +38,7 @@ class TestNbdReconnect(iotests.QMPTestCase):
qemu_img_create('-f', iotests.imgfmt, disk_b, str(disk_size))
self.vm = iotests.VM().add_drive(disk_a)
self.vm.launch()
- self.vm.hmp_qemu_io('drive0', 'write 0 {}'.format(disk_size))
+ self.vm.qmp_qemu_io('drive0', 'write 0 {}'.format(disk_size))
def tearDown(self):
self.vm.shutdown()
@@ -114,5 +114,4 @@ class TestNbdReconnect(iotests.QMPTestCase):
if __name__ == '__main__':
- iotests.main(supported_fmts=['qcow2'],
- require_hmp=True)
+ iotests.main(supported_fmts=['qcow2'])
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 23/88] qemu-iotests/304: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (21 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 22/88] qemu-iotests/264: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 24/88] qemu-iotests/300: replace hmp_qemu_io with qmp Marc-André Lureau
` (66 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/304 | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/tests/qemu-iotests/304 b/tests/qemu-iotests/304
index 03c7c1cbe3c8..2447fca99dbf 100755
--- a/tests/qemu-iotests/304
+++ b/tests/qemu-iotests/304
@@ -24,8 +24,7 @@ import iotests
from iotests import qemu_img_create, qemu_img_log, file_path
iotests.script_initialize(supported_fmts=['qcow2', 'parallels'],
- supported_protocols=['file'],
- require_hmp=True)
+ supported_protocols=['file'])
test_img = file_path('test.qcow2')
target_img = file_path('target.qcow2')
@@ -41,8 +40,8 @@ vm = iotests.VM().add_drive(test_img)
vm.launch()
# write to the entire image
-vm.hmp_qemu_io('drive0', 'write -P0x16 0 4096');
-vm.hmp_qemu_io('drive0', 'write -P0x17 4096 1');
+vm.qmp_qemu_io('drive0', 'write -P0x16 0 4096');
+vm.qmp_qemu_io('drive0', 'write -P0x17 4096 1');
# do backup and wait for completion
vm.qmp('drive-backup', **{
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 24/88] qemu-iotests/300: replace hmp_qemu_io with qmp
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (22 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 23/88] qemu-iotests/304: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 25/88] qemu-iotests/298: migrate away from HMP Marc-André Lureau
` (65 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
There is still HMP usage left, addressed later.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/300 | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tests/qemu-iotests/300 b/tests/qemu-iotests/300
index df2ba326327d..bcc6fa972581 100755
--- a/tests/qemu-iotests/300
+++ b/tests/qemu-iotests/300
@@ -57,7 +57,7 @@ class TestDirtyBitmapMigration(iotests.QMPTestCase):
# Dirty some random megabytes
for _ in range(9):
mb_ofs = random.randrange(1024)
- self.vm_a.hmp_qemu_io(self.src_node_name, f'discard {mb_ofs}M 1M')
+ self.vm_a.qmp_qemu_io(self.src_node_name, f'discard {mb_ofs}M 1M')
result = self.vm_a.qmp('x-debug-block-dirty-bitmap-sha256',
node=self.src_node_name,
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 25/88] qemu-iotests/298: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (23 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 24/88] qemu-iotests/300: replace hmp_qemu_io with qmp Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 26/88] qemu-iotests/056: " Marc-André Lureau
` (64 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/298 | 9 ++++-----
1 file changed, 4 insertions(+), 5 deletions(-)
diff --git a/tests/qemu-iotests/298 b/tests/qemu-iotests/298
index f2b94077f43a..7258ae6f141f 100755
--- a/tests/qemu-iotests/298
+++ b/tests/qemu-iotests/298
@@ -74,7 +74,7 @@ class TestPreallocateFilter(TestPreallocateBase):
super().tearDown()
def test_prealloc(self):
- self.vm.hmp_qemu_io('drive0', 'write 0 1M')
+ self.vm.qmp_qemu_io('drive0', 'write 0 1M')
self.check_big()
def test_external_snapshot(self):
@@ -87,7 +87,7 @@ class TestPreallocateFilter(TestPreallocateBase):
# on reopen to r-o base preallocation should be dropped
self.check_small()
- self.vm.hmp_qemu_io('drive0', 'write 1M 1M')
+ self.vm.qmp_qemu_io('drive0', 'write 1M 1M')
self.vm.cmd('block-commit', device='overlay')
self.complete_and_wait()
@@ -112,7 +112,7 @@ class TestPreallocateFilter(TestPreallocateBase):
}
}])
- self.vm.hmp_qemu_io('drive0', 'write 0 1M')
+ self.vm.qmp_qemu_io('drive0', 'write 0 1M')
self.assertTrue(os.path.getsize(disk) == 25 * MiB)
@@ -177,5 +177,4 @@ class TestTruncate(iotests.QMPTestCase):
if __name__ == '__main__':
- iotests.main(supported_fmts=['qcow2'], required_fmts=['preallocate'],
- require_hmp=True)
+ iotests.main(supported_fmts=['qcow2'], required_fmts=['preallocate'])
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 26/88] qemu-iotests/056: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (24 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 25/88] qemu-iotests/298: migrate away from HMP Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 27/88] qemu-iotests/093: " Marc-André Lureau
` (63 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/056 | 21 ++++++++++-----------
1 file changed, 10 insertions(+), 11 deletions(-)
diff --git a/tests/qemu-iotests/056 b/tests/qemu-iotests/056
index 7cc97486951c..b01b11522bb5 100755
--- a/tests/qemu-iotests/056
+++ b/tests/qemu-iotests/056
@@ -91,8 +91,8 @@ class TestSyncModesNoneAndTop(iotests.QMPTestCase):
self.vm.cmd('drive-backup', device='drive0',
sync='none', target=target_img)
time.sleep(1)
- self.vm.hmp_qemu_io('drive0', 'write -P0x5e 0 512')
- self.vm.hmp_qemu_io('drive0', 'aio_flush')
+ self.vm.qmp_qemu_io('drive0', 'write -P0x5e 0 512')
+ self.vm.qmp_qemu_io('drive0', 'aio_flush')
# Verify that the original contents exist in the target image.
event = self.cancel_and_wait()
@@ -119,7 +119,7 @@ class TestBeforeWriteNotifier(iotests.QMPTestCase):
self.vm.cmd('block-job-pause', device="drive0")
# Speed is low enough that this must be an uncopied range, which will
# trigger the before write notifier
- self.vm.hmp_qemu_io('drive0', 'aio_write -P 1 512512 512')
+ self.vm.qmp_qemu_io('drive0', 'aio_write -P 1 512512 512')
self.vm.resume_drive("drive0")
self.vm.cmd('block-job-resume', device="drive0")
event = self.cancel_and_wait()
@@ -142,10 +142,10 @@ class BackupTest(iotests.QMPTestCase):
try_remove(self.dest_img2)
try_remove(self.ref_img)
- def hmp_io_writes(self, drive, patterns):
+ def qmp_io_writes(self, drive, patterns):
for pattern in patterns:
- self.vm.hmp_qemu_io(drive, 'write -P%s %s %s' % pattern)
- self.vm.hmp_qemu_io(drive, 'flush')
+ self.vm.qmp_qemu_io(drive, 'write -P%s %s %s' % pattern)
+ self.vm.qmp_qemu_io(drive, 'flush')
def qmp_backup_and_wait(self, cmd='drive-backup', serror=None,
aerror=None, **kwargs):
@@ -180,7 +180,7 @@ class BackupTest(iotests.QMPTestCase):
def test_overlapping_writes(self):
# Write something to back up
- self.hmp_io_writes('drive0', [('42', '0M', '2M')])
+ self.qmp_io_writes('drive0', [('42', '0M', '2M')])
# Create a reference backup
self.qmp_backup_and_wait(device='drive0', format=iotests.imgfmt,
@@ -201,7 +201,7 @@ class BackupTest(iotests.QMPTestCase):
self.qmp_backup(device='drive0', format=iotests.imgfmt, sync='full',
target=self.dest_img, speed=1, auto_dismiss=False)
- self.hmp_io_writes('drive0', [('23', '%ik' % (1024 + 64), '64k'),
+ self.qmp_io_writes('drive0', [('23', '%ik' % (1024 + 64), '64k'),
('66', '1M', '1M')])
# Let the job complete
@@ -266,7 +266,7 @@ class BackupTest(iotests.QMPTestCase):
res = self.vm.qmp('query-block-jobs')
self.assert_qmp(res, 'return', [])
# Give blkdebug something to chew on
- self.hmp_io_writes('drive0',
+ self.qmp_io_writes('drive0',
(('0x9a', 0, 512),
('0x55', '8M', '352k'),
('0x78', '15872k', '1M')))
@@ -332,5 +332,4 @@ class BackupTest(iotests.QMPTestCase):
if __name__ == '__main__':
iotests.main(supported_fmts=['qcow2', 'qed'],
- supported_protocols=['file'],
- require_hmp=True)
+ supported_protocols=['file'])
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 27/88] qemu-iotests/093: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (25 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 26/88] qemu-iotests/056: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 28/88] qemu-iotests/124: " Marc-André Lureau
` (62 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/093 | 15 +++++++--------
1 file changed, 7 insertions(+), 8 deletions(-)
diff --git a/tests/qemu-iotests/093 b/tests/qemu-iotests/093
index 26ae6e2b2d56..5a22f672d8c2 100755
--- a/tests/qemu-iotests/093
+++ b/tests/qemu-iotests/093
@@ -90,13 +90,13 @@ class ThrottleTestCase(iotests.QMPTestCase):
for i in range(rd_nr):
for drive in range(0, ndrives):
idx = first_drive + drive
- self.vm.hmp_qemu_io("drive%d" % idx, "aio_read %d %d" %
+ self.vm.qmp_qemu_io("drive%d" % idx, "aio_read %d %d" %
(i * rq_size, rq_size))
for i in range(wr_nr):
for drive in range(0, ndrives):
idx = first_drive + drive
- self.vm.hmp_qemu_io("drive%d" % idx, "aio_write %d %d" %
+ self.vm.qmp_qemu_io("drive%d" % idx, "aio_write %d %d" %
(i * rq_size, rq_size))
# We'll store the I/O stats for each drive in these arrays
@@ -227,21 +227,21 @@ class ThrottleTestCase(iotests.QMPTestCase):
self.configure_throttle(2, params)
# Read 4KB from drive0. This is performed immediately.
- self.vm.hmp_qemu_io("drive0", "aio_read 0 4096")
+ self.vm.qmp_qemu_io("drive0", "aio_read 0 4096")
# Read 2KB. The I/O limit has been exceeded so this
# request is throttled and a timer is set to wake it up.
- self.vm.hmp_qemu_io("drive0", "aio_read 0 2048")
+ self.vm.qmp_qemu_io("drive0", "aio_read 0 2048")
# Read 2KB again. We're still over the I/O limit so this is
# request is also throttled, but no new timer is set since
# there's already one.
- self.vm.hmp_qemu_io("drive0", "aio_read 0 2048")
+ self.vm.qmp_qemu_io("drive0", "aio_read 0 2048")
# Read from drive1. This request is also throttled, and no
# timer is set in drive1 because there's already one in
# drive0.
- self.vm.hmp_qemu_io("drive1", "aio_read 0 4096")
+ self.vm.qmp_qemu_io("drive1", "aio_read 0 4096")
# At this point only the first 4KB have been read from drive0.
# The other requests are throttled.
@@ -419,5 +419,4 @@ class ThrottleTestRemovableMedia(iotests.QMPTestCase):
if __name__ == '__main__':
if 'null-co' not in iotests.supported_formats():
iotests.notrun('null-co driver support missing')
- iotests.main(supported_fmts=["raw"],
- require_hmp=True)
+ iotests.main(supported_fmts=["raw"])
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 28/88] qemu-iotests/124: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (26 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 27/88] qemu-iotests/093: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 29/88] qemu-iotests/136: " Marc-André Lureau
` (61 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/124 | 33 ++++++++++++++++-----------------
1 file changed, 16 insertions(+), 17 deletions(-)
diff --git a/tests/qemu-iotests/124 b/tests/qemu-iotests/124
index ab9ea4d8b59d..662cca71d6d7 100755
--- a/tests/qemu-iotests/124
+++ b/tests/qemu-iotests/124
@@ -249,10 +249,10 @@ class TestIncrementalBackupBase(iotests.QMPTestCase):
self.assertTrue(iotests.compare_images(last, bitmap.drive['file']))
- def hmp_io_writes(self, drive, patterns):
+ def qmp_io_writes(self, drive, patterns):
for pattern in patterns:
- self.vm.hmp_qemu_io(drive, 'write -P%s %s %s' % pattern)
- self.vm.hmp_qemu_io(drive, 'flush')
+ self.vm.qmp_qemu_io(drive, 'write -P%s %s %s' % pattern)
+ self.vm.qmp_qemu_io(drive, 'flush')
def do_incremental_simple(self, **kwargs):
@@ -263,12 +263,12 @@ class TestIncrementalBackupBase(iotests.QMPTestCase):
self.create_incremental()
# Three writes: One complete overwrite, one new segment,
# and one partial overlap.
- self.hmp_io_writes(self.drives[0]['id'], (('0xab', 0, 512),
+ self.qmp_io_writes(self.drives[0]['id'], (('0xab', 0, 512),
('0xfe', '16M', '256k'),
('0x64', '32736k', '64k')))
self.create_incremental()
# Three more writes, one of each kind, like above
- self.hmp_io_writes(self.drives[0]['id'], (('0x9a', 0, 512),
+ self.qmp_io_writes(self.drives[0]['id'], (('0x9a', 0, 512),
('0x55', '8M', '352k'),
('0x78', '15872k', '1M')))
self.create_incremental()
@@ -337,7 +337,7 @@ class TestIncrementalBackup(TestIncrementalBackupBase):
# overwrite [32736, 32799] which will dirty bitmap clusters at
# 32M-64K and 32M. 32M+64K will be left undirtied.
bitmap0 = self.add_bitmap('bitmap0', drive0)
- self.hmp_io_writes(drive0['id'],
+ self.qmp_io_writes(drive0['id'],
(('0xab', 0, 512),
('0xfe', '16M', '256k'),
('0x64', '32736k', '64k')))
@@ -382,7 +382,7 @@ class TestIncrementalBackup(TestIncrementalBackupBase):
drive0 = self.drives[0]
bitmap0 = self.add_bitmap('bitmap0', drive0)
- self.hmp_io_writes(drive0['id'], (('0xab', 0, 512),
+ self.qmp_io_writes(drive0['id'], (('0xab', 0, 512),
('0xfe', '16M', '256k'),
('0x64', '32736k', '64k')))
bitmap1 = self.add_bitmap('bitmap1', drive0)
@@ -396,7 +396,7 @@ class TestIncrementalBackup(TestIncrementalBackupBase):
self.wait_until_completed(drive0['id'])
self.files.append(drive0['backup'])
- self.hmp_io_writes(drive0['id'], (('0x9a', 0, 512),
+ self.qmp_io_writes(drive0['id'], (('0x9a', 0, 512),
('0x55', '8M', '352k'),
('0x78', '15872k', '1M')))
# Both bitmaps should be correctly in sync.
@@ -450,10 +450,10 @@ class TestIncrementalBackup(TestIncrementalBackupBase):
# Emulate some writes
if not race:
- self.hmp_io_writes(drive0['id'], (('0xab', 0, 512),
+ self.qmp_io_writes(drive0['id'], (('0xab', 0, 512),
('0xfe', '16M', '256k'),
('0x64', '32736k', '64k')))
- self.hmp_io_writes(drive1['id'], (('0xba', 0, 512),
+ self.qmp_io_writes(drive1['id'], (('0xba', 0, 512),
('0xef', '16M', '256k'),
('0x46', '32736k', '64k')))
@@ -584,7 +584,7 @@ class TestIncrementalBackup(TestIncrementalBackupBase):
size=(65 * 1048576))
# Dirty the image past the old end
- self.vm.hmp_qemu_io(self.drives[0]['id'], 'write 64M 64k')
+ self.vm.qmp_qemu_io(self.drives[0]['id'], 'write 64M 64k')
target = self.prepare_backup(size='65M')
self.create_incremental(target=target)
@@ -640,13 +640,13 @@ class TestIncrementalBackupBlkdebug(TestIncrementalBackupBase):
# Note: at this point, during a normal execution,
# Assume that the VM resumes and begins issuing IO requests here.
- self.hmp_io_writes(drive0['id'], (('0xab', 0, 512),
+ self.qmp_io_writes(drive0['id'], (('0xab', 0, 512),
('0xfe', '16M', '256k'),
('0x64', '32736k', '64k')))
result = self.create_incremental(validate=False)
self.assertFalse(result)
- self.hmp_io_writes(drive0['id'], (('0x9a', 0, 512),
+ self.qmp_io_writes(drive0['id'], (('0x9a', 0, 512),
('0x55', '8M', '352k'),
('0x78', '15872k', '1M')))
self.create_incremental()
@@ -660,7 +660,7 @@ class TestIncrementalBackupBlkdebug(TestIncrementalBackupBase):
drive0 = self.drives[0]
# NB: The blkdebug script here looks for a "flush, read" pattern.
- # The flush occurs in hmp_io_writes, and the read during the block job.
+ # The flush occurs in qmp_io_writes, and the read during the block job.
self.vm.cmd('blockdev-add',
node_name=drive0['id'],
driver=drive0['fmt'],
@@ -687,7 +687,7 @@ class TestIncrementalBackupBlkdebug(TestIncrementalBackupBase):
bitmap = self.add_bitmap('bitmap0', drive0)
# Emulate guest activity
- self.hmp_io_writes(drive0['id'], (('0xab', 0, 512),
+ self.qmp_io_writes(drive0['id'], (('0xab', 0, 512),
('0xfe', '16M', '256k'),
('0x64', '32736k', '64k')))
@@ -750,5 +750,4 @@ class TestIncrementalBackupBlkdebug(TestIncrementalBackupBase):
if __name__ == '__main__':
iotests.main(supported_fmts=['qcow2'],
- supported_protocols=['file'],
- require_hmp=True)
+ supported_protocols=['file'])
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 29/88] qemu-iotests/136: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (27 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 28/88] qemu-iotests/124: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 30/88] qemu-iotests/148: " Marc-André Lureau
` (60 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/136 | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/tests/qemu-iotests/136 b/tests/qemu-iotests/136
index 72fd638aa04d..32857990fa3e 100755
--- a/tests/qemu-iotests/136
+++ b/tests/qemu-iotests/136
@@ -58,9 +58,9 @@ class BlockDeviceStatsTestCase(iotests.QMPTestCase):
def qemu_io(self, cmd):
if self.use_blockdev:
- self.vm.hmp_qemu_io("virtio0/virtio-backend", cmd, qdev=True)
+ self.vm.qmp_qemu_io("virtio0/virtio-backend", cmd, qdev=True)
else:
- self.vm.hmp_qemu_io("drive0", cmd)
+ self.vm.qmp_qemu_io("drive0", cmd)
def create_blkdebug_file(self):
file = open(blkdebug_file, 'w')
@@ -410,5 +410,4 @@ class BlockDeviceStatsTestCoroutine(BlockDeviceStatsTestCase):
if __name__ == '__main__':
if 'null-co' not in iotests.supported_formats():
iotests.notrun('null-co driver support missing')
- iotests.main(supported_fmts=["raw"],
- require_hmp=True)
+ iotests.main(supported_fmts=["raw"])
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 30/88] qemu-iotests/148: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (28 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 29/88] qemu-iotests/136: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 31/88] qemu-iotests/151: " Marc-André Lureau
` (59 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/148 | 13 ++++++-------
1 file changed, 6 insertions(+), 7 deletions(-)
diff --git a/tests/qemu-iotests/148 b/tests/qemu-iotests/148
index 4b092dccb7cc..0279386e3299 100755
--- a/tests/qemu-iotests/148
+++ b/tests/qemu-iotests/148
@@ -82,7 +82,7 @@ sector = "%d"
def testQuorum(self):
# Generate an error and get an event
- self.vm.hmp_qemu_io("drive0", "aio_read %d %d" %
+ self.vm.qmp_qemu_io("drive0", "aio_read %d %d" %
(offset * sector_size, sector_size))
self.vm.qtest("clock_step 10")
self.do_check_event('img0', offset)
@@ -90,7 +90,7 @@ sector = "%d"
# I/O errors in the same child: only one event is emitted
delay = 10
for i in range(3):
- self.vm.hmp_qemu_io("drive0", "aio_read %d %d" %
+ self.vm.qmp_qemu_io("drive0", "aio_read %d %d" %
(offset * sector_size, sector_size))
self.vm.qtest("clock_step %d" % delay)
self.do_check_event(None)
@@ -102,7 +102,7 @@ sector = "%d"
# I/O errors in the same child: all events are emitted
delay = 2 * event_rate
for i in range(3):
- self.vm.hmp_qemu_io("drive0", "aio_read %d %d" %
+ self.vm.qmp_qemu_io("drive0", "aio_read %d %d" %
(offset * sector_size, sector_size))
self.vm.qtest("clock_step %d" % delay)
self.do_check_event('img0', offset)
@@ -110,7 +110,7 @@ sector = "%d"
# I/O errors in different children: all events are emitted
delay = 10
for i in range(len(imgs)):
- self.vm.hmp_qemu_io("drive0", "aio_read %d %d" %
+ self.vm.qmp_qemu_io("drive0", "aio_read %d %d" %
((offset + i) * sector_size, sector_size))
self.vm.qtest("clock_step %d" % delay)
# In fifo mode only errors in the first child are detected
@@ -122,7 +122,7 @@ sector = "%d"
# I/O errors in different children: all events are emitted
delay = 2 * event_rate
for i in range(len(imgs)):
- self.vm.hmp_qemu_io("drive0", "aio_read %d %d" %
+ self.vm.qmp_qemu_io("drive0", "aio_read %d %d" %
((offset + i) * sector_size, sector_size))
self.vm.qtest("clock_step %d" % delay)
# In fifo mode only errors in the first child are detected
@@ -140,5 +140,4 @@ class TestFifoQuorumEvents(TestQuorumEvents):
if __name__ == '__main__':
iotests.verify_quorum()
iotests.main(supported_fmts=["raw"],
- supported_protocols=["file"],
- require_hmp=True)
+ supported_protocols=["file"])
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 31/88] qemu-iotests/151: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (29 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 30/88] qemu-iotests/148: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 32/88] qemu-iotests/236: " Marc-André Lureau
` (58 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/151 | 51 +++++++++++++++++++++++++-------------------------
1 file changed, 25 insertions(+), 26 deletions(-)
diff --git a/tests/qemu-iotests/151 b/tests/qemu-iotests/151
index 204221a5738e..72f7bcaa0c60 100755
--- a/tests/qemu-iotests/151
+++ b/tests/qemu-iotests/151
@@ -69,14 +69,14 @@ class TestActiveMirror(iotests.QMPTestCase):
def doActiveIO(self, sync_source_and_target):
# Fill the source image
- self.vm.hmp_qemu_io('source',
+ self.vm.qmp_qemu_io('source',
'write -P 1 0 %i' % self.image_len);
# Start some background requests
for offset in range(1 * self.image_len // 8, 3 * self.image_len // 8, 1024 * 1024):
- self.vm.hmp_qemu_io('source', 'aio_write -P 2 %i 1M' % offset)
+ self.vm.qmp_qemu_io('source', 'aio_write -P 2 %i 1M' % offset)
for offset in range(2 * self.image_len // 8, 3 * self.image_len // 8, 1024 * 1024):
- self.vm.hmp_qemu_io('source', 'aio_write -z %i 1M' % offset)
+ self.vm.qmp_qemu_io('source', 'aio_write -z %i 1M' % offset)
# Start the block job
self.vm.cmd('blockdev-mirror',
@@ -89,9 +89,9 @@ class TestActiveMirror(iotests.QMPTestCase):
# Start some more requests
for offset in range(3 * self.image_len // 8, 5 * self.image_len // 8, 1024 * 1024):
- self.vm.hmp_qemu_io('source', 'aio_write -P 3 %i 1M' % offset)
+ self.vm.qmp_qemu_io('source', 'aio_write -P 3 %i 1M' % offset)
for offset in range(4 * self.image_len // 8, 5 * self.image_len // 8, 1024 * 1024):
- self.vm.hmp_qemu_io('source', 'aio_write -z %i 1M' % offset)
+ self.vm.qmp_qemu_io('source', 'aio_write -z %i 1M' % offset)
# Wait for the READY event
self.wait_ready(drive='mirror')
@@ -101,14 +101,14 @@ class TestActiveMirror(iotests.QMPTestCase):
# The mirror code itself asserts that the source BDS's dirty
# bitmap will stay clean between READY and COMPLETED.
for offset in range(5 * self.image_len // 8, 7 * self.image_len // 8, 1024 * 1024):
- self.vm.hmp_qemu_io('source', 'aio_write -P 3 %i 1M' % offset)
+ self.vm.qmp_qemu_io('source', 'aio_write -P 3 %i 1M' % offset)
for offset in range(6 * self.image_len // 8, 7 * self.image_len // 8, 1024 * 1024):
- self.vm.hmp_qemu_io('source', 'aio_write -z %i 1M' % offset)
+ self.vm.qmp_qemu_io('source', 'aio_write -z %i 1M' % offset)
if sync_source_and_target:
# If source and target should be in sync after the mirror,
# we have to flush before completion
- self.vm.hmp_qemu_io('source', 'aio_flush')
+ self.vm.qmp_qemu_io('source', 'aio_flush')
self.potential_writes_in_flight = False
self.complete_and_wait(drive='mirror', wait_ready=False)
@@ -121,7 +121,7 @@ class TestActiveMirror(iotests.QMPTestCase):
def testUnalignedActiveIO(self):
# Fill the source image
- result = self.vm.hmp_qemu_io('source', 'write -P 1 0 2M')
+ result = self.vm.qmp_qemu_io('source', 'write -P 1 0 2M')
# Start the block job (very slowly)
self.vm.cmd('blockdev-mirror',
@@ -135,7 +135,7 @@ class TestActiveMirror(iotests.QMPTestCase):
speed=1)
# Start an unaligned request to a dirty area
- result = self.vm.hmp_qemu_io('source', 'write -P 2 %i 1' % (1048576 + 42))
+ result = self.vm.qmp_qemu_io('source', 'write -P 2 %i 1' % (1048576 + 42))
# Let the job finish
self.vm.cmd('block-job-set-speed', device='mirror', speed=0)
@@ -145,7 +145,7 @@ class TestActiveMirror(iotests.QMPTestCase):
def testIntersectingActiveIO(self):
# Fill the source image
- result = self.vm.hmp_qemu_io('source', 'write -P 1 0 2M')
+ result = self.vm.qmp_qemu_io('source', 'write -P 1 0 2M')
# Start the block job (very slowly)
self.vm.cmd('blockdev-mirror',
@@ -157,23 +157,23 @@ class TestActiveMirror(iotests.QMPTestCase):
copy_mode='write-blocking',
speed=1)
- self.vm.hmp_qemu_io('source', 'break write_aio A')
- self.vm.hmp_qemu_io('source', 'aio_write 0 1M') # 1
- self.vm.hmp_qemu_io('source', 'wait_break A')
- self.vm.hmp_qemu_io('source', 'aio_write 0 2M') # 2
- self.vm.hmp_qemu_io('source', 'aio_write 0 2M') # 3
+ self.vm.qmp_qemu_io('source', 'break write_aio A')
+ self.vm.qmp_qemu_io('source', 'aio_write 0 1M') # 1
+ self.vm.qmp_qemu_io('source', 'wait_break A')
+ self.vm.qmp_qemu_io('source', 'aio_write 0 2M') # 2
+ self.vm.qmp_qemu_io('source', 'aio_write 0 2M') # 3
# Now 2 and 3 are in mirror_wait_on_conflicts, waiting for 1
- self.vm.hmp_qemu_io('source', 'break write_aio B')
- self.vm.hmp_qemu_io('source', 'aio_write 1M 2M') # 4
- self.vm.hmp_qemu_io('source', 'wait_break B')
+ self.vm.qmp_qemu_io('source', 'break write_aio B')
+ self.vm.qmp_qemu_io('source', 'aio_write 1M 2M') # 4
+ self.vm.qmp_qemu_io('source', 'wait_break B')
# 4 doesn't wait for 2 and 3, because they didn't yet set
# in_flight_bitmap. So, nothing prevents 4 to go except for our
# break-point B.
- self.vm.hmp_qemu_io('source', 'resume A')
+ self.vm.qmp_qemu_io('source', 'resume A')
# Now we resumed 1, so 2 and 3 goes to the next iteration of while loop
# in mirror_wait_on_conflicts(). They don't exit, as bitmap is dirty
@@ -181,7 +181,7 @@ class TestActiveMirror(iotests.QMPTestCase):
# In the past at that point 2 and 3 would wait for each other producing
# a dead-lock. Now this is fixed and they will wait for request 4.
- self.vm.hmp_qemu_io('source', 'resume B')
+ self.vm.qmp_qemu_io('source', 'resume B')
# After resuming 4, one of 2 and 3 goes first and set in_flight_bitmap,
# so the other will wait for it.
@@ -193,7 +193,7 @@ class TestActiveMirror(iotests.QMPTestCase):
def testUnalignedSmallerThanGranularityWriteZeroes(self):
# Fill the source image
- self.vm.hmp_qemu_io('source', 'write -P 1 0 %i' % self.image_len);
+ self.vm.qmp_qemu_io('source', 'write -P 1 0 %i' % self.image_len);
# Start the block job
self.vm.cmd('blockdev-mirror',
@@ -208,7 +208,7 @@ class TestActiveMirror(iotests.QMPTestCase):
self.wait_ready(drive='mirror')
for offset in range(6 * self.image_len // 8, 7 * self.image_len // 8, 1024 * 1024):
- self.vm.hmp_qemu_io('source', 'aio_write -z %i 512' % (offset + 512))
+ self.vm.qmp_qemu_io('source', 'aio_write -z %i 512' % (offset + 512))
self.complete_and_wait(drive='mirror', wait_ready=False)
@@ -323,7 +323,7 @@ class TestLowThrottledWithNbdExport(TestThrottledWithNbdExportBase):
# progress (because when the job was started, those areas were not
# intended to be copied, so active mirroring will only lead to not
# losing progress, but also not making any).
- self.vm.hmp_qemu_io('source-node',
+ self.vm.qmp_qemu_io('source-node',
f'aio_write -P 1 0 {self.image_len // 2}')
self.vm.qtest(f'clock_step {1 * 1000 * 1000 * 1000}')
@@ -434,5 +434,4 @@ class TestHighThrottledWithNbdExport(TestThrottledWithNbdExportBase):
if __name__ == '__main__':
iotests.main(supported_fmts=['qcow2', 'raw'],
- supported_protocols=['file'],
- require_hmp=True)
+ supported_protocols=['file'])
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 32/88] qemu-iotests/236: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (30 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 31/88] qemu-iotests/151: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 33/88] qemu-iotests/245: " Marc-André Lureau
` (57 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
No need to log empty results, qmp_qemu_io() already checks for success.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/236 | 7 +++----
tests/qemu-iotests/236.out | 8 --------
2 files changed, 3 insertions(+), 12 deletions(-)
diff --git a/tests/qemu-iotests/236 b/tests/qemu-iotests/236
index 3cf0de4043f6..0d2c1780df71 100755
--- a/tests/qemu-iotests/236
+++ b/tests/qemu-iotests/236
@@ -23,8 +23,7 @@
import iotests
from iotests import log
-iotests.script_initialize(supported_fmts=['generic'],
- require_hmp=True)
+iotests.script_initialize(supported_fmts=['generic'])
size = 64 * 1024 * 1024
granularity = 64 * 1024
@@ -62,7 +61,7 @@ with iotests.FilePath('img') as img_path, \
for p in patterns:
cmd = "write -P%s %s %s" % p
log(cmd)
- log(vm.hmp_qemu_io("drive0", cmd))
+ vm.qmp_qemu_io("drive0", cmd)
log(query_bitmaps(vm), indent=2)
@@ -100,7 +99,7 @@ with iotests.FilePath('img') as img_path, \
for p in overwrite:
cmd = "write -P%s %s %s" % p
log(cmd)
- log(vm.hmp_qemu_io("drive0", cmd))
+ vm.qmp_qemu_io("drive0", cmd)
log('\n--- Disabling A & C ---\n')
vm.qmp_log("transaction", indent=2, actions=[
diff --git a/tests/qemu-iotests/236.out b/tests/qemu-iotests/236.out
index 7448ceea027e..aedac37931d7 100644
--- a/tests/qemu-iotests/236.out
+++ b/tests/qemu-iotests/236.out
@@ -11,13 +11,9 @@
--- Emulating writes ---
write -P0x5d 0 64k
-{"return": ""}
write -P0xd5 1M 64k
-{"return": ""}
write -P0xdc 32M 64k
-{"return": ""}
write -P0xcd 0x3ff0000 64k
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -150,13 +146,9 @@ write -P0xcd 0x3ff0000 64k
--- Emulating further writes ---
write -P0xab 0 64k
-{"return": ""}
write -P0xad 0x00f8000 64k
-{"return": ""}
write -P0x1d 0x2008000 64k
-{"return": ""}
write -P0xea 0x3fe0000 64k
-{"return": ""}
--- Disabling A & C ---
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 33/88] qemu-iotests/245: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (31 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 32/88] qemu-iotests/236: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 34/88] qemu-iotests/255: " Marc-André Lureau
` (56 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
No need to wait until the VM is shut down to verify the output.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/245 | 28 +++-------------------------
1 file changed, 3 insertions(+), 25 deletions(-)
diff --git a/tests/qemu-iotests/245 b/tests/qemu-iotests/245
index 2f354d1d9205..3f4a87d2cd8a 100755
--- a/tests/qemu-iotests/245
+++ b/tests/qemu-iotests/245
@@ -58,34 +58,13 @@ class TestBlockdevReopen(iotests.QMPTestCase):
def tearDown(self):
self.vm.shutdown()
- self.check_qemu_io_errors()
os.remove(hd_path[0])
os.remove(hd_path[1])
os.remove(hd_path[2])
- # The output of qemu-io is not returned by vm.hmp_qemu_io() but
- # it's stored in the log and can only be read when the VM has been
- # shut down. This function runs qemu-io and keeps track of the
- # number of times it's been called.
def run_qemu_io(self, img, cmd):
- result = self.vm.hmp_qemu_io(img, cmd)
- self.assert_qmp(result, 'return', '')
- self.total_io_cmds += 1
-
- # Once the VM is shut down we can parse the log and see if qemu-io
- # ran without errors.
- def check_qemu_io_errors(self):
- self.assertFalse(self.vm.is_running())
- found = 0
- log = self.vm.get_log()
- for line in log.split("\n"):
- if line.startswith("Pattern verification failed"):
- raise Exception("%s (command #%d)" % (line, found))
- if re.match("(read|wrote) .*/.* bytes at offset", line):
- found += 1
- self.assertEqual(found, self.total_io_cmds,
- "Expected output of %d qemu-io commands, found %d" %
- (found, self.total_io_cmds))
+ result = self.vm.qmp('x-qemu-io', device=img, command=cmd)
+ self.assert_qmp_absent(result, 'error')
# Run blockdev-reopen on a list of block devices
def reopenMultiple(self, opts, errmsg = None):
@@ -1160,5 +1139,4 @@ class TestBlockdevReopen(iotests.QMPTestCase):
if __name__ == '__main__':
iotests.activate_logging()
iotests.main(supported_fmts=["qcow2"],
- supported_protocols=["file"],
- require_hmp=True)
+ supported_protocols=["file"])
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 34/88] qemu-iotests/255: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (32 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 33/88] qemu-iotests/245: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 35/88] qemu-iotests/257: " Marc-André Lureau
` (55 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/255 | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/tests/qemu-iotests/255 b/tests/qemu-iotests/255
index 8f88522f1e91..83c2246db3b2 100755
--- a/tests/qemu-iotests/255
+++ b/tests/qemu-iotests/255
@@ -24,8 +24,7 @@
import iotests
from iotests import imgfmt
-iotests.script_initialize(supported_fmts=['qcow2'],
- require_hmp=True)
+iotests.script_initialize(supported_fmts=['qcow2'])
iotests.log('Finishing a commit job with background reads')
iotests.log('============================================')
@@ -62,8 +61,8 @@ with iotests.FilePath('t.qcow2') as disk_path, \
iotests.log("")
def start_requests():
- vm.hmp_qemu_io('overlay', 'aio_read 0 4k')
- vm.hmp_qemu_io('overlay', 'aio_read 0 4k')
+ vm.qmp_qemu_io('overlay', 'aio_read 0 4k')
+ vm.qmp_qemu_io('overlay', 'aio_read 0 4k')
start_requests()
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 35/88] qemu-iotests/257: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (33 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 34/88] qemu-iotests/255: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 36/88] qemu-iotests/260: " Marc-André Lureau
` (54 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
No need to log success, the qmp_qemu_io() command already checks for it.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/257 | 7 +-
tests/qemu-iotests/257.out | 315 ---------------------------------------------
2 files changed, 3 insertions(+), 319 deletions(-)
diff --git a/tests/qemu-iotests/257 b/tests/qemu-iotests/257
index 5e4dba02e769..3fbf24531a7d 100755
--- a/tests/qemu-iotests/257
+++ b/tests/qemu-iotests/257
@@ -227,7 +227,7 @@ def perform_writes(drive, n, filter_node_name=None):
pattern.offset,
pattern.size)
log(cmd)
- log(drive.vm.hmp_qemu_io(filter_node_name or drive.node, cmd))
+ drive.vm.qmp_qemu_io(filter_node_name or drive.node, cmd)
bitmaps = drive.vm.query_bitmaps()
log({'bitmaps': bitmaps}, indent=2)
log('')
@@ -354,7 +354,7 @@ def test_bitmap_sync(bsync_mode, msync_mode='bitmap', failure=None):
# 1 - Test Backup (w/ Optional induced failure)
if failure == 'intermediate':
# Activate blkdebug induced failure for second-to-next read
- log(vm.hmp_qemu_io(drive0.node, 'flush'))
+ vm.qmp_qemu_io(drive0.node, 'flush')
log('')
job = backup(drive0, 1, bsync1, msync_mode,
bitmap="bitmap0", bitmap_mode=bsync_mode)
@@ -533,5 +533,4 @@ def main():
if __name__ == '__main__':
iotests.script_main(main, supported_fmts=['qcow2'],
- supported_protocols=['file'],
- require_hmp=True)
+ supported_protocols=['file'])
diff --git a/tests/qemu-iotests/257.out b/tests/qemu-iotests/257.out
index fb28333cb2fa..984dd7dbd73e 100644
--- a/tests/qemu-iotests/257.out
+++ b/tests/qemu-iotests/257.out
@@ -9,13 +9,9 @@
--- Write #0 ---
write -P0x49 0x0000000 0x10000
-{"return": ""}
write -P0x6c 0x0100000 0x10000
-{"return": ""}
write -P0x6f 0x2000000 0x10000
-{"return": ""}
write -P0x76 0x3ff0000 0x10000
-{"return": ""}
{
"bitmaps": {}
}
@@ -42,13 +38,9 @@ write -P0x76 0x3ff0000 0x10000
--- Write #1 ---
write -P0x65 0x0000000 0x10000
-{"return": ""}
write -P0x77 0x00f8000 0x10000
-{"return": ""}
write -P0x72 0x2008000 0x10000
-{"return": ""}
write -P0x69 0x3fe0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -97,13 +89,9 @@ expecting 6 dirty sectors; have 6. OK!
--- Write #2 ---
write -P0x74 0x0010000 0x10000
-{"return": ""}
write -P0x69 0x00e8000 0x10000
-{"return": ""}
write -P0x6e 0x2018000 0x10000
-{"return": ""}
write -P0x67 0x3fe0000 0x20000
-{"return": ""}
{
"bitmaps": {
"backup-top": [
@@ -180,13 +168,9 @@ expecting 10 dirty sectors; have 10. OK!
--- Write #3 ---
write -P0xaa 0x0010000 0x30000
-{"return": ""}
write -P0xbb 0x00d8000 0x10000
-{"return": ""}
write -P0xcc 0x2028000 0x10000
-{"return": ""}
write -P0xdd 0x3fc0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -278,13 +262,9 @@ qemu_img compare "TEST_DIR/PID-img" "TEST_DIR/PID-fbackup2" ==> Identical, OK!
--- Write #0 ---
write -P0x49 0x0000000 0x10000
-{"return": ""}
write -P0x6c 0x0100000 0x10000
-{"return": ""}
write -P0x6f 0x2000000 0x10000
-{"return": ""}
write -P0x76 0x3ff0000 0x10000
-{"return": ""}
{
"bitmaps": {}
}
@@ -311,13 +291,9 @@ write -P0x76 0x3ff0000 0x10000
--- Write #1 ---
write -P0x65 0x0000000 0x10000
-{"return": ""}
write -P0x77 0x00f8000 0x10000
-{"return": ""}
write -P0x72 0x2008000 0x10000
-{"return": ""}
write -P0x69 0x3fe0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -350,7 +326,6 @@ expecting 6 dirty sectors; have 6. OK!
{"return": {}}
{"data": {"device": "ref_backup_1", "len": 67108864, "offset": 67108864, "speed": 0, "type": "backup"}, "event": "BLOCK_JOB_COMPLETED", "timestamp": {"microseconds": "USECS", "seconds": "SECS"}}
-{"return": ""}
--- Test Backup #1 ---
@@ -387,13 +362,9 @@ expecting 6 dirty sectors; have 6. OK!
--- Write #3 ---
write -P0xaa 0x0010000 0x30000
-{"return": ""}
write -P0xbb 0x00d8000 0x10000
-{"return": ""}
write -P0xcc 0x2028000 0x10000
-{"return": ""}
write -P0xdd 0x3fc0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -485,13 +456,9 @@ qemu_img compare "TEST_DIR/PID-img" "TEST_DIR/PID-fbackup2" ==> Identical, OK!
--- Write #0 ---
write -P0x49 0x0000000 0x10000
-{"return": ""}
write -P0x6c 0x0100000 0x10000
-{"return": ""}
write -P0x6f 0x2000000 0x10000
-{"return": ""}
write -P0x76 0x3ff0000 0x10000
-{"return": ""}
{
"bitmaps": {}
}
@@ -518,13 +485,9 @@ write -P0x76 0x3ff0000 0x10000
--- Write #1 ---
write -P0x65 0x0000000 0x10000
-{"return": ""}
write -P0x77 0x00f8000 0x10000
-{"return": ""}
write -P0x72 0x2008000 0x10000
-{"return": ""}
write -P0x69 0x3fe0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -573,13 +536,9 @@ expecting 6 dirty sectors; have 6. OK!
--- Write #2 ---
write -P0x74 0x0010000 0x10000
-{"return": ""}
write -P0x69 0x00e8000 0x10000
-{"return": ""}
write -P0x6e 0x2018000 0x10000
-{"return": ""}
write -P0x67 0x3fe0000 0x20000
-{"return": ""}
{
"bitmaps": {
"backup-top": [
@@ -656,13 +615,9 @@ expecting 10 dirty sectors; have 10. OK!
--- Write #3 ---
write -P0xaa 0x0010000 0x30000
-{"return": ""}
write -P0xbb 0x00d8000 0x10000
-{"return": ""}
write -P0xcc 0x2028000 0x10000
-{"return": ""}
write -P0xdd 0x3fc0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -754,13 +709,9 @@ qemu_img compare "TEST_DIR/PID-img" "TEST_DIR/PID-fbackup2" ==> Identical, OK!
--- Write #0 ---
write -P0x49 0x0000000 0x10000
-{"return": ""}
write -P0x6c 0x0100000 0x10000
-{"return": ""}
write -P0x6f 0x2000000 0x10000
-{"return": ""}
write -P0x76 0x3ff0000 0x10000
-{"return": ""}
{
"bitmaps": {}
}
@@ -787,13 +738,9 @@ write -P0x76 0x3ff0000 0x10000
--- Write #1 ---
write -P0x65 0x0000000 0x10000
-{"return": ""}
write -P0x77 0x00f8000 0x10000
-{"return": ""}
write -P0x72 0x2008000 0x10000
-{"return": ""}
write -P0x69 0x3fe0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -842,13 +789,9 @@ expecting 6 dirty sectors; have 6. OK!
--- Write #2 ---
write -P0x74 0x0010000 0x10000
-{"return": ""}
write -P0x69 0x00e8000 0x10000
-{"return": ""}
write -P0x6e 0x2018000 0x10000
-{"return": ""}
write -P0x67 0x3fe0000 0x20000
-{"return": ""}
{
"bitmaps": {
"backup-top": [
@@ -925,13 +868,9 @@ expecting 10 dirty sectors; have 10. OK!
--- Write #3 ---
write -P0xaa 0x0010000 0x30000
-{"return": ""}
write -P0xbb 0x00d8000 0x10000
-{"return": ""}
write -P0xcc 0x2028000 0x10000
-{"return": ""}
write -P0xdd 0x3fc0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -1023,13 +962,9 @@ qemu_img compare "TEST_DIR/PID-img" "TEST_DIR/PID-fbackup2" ==> Identical, OK!
--- Write #0 ---
write -P0x49 0x0000000 0x10000
-{"return": ""}
write -P0x6c 0x0100000 0x10000
-{"return": ""}
write -P0x6f 0x2000000 0x10000
-{"return": ""}
write -P0x76 0x3ff0000 0x10000
-{"return": ""}
{
"bitmaps": {}
}
@@ -1056,13 +991,9 @@ write -P0x76 0x3ff0000 0x10000
--- Write #1 ---
write -P0x65 0x0000000 0x10000
-{"return": ""}
write -P0x77 0x00f8000 0x10000
-{"return": ""}
write -P0x72 0x2008000 0x10000
-{"return": ""}
write -P0x69 0x3fe0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -1095,7 +1026,6 @@ expecting 6 dirty sectors; have 6. OK!
{"return": {}}
{"data": {"device": "ref_backup_1", "len": 67108864, "offset": 67108864, "speed": 0, "type": "backup"}, "event": "BLOCK_JOB_COMPLETED", "timestamp": {"microseconds": "USECS", "seconds": "SECS"}}
-{"return": ""}
--- Test Backup #1 ---
@@ -1132,13 +1062,9 @@ expecting 6 dirty sectors; have 6. OK!
--- Write #3 ---
write -P0xaa 0x0010000 0x30000
-{"return": ""}
write -P0xbb 0x00d8000 0x10000
-{"return": ""}
write -P0xcc 0x2028000 0x10000
-{"return": ""}
write -P0xdd 0x3fc0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -1230,13 +1156,9 @@ qemu_img compare "TEST_DIR/PID-img" "TEST_DIR/PID-fbackup2" ==> Identical, OK!
--- Write #0 ---
write -P0x49 0x0000000 0x10000
-{"return": ""}
write -P0x6c 0x0100000 0x10000
-{"return": ""}
write -P0x6f 0x2000000 0x10000
-{"return": ""}
write -P0x76 0x3ff0000 0x10000
-{"return": ""}
{
"bitmaps": {}
}
@@ -1263,13 +1185,9 @@ write -P0x76 0x3ff0000 0x10000
--- Write #1 ---
write -P0x65 0x0000000 0x10000
-{"return": ""}
write -P0x77 0x00f8000 0x10000
-{"return": ""}
write -P0x72 0x2008000 0x10000
-{"return": ""}
write -P0x69 0x3fe0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -1318,13 +1236,9 @@ expecting 6 dirty sectors; have 6. OK!
--- Write #2 ---
write -P0x74 0x0010000 0x10000
-{"return": ""}
write -P0x69 0x00e8000 0x10000
-{"return": ""}
write -P0x6e 0x2018000 0x10000
-{"return": ""}
write -P0x67 0x3fe0000 0x20000
-{"return": ""}
{
"bitmaps": {
"backup-top": [
@@ -1401,13 +1315,9 @@ expecting 7 dirty sectors; have 7. OK!
--- Write #3 ---
write -P0xaa 0x0010000 0x30000
-{"return": ""}
write -P0xbb 0x00d8000 0x10000
-{"return": ""}
write -P0xcc 0x2028000 0x10000
-{"return": ""}
write -P0xdd 0x3fc0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -1499,13 +1409,9 @@ qemu_img compare "TEST_DIR/PID-img" "TEST_DIR/PID-fbackup2" ==> Identical, OK!
--- Write #0 ---
write -P0x49 0x0000000 0x10000
-{"return": ""}
write -P0x6c 0x0100000 0x10000
-{"return": ""}
write -P0x6f 0x2000000 0x10000
-{"return": ""}
write -P0x76 0x3ff0000 0x10000
-{"return": ""}
{
"bitmaps": {}
}
@@ -1532,13 +1438,9 @@ write -P0x76 0x3ff0000 0x10000
--- Write #1 ---
write -P0x65 0x0000000 0x10000
-{"return": ""}
write -P0x77 0x00f8000 0x10000
-{"return": ""}
write -P0x72 0x2008000 0x10000
-{"return": ""}
write -P0x69 0x3fe0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -1587,13 +1489,9 @@ expecting 6 dirty sectors; have 6. OK!
--- Write #2 ---
write -P0x74 0x0010000 0x10000
-{"return": ""}
write -P0x69 0x00e8000 0x10000
-{"return": ""}
write -P0x6e 0x2018000 0x10000
-{"return": ""}
write -P0x67 0x3fe0000 0x20000
-{"return": ""}
{
"bitmaps": {
"backup-top": [
@@ -1670,13 +1568,9 @@ expecting 7 dirty sectors; have 7. OK!
--- Write #3 ---
write -P0xaa 0x0010000 0x30000
-{"return": ""}
write -P0xbb 0x00d8000 0x10000
-{"return": ""}
write -P0xcc 0x2028000 0x10000
-{"return": ""}
write -P0xdd 0x3fc0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -1768,13 +1662,9 @@ qemu_img compare "TEST_DIR/PID-img" "TEST_DIR/PID-fbackup2" ==> Identical, OK!
--- Write #0 ---
write -P0x49 0x0000000 0x10000
-{"return": ""}
write -P0x6c 0x0100000 0x10000
-{"return": ""}
write -P0x6f 0x2000000 0x10000
-{"return": ""}
write -P0x76 0x3ff0000 0x10000
-{"return": ""}
{
"bitmaps": {}
}
@@ -1801,13 +1691,9 @@ write -P0x76 0x3ff0000 0x10000
--- Write #1 ---
write -P0x65 0x0000000 0x10000
-{"return": ""}
write -P0x77 0x00f8000 0x10000
-{"return": ""}
write -P0x72 0x2008000 0x10000
-{"return": ""}
write -P0x69 0x3fe0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -1840,7 +1726,6 @@ expecting 6 dirty sectors; have 6. OK!
{"return": {}}
{"data": {"device": "ref_backup_1", "len": 67108864, "offset": 67108864, "speed": 0, "type": "backup"}, "event": "BLOCK_JOB_COMPLETED", "timestamp": {"microseconds": "USECS", "seconds": "SECS"}}
-{"return": ""}
--- Test Backup #1 ---
@@ -1877,13 +1762,9 @@ expecting 5 dirty sectors; have 5. OK!
--- Write #3 ---
write -P0xaa 0x0010000 0x30000
-{"return": ""}
write -P0xbb 0x00d8000 0x10000
-{"return": ""}
write -P0xcc 0x2028000 0x10000
-{"return": ""}
write -P0xdd 0x3fc0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -1975,13 +1856,9 @@ qemu_img compare "TEST_DIR/PID-img" "TEST_DIR/PID-fbackup2" ==> Identical, OK!
--- Write #0 ---
write -P0x49 0x0000000 0x10000
-{"return": ""}
write -P0x6c 0x0100000 0x10000
-{"return": ""}
write -P0x6f 0x2000000 0x10000
-{"return": ""}
write -P0x76 0x3ff0000 0x10000
-{"return": ""}
{
"bitmaps": {}
}
@@ -2008,13 +1885,9 @@ write -P0x76 0x3ff0000 0x10000
--- Write #1 ---
write -P0x65 0x0000000 0x10000
-{"return": ""}
write -P0x77 0x00f8000 0x10000
-{"return": ""}
write -P0x72 0x2008000 0x10000
-{"return": ""}
write -P0x69 0x3fe0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -2063,13 +1936,9 @@ expecting 6 dirty sectors; have 6. OK!
--- Write #2 ---
write -P0x74 0x0010000 0x10000
-{"return": ""}
write -P0x69 0x00e8000 0x10000
-{"return": ""}
write -P0x6e 0x2018000 0x10000
-{"return": ""}
write -P0x67 0x3fe0000 0x20000
-{"return": ""}
{
"bitmaps": {
"backup-top": [
@@ -2146,13 +2015,9 @@ expecting 7 dirty sectors; have 7. OK!
--- Write #3 ---
write -P0xaa 0x0010000 0x30000
-{"return": ""}
write -P0xbb 0x00d8000 0x10000
-{"return": ""}
write -P0xcc 0x2028000 0x10000
-{"return": ""}
write -P0xdd 0x3fc0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -2244,13 +2109,9 @@ qemu_img compare "TEST_DIR/PID-img" "TEST_DIR/PID-fbackup2" ==> Identical, OK!
--- Write #0 ---
write -P0x49 0x0000000 0x10000
-{"return": ""}
write -P0x6c 0x0100000 0x10000
-{"return": ""}
write -P0x6f 0x2000000 0x10000
-{"return": ""}
write -P0x76 0x3ff0000 0x10000
-{"return": ""}
{
"bitmaps": {}
}
@@ -2277,13 +2138,9 @@ write -P0x76 0x3ff0000 0x10000
--- Write #1 ---
write -P0x65 0x0000000 0x10000
-{"return": ""}
write -P0x77 0x00f8000 0x10000
-{"return": ""}
write -P0x72 0x2008000 0x10000
-{"return": ""}
write -P0x69 0x3fe0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -2332,13 +2189,9 @@ expecting 6 dirty sectors; have 6. OK!
--- Write #2 ---
write -P0x74 0x0010000 0x10000
-{"return": ""}
write -P0x69 0x00e8000 0x10000
-{"return": ""}
write -P0x6e 0x2018000 0x10000
-{"return": ""}
write -P0x67 0x3fe0000 0x20000
-{"return": ""}
{
"bitmaps": {
"backup-top": [
@@ -2415,13 +2268,9 @@ expecting 10 dirty sectors; have 10. OK!
--- Write #3 ---
write -P0xaa 0x0010000 0x30000
-{"return": ""}
write -P0xbb 0x00d8000 0x10000
-{"return": ""}
write -P0xcc 0x2028000 0x10000
-{"return": ""}
write -P0xdd 0x3fc0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -2513,13 +2362,9 @@ qemu_img compare "TEST_DIR/PID-img" "TEST_DIR/PID-fbackup2" ==> Identical, OK!
--- Write #0 ---
write -P0x49 0x0000000 0x10000
-{"return": ""}
write -P0x6c 0x0100000 0x10000
-{"return": ""}
write -P0x6f 0x2000000 0x10000
-{"return": ""}
write -P0x76 0x3ff0000 0x10000
-{"return": ""}
{
"bitmaps": {}
}
@@ -2546,13 +2391,9 @@ write -P0x76 0x3ff0000 0x10000
--- Write #1 ---
write -P0x65 0x0000000 0x10000
-{"return": ""}
write -P0x77 0x00f8000 0x10000
-{"return": ""}
write -P0x72 0x2008000 0x10000
-{"return": ""}
write -P0x69 0x3fe0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -2585,7 +2426,6 @@ expecting 6 dirty sectors; have 6. OK!
{"return": {}}
{"data": {"device": "ref_backup_1", "len": 67108864, "offset": 67108864, "speed": 0, "type": "backup"}, "event": "BLOCK_JOB_COMPLETED", "timestamp": {"microseconds": "USECS", "seconds": "SECS"}}
-{"return": ""}
--- Test Backup #1 ---
@@ -2622,13 +2462,9 @@ expecting 6 dirty sectors; have 6. OK!
--- Write #3 ---
write -P0xaa 0x0010000 0x30000
-{"return": ""}
write -P0xbb 0x00d8000 0x10000
-{"return": ""}
write -P0xcc 0x2028000 0x10000
-{"return": ""}
write -P0xdd 0x3fc0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -2720,13 +2556,9 @@ qemu_img compare "TEST_DIR/PID-img" "TEST_DIR/PID-fbackup2" ==> Identical, OK!
--- Write #0 ---
write -P0x49 0x0000000 0x10000
-{"return": ""}
write -P0x6c 0x0100000 0x10000
-{"return": ""}
write -P0x6f 0x2000000 0x10000
-{"return": ""}
write -P0x76 0x3ff0000 0x10000
-{"return": ""}
{
"bitmaps": {}
}
@@ -2753,13 +2585,9 @@ write -P0x76 0x3ff0000 0x10000
--- Write #1 ---
write -P0x65 0x0000000 0x10000
-{"return": ""}
write -P0x77 0x00f8000 0x10000
-{"return": ""}
write -P0x72 0x2008000 0x10000
-{"return": ""}
write -P0x69 0x3fe0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -2808,13 +2636,9 @@ expecting 6 dirty sectors; have 6. OK!
--- Write #2 ---
write -P0x74 0x0010000 0x10000
-{"return": ""}
write -P0x69 0x00e8000 0x10000
-{"return": ""}
write -P0x6e 0x2018000 0x10000
-{"return": ""}
write -P0x67 0x3fe0000 0x20000
-{"return": ""}
{
"bitmaps": {
"backup-top": [
@@ -2891,13 +2715,9 @@ expecting 7 dirty sectors; have 7. OK!
--- Write #3 ---
write -P0xaa 0x0010000 0x30000
-{"return": ""}
write -P0xbb 0x00d8000 0x10000
-{"return": ""}
write -P0xcc 0x2028000 0x10000
-{"return": ""}
write -P0xdd 0x3fc0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -2989,13 +2809,9 @@ qemu_img compare "TEST_DIR/PID-img" "TEST_DIR/PID-fbackup2" ==> Identical, OK!
--- Write #0 ---
write -P0x49 0x0000000 0x10000
-{"return": ""}
write -P0x6c 0x0100000 0x10000
-{"return": ""}
write -P0x6f 0x2000000 0x10000
-{"return": ""}
write -P0x76 0x3ff0000 0x10000
-{"return": ""}
{
"bitmaps": {}
}
@@ -3022,13 +2838,9 @@ write -P0x76 0x3ff0000 0x10000
--- Write #1 ---
write -P0x65 0x0000000 0x10000
-{"return": ""}
write -P0x77 0x00f8000 0x10000
-{"return": ""}
write -P0x72 0x2008000 0x10000
-{"return": ""}
write -P0x69 0x3fe0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -3077,13 +2889,9 @@ expecting 6 dirty sectors; have 6. OK!
--- Write #2 ---
write -P0x74 0x0010000 0x10000
-{"return": ""}
write -P0x69 0x00e8000 0x10000
-{"return": ""}
write -P0x6e 0x2018000 0x10000
-{"return": ""}
write -P0x67 0x3fe0000 0x20000
-{"return": ""}
{
"bitmaps": {
"backup-top": [
@@ -3160,13 +2968,9 @@ expecting 7 dirty sectors; have 7. OK!
--- Write #3 ---
write -P0xaa 0x0010000 0x30000
-{"return": ""}
write -P0xbb 0x00d8000 0x10000
-{"return": ""}
write -P0xcc 0x2028000 0x10000
-{"return": ""}
write -P0xdd 0x3fc0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -3258,13 +3062,9 @@ qemu_img compare "TEST_DIR/PID-img" "TEST_DIR/PID-fbackup2" ==> Identical, OK!
--- Write #0 ---
write -P0x49 0x0000000 0x10000
-{"return": ""}
write -P0x6c 0x0100000 0x10000
-{"return": ""}
write -P0x6f 0x2000000 0x10000
-{"return": ""}
write -P0x76 0x3ff0000 0x10000
-{"return": ""}
{
"bitmaps": {}
}
@@ -3291,13 +3091,9 @@ write -P0x76 0x3ff0000 0x10000
--- Write #1 ---
write -P0x65 0x0000000 0x10000
-{"return": ""}
write -P0x77 0x00f8000 0x10000
-{"return": ""}
write -P0x72 0x2008000 0x10000
-{"return": ""}
write -P0x69 0x3fe0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -3330,7 +3126,6 @@ expecting 6 dirty sectors; have 6. OK!
{"return": {}}
{"data": {"device": "ref_backup_1", "len": 67108864, "offset": 67108864, "speed": 0, "type": "backup"}, "event": "BLOCK_JOB_COMPLETED", "timestamp": {"microseconds": "USECS", "seconds": "SECS"}}
-{"return": ""}
--- Test Backup #1 ---
@@ -3367,13 +3162,9 @@ expecting 1009 dirty sectors; have 1009. OK!
--- Write #3 ---
write -P0xaa 0x0010000 0x30000
-{"return": ""}
write -P0xbb 0x00d8000 0x10000
-{"return": ""}
write -P0xcc 0x2028000 0x10000
-{"return": ""}
write -P0xdd 0x3fc0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -3465,13 +3256,9 @@ qemu_img compare "TEST_DIR/PID-img" "TEST_DIR/PID-fbackup2" ==> Identical, OK!
--- Write #0 ---
write -P0x49 0x0000000 0x10000
-{"return": ""}
write -P0x6c 0x0100000 0x10000
-{"return": ""}
write -P0x6f 0x2000000 0x10000
-{"return": ""}
write -P0x76 0x3ff0000 0x10000
-{"return": ""}
{
"bitmaps": {}
}
@@ -3498,13 +3285,9 @@ write -P0x76 0x3ff0000 0x10000
--- Write #1 ---
write -P0x65 0x0000000 0x10000
-{"return": ""}
write -P0x77 0x00f8000 0x10000
-{"return": ""}
write -P0x72 0x2008000 0x10000
-{"return": ""}
write -P0x69 0x3fe0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -3553,13 +3336,9 @@ expecting 6 dirty sectors; have 6. OK!
--- Write #2 ---
write -P0x74 0x0010000 0x10000
-{"return": ""}
write -P0x69 0x00e8000 0x10000
-{"return": ""}
write -P0x6e 0x2018000 0x10000
-{"return": ""}
write -P0x67 0x3fe0000 0x20000
-{"return": ""}
{
"bitmaps": {
"backup-top": [
@@ -3636,13 +3415,9 @@ expecting 7 dirty sectors; have 7. OK!
--- Write #3 ---
write -P0xaa 0x0010000 0x30000
-{"return": ""}
write -P0xbb 0x00d8000 0x10000
-{"return": ""}
write -P0xcc 0x2028000 0x10000
-{"return": ""}
write -P0xdd 0x3fc0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -3734,13 +3509,9 @@ qemu_img compare "TEST_DIR/PID-img" "TEST_DIR/PID-fbackup2" ==> Identical, OK!
--- Write #0 ---
write -P0x49 0x0000000 0x10000
-{"return": ""}
write -P0x6c 0x0100000 0x10000
-{"return": ""}
write -P0x6f 0x2000000 0x10000
-{"return": ""}
write -P0x76 0x3ff0000 0x10000
-{"return": ""}
{
"bitmaps": {}
}
@@ -3767,13 +3538,9 @@ write -P0x76 0x3ff0000 0x10000
--- Write #1 ---
write -P0x65 0x0000000 0x10000
-{"return": ""}
write -P0x77 0x00f8000 0x10000
-{"return": ""}
write -P0x72 0x2008000 0x10000
-{"return": ""}
write -P0x69 0x3fe0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -3822,13 +3589,9 @@ expecting 6 dirty sectors; have 6. OK!
--- Write #2 ---
write -P0x74 0x0010000 0x10000
-{"return": ""}
write -P0x69 0x00e8000 0x10000
-{"return": ""}
write -P0x6e 0x2018000 0x10000
-{"return": ""}
write -P0x67 0x3fe0000 0x20000
-{"return": ""}
{
"bitmaps": {
"backup-top": [
@@ -3905,13 +3668,9 @@ expecting 10 dirty sectors; have 10. OK!
--- Write #3 ---
write -P0xaa 0x0010000 0x30000
-{"return": ""}
write -P0xbb 0x00d8000 0x10000
-{"return": ""}
write -P0xcc 0x2028000 0x10000
-{"return": ""}
write -P0xdd 0x3fc0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -4003,13 +3762,9 @@ qemu_img compare "TEST_DIR/PID-img" "TEST_DIR/PID-fbackup2" ==> Identical, OK!
--- Write #0 ---
write -P0x49 0x0000000 0x10000
-{"return": ""}
write -P0x6c 0x0100000 0x10000
-{"return": ""}
write -P0x6f 0x2000000 0x10000
-{"return": ""}
write -P0x76 0x3ff0000 0x10000
-{"return": ""}
{
"bitmaps": {}
}
@@ -4036,13 +3791,9 @@ write -P0x76 0x3ff0000 0x10000
--- Write #1 ---
write -P0x65 0x0000000 0x10000
-{"return": ""}
write -P0x77 0x00f8000 0x10000
-{"return": ""}
write -P0x72 0x2008000 0x10000
-{"return": ""}
write -P0x69 0x3fe0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -4075,7 +3826,6 @@ expecting 6 dirty sectors; have 6. OK!
{"return": {}}
{"data": {"device": "ref_backup_1", "len": 67108864, "offset": 67108864, "speed": 0, "type": "backup"}, "event": "BLOCK_JOB_COMPLETED", "timestamp": {"microseconds": "USECS", "seconds": "SECS"}}
-{"return": ""}
--- Test Backup #1 ---
@@ -4112,13 +3862,9 @@ expecting 6 dirty sectors; have 6. OK!
--- Write #3 ---
write -P0xaa 0x0010000 0x30000
-{"return": ""}
write -P0xbb 0x00d8000 0x10000
-{"return": ""}
write -P0xcc 0x2028000 0x10000
-{"return": ""}
write -P0xdd 0x3fc0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -4210,13 +3956,9 @@ qemu_img compare "TEST_DIR/PID-img" "TEST_DIR/PID-fbackup2" ==> Identical, OK!
--- Write #0 ---
write -P0x49 0x0000000 0x10000
-{"return": ""}
write -P0x6c 0x0100000 0x10000
-{"return": ""}
write -P0x6f 0x2000000 0x10000
-{"return": ""}
write -P0x76 0x3ff0000 0x10000
-{"return": ""}
{
"bitmaps": {}
}
@@ -4243,13 +3985,9 @@ write -P0x76 0x3ff0000 0x10000
--- Write #1 ---
write -P0x65 0x0000000 0x10000
-{"return": ""}
write -P0x77 0x00f8000 0x10000
-{"return": ""}
write -P0x72 0x2008000 0x10000
-{"return": ""}
write -P0x69 0x3fe0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -4298,13 +4036,9 @@ expecting 6 dirty sectors; have 6. OK!
--- Write #2 ---
write -P0x74 0x0010000 0x10000
-{"return": ""}
write -P0x69 0x00e8000 0x10000
-{"return": ""}
write -P0x6e 0x2018000 0x10000
-{"return": ""}
write -P0x67 0x3fe0000 0x20000
-{"return": ""}
{
"bitmaps": {
"backup-top": [
@@ -4381,13 +4115,9 @@ expecting 7 dirty sectors; have 7. OK!
--- Write #3 ---
write -P0xaa 0x0010000 0x30000
-{"return": ""}
write -P0xbb 0x00d8000 0x10000
-{"return": ""}
write -P0xcc 0x2028000 0x10000
-{"return": ""}
write -P0xdd 0x3fc0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -4479,13 +4209,9 @@ qemu_img compare "TEST_DIR/PID-img" "TEST_DIR/PID-fbackup2" ==> Identical, OK!
--- Write #0 ---
write -P0x49 0x0000000 0x10000
-{"return": ""}
write -P0x6c 0x0100000 0x10000
-{"return": ""}
write -P0x6f 0x2000000 0x10000
-{"return": ""}
write -P0x76 0x3ff0000 0x10000
-{"return": ""}
{
"bitmaps": {}
}
@@ -4512,13 +4238,9 @@ write -P0x76 0x3ff0000 0x10000
--- Write #1 ---
write -P0x65 0x0000000 0x10000
-{"return": ""}
write -P0x77 0x00f8000 0x10000
-{"return": ""}
write -P0x72 0x2008000 0x10000
-{"return": ""}
write -P0x69 0x3fe0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -4567,13 +4289,9 @@ expecting 6 dirty sectors; have 6. OK!
--- Write #2 ---
write -P0x74 0x0010000 0x10000
-{"return": ""}
write -P0x69 0x00e8000 0x10000
-{"return": ""}
write -P0x6e 0x2018000 0x10000
-{"return": ""}
write -P0x67 0x3fe0000 0x20000
-{"return": ""}
{
"bitmaps": {
"backup-top": [
@@ -4650,13 +4368,9 @@ expecting 7 dirty sectors; have 7. OK!
--- Write #3 ---
write -P0xaa 0x0010000 0x30000
-{"return": ""}
write -P0xbb 0x00d8000 0x10000
-{"return": ""}
write -P0xcc 0x2028000 0x10000
-{"return": ""}
write -P0xdd 0x3fc0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -4748,13 +4462,9 @@ qemu_img compare "TEST_DIR/PID-img" "TEST_DIR/PID-fbackup2" ==> Identical, OK!
--- Write #0 ---
write -P0x49 0x0000000 0x10000
-{"return": ""}
write -P0x6c 0x0100000 0x10000
-{"return": ""}
write -P0x6f 0x2000000 0x10000
-{"return": ""}
write -P0x76 0x3ff0000 0x10000
-{"return": ""}
{
"bitmaps": {}
}
@@ -4781,13 +4491,9 @@ write -P0x76 0x3ff0000 0x10000
--- Write #1 ---
write -P0x65 0x0000000 0x10000
-{"return": ""}
write -P0x77 0x00f8000 0x10000
-{"return": ""}
write -P0x72 0x2008000 0x10000
-{"return": ""}
write -P0x69 0x3fe0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -4820,7 +4526,6 @@ expecting 6 dirty sectors; have 6. OK!
{"return": {}}
{"data": {"device": "ref_backup_1", "len": 67108864, "offset": 67108864, "speed": 0, "type": "backup"}, "event": "BLOCK_JOB_COMPLETED", "timestamp": {"microseconds": "USECS", "seconds": "SECS"}}
-{"return": ""}
--- Test Backup #1 ---
@@ -4857,13 +4562,9 @@ expecting 6 dirty sectors; have 6. OK!
--- Write #3 ---
write -P0xaa 0x0010000 0x30000
-{"return": ""}
write -P0xbb 0x00d8000 0x10000
-{"return": ""}
write -P0xcc 0x2028000 0x10000
-{"return": ""}
write -P0xdd 0x3fc0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -4955,13 +4656,9 @@ qemu_img compare "TEST_DIR/PID-img" "TEST_DIR/PID-fbackup2" ==> Identical, OK!
--- Write #0 ---
write -P0x49 0x0000000 0x10000
-{"return": ""}
write -P0x6c 0x0100000 0x10000
-{"return": ""}
write -P0x6f 0x2000000 0x10000
-{"return": ""}
write -P0x76 0x3ff0000 0x10000
-{"return": ""}
{
"bitmaps": {}
}
@@ -4988,13 +4685,9 @@ write -P0x76 0x3ff0000 0x10000
--- Write #1 ---
write -P0x65 0x0000000 0x10000
-{"return": ""}
write -P0x77 0x00f8000 0x10000
-{"return": ""}
write -P0x72 0x2008000 0x10000
-{"return": ""}
write -P0x69 0x3fe0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
@@ -5043,13 +4736,9 @@ expecting 6 dirty sectors; have 6. OK!
--- Write #2 ---
write -P0x74 0x0010000 0x10000
-{"return": ""}
write -P0x69 0x00e8000 0x10000
-{"return": ""}
write -P0x6e 0x2018000 0x10000
-{"return": ""}
write -P0x67 0x3fe0000 0x20000
-{"return": ""}
{
"bitmaps": {
"backup-top": [
@@ -5126,13 +4815,9 @@ expecting 7 dirty sectors; have 7. OK!
--- Write #3 ---
write -P0xaa 0x0010000 0x30000
-{"return": ""}
write -P0xbb 0x00d8000 0x10000
-{"return": ""}
write -P0xcc 0x2028000 0x10000
-{"return": ""}
write -P0xdd 0x3fc0000 0x10000
-{"return": ""}
{
"bitmaps": {
"drive0": [
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 36/88] qemu-iotests/260: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (34 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 35/88] qemu-iotests/257: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 37/88] qemu-iotests/280: " Marc-André Lureau
` (53 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/260 | 9 ++++-----
1 file changed, 4 insertions(+), 5 deletions(-)
diff --git a/tests/qemu-iotests/260 b/tests/qemu-iotests/260
index 65165446607c..6ca173aa020b 100755
--- a/tests/qemu-iotests/260
+++ b/tests/qemu-iotests/260
@@ -24,8 +24,7 @@ from iotests import qemu_img_create, file_path, log, filter_qmp_event
iotests.script_initialize(
supported_fmts=['qcow2'],
- unsupported_imgopts=['compat'],
- require_hmp=True,
+ unsupported_imgopts=['compat']
)
base, top = file_path('base', 'top')
@@ -55,12 +54,12 @@ def test(persistent, restart):
vm.qmp_log('block-dirty-bitmap-add', node='drive0', name='bitmap0',
persistent=persistent)
- vm.hmp_qemu_io('drive0', 'write 0 64K')
+ vm.qmp_qemu_io('drive0', 'write 0 64K')
print_bitmap('initial bitmap', vm)
vm.qmp_log('blockdev-snapshot-sync', device='drive0', snapshot_file=top,
format=iotests.imgfmt, filters=[iotests.filter_qmp_testfiles])
- vm.hmp_qemu_io('drive0', 'write 64K 512')
+ vm.qmp_qemu_io('drive0', 'write 64K 512')
print_bitmap('check that no bitmaps are in snapshot', vm)
if restart:
@@ -84,7 +83,7 @@ def test(persistent, restart):
log(filter_qmp_event(ev))
print_bitmap('check bitmap after commit', vm)
- vm.hmp_qemu_io('drive0', 'write 128K 64K')
+ vm.qmp_qemu_io('drive0', 'write 128K 64K')
print_bitmap('check updated bitmap', vm)
vm.shutdown()
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 37/88] qemu-iotests/280: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (35 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 36/88] qemu-iotests/260: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 38/88] qemu-iotests/backup-discard-source: " Marc-André Lureau
` (52 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
For consistency with the rest of the test, we use use_log=True, although
it is not stricly necessary.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/280 | 3 +--
tests/qemu-iotests/280.out | 3 ++-
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/tests/qemu-iotests/280 b/tests/qemu-iotests/280
index 8f4750de074b..ccd94905e045 100755
--- a/tests/qemu-iotests/280
+++ b/tests/qemu-iotests/280
@@ -27,7 +27,6 @@ iotests.script_initialize(
supported_fmts=['qcow2'],
supported_protocols=['file'],
supported_platforms=['linux'],
- require_hmp=True,
)
with iotests.FilePath('base') as base_path , \
@@ -77,7 +76,7 @@ with iotests.FilePath('base') as base_path , \
iotests.log('\n=== Resume the VM and simulate a write request ===')
vm.qmp_log('cont')
- iotests.log(vm.hmp_qemu_io('-d vda/virtio-backend', 'write 4k 4k'))
+ vm.qmp_qemu_io('vda/virtio-backend', 'write 4k 4k', use_log=True, qdev=True)
iotests.log('\n=== Commit it to the backing file ===')
result = vm.qmp_log('block-commit', job_id='job0', auto_dismiss=False,
diff --git a/tests/qemu-iotests/280.out b/tests/qemu-iotests/280.out
index 37411144cafe..21eff12585c1 100644
--- a/tests/qemu-iotests/280.out
+++ b/tests/qemu-iotests/280.out
@@ -36,7 +36,8 @@ completed
=== Resume the VM and simulate a write request ===
{"execute": "cont", "arguments": {}}
{"return": {}}
-{"return": ""}
+{"execute": "x-qemu-io", "arguments": {"command": "write 4k 4k", "qdev": "vda/virtio-backend"}}
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 4096\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
=== Commit it to the backing file ===
{"execute": "block-commit", "arguments": {"auto-dismiss": false, "device": "top-fmt", "job-id": "job0", "top-node": "top-fmt"}}
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 38/88] qemu-iotests/backup-discard-source: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (36 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 37/88] qemu-iotests/280: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 39/88] qemu-iotests/qsd-migrate: " Marc-André Lureau
` (51 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/tests/backup-discard-source | 15 +++++++--------
1 file changed, 7 insertions(+), 8 deletions(-)
diff --git a/tests/qemu-iotests/tests/backup-discard-source b/tests/qemu-iotests/tests/backup-discard-source
index 80ea32c46e3f..3ccd616d197e 100755
--- a/tests/qemu-iotests/tests/backup-discard-source
+++ b/tests/qemu-iotests/tests/backup-discard-source
@@ -87,11 +87,13 @@ class TestBackup(iotests.QMPTestCase):
def tearDown(self):
# That should fail, because region is discarded
- result = self.vm.hmp_qemu_io('access', 'read 0 1M')
+ result = self.vm.qmp('x-qemu-io', device='access',
+ command='read 0 1M')
self.vm.shutdown()
- self.assertIn('read failed: Permission denied', result['return'])
+ self.assertIn('read failed: Permission denied',
+ result['error']['desc'])
# Final check that temp image is empty
mapping = qemu_img_map(temp_img)
@@ -127,8 +129,7 @@ class TestBackup(iotests.QMPTestCase):
removed from temp
"""
# Trigger copy-before-write operation
- result = self.vm.hmp_qemu_io('cbw', 'write 0 1M')
- self.assert_qmp(result, 'return', '')
+ self.vm.qmp_qemu_io('cbw', 'write 0 1M')
# Check that data is written to temporary image
self.assertEqual(self.get_bitmap_count(), size)
@@ -150,8 +151,7 @@ class TestBackup(iotests.QMPTestCase):
self.vm.cmd('block-dirty-bitmap-clear', self.bitmap)
# Try trigger copy-before-write operation
- result = self.vm.hmp_qemu_io('cbw', 'write 0 1M')
- self.assert_qmp(result, 'return', '')
+ self.vm.qmp_qemu_io('cbw', 'write 0 1M')
# Check that data is not written to temporary image, as region
# is discarded from copy-before-write process
@@ -160,5 +160,4 @@ class TestBackup(iotests.QMPTestCase):
if __name__ == '__main__':
iotests.main(supported_fmts=['qcow2'],
- supported_protocols=['file'],
- require_hmp=True)
+ supported_protocols=['file'])
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 39/88] qemu-iotests/qsd-migrate: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (37 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 38/88] qemu-iotests/backup-discard-source: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 40/88] qemu-iotests/mirror-change-copy-mode: " Marc-André Lureau
` (50 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Keep the vm_src/vm_dst log, even if they should be empty now.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/tests/qsd-migrate | 23 ++++++++---------
tests/qemu-iotests/tests/qsd-migrate.out | 44 ++++++++++++--------------------
2 files changed, 27 insertions(+), 40 deletions(-)
diff --git a/tests/qemu-iotests/tests/qsd-migrate b/tests/qemu-iotests/tests/qsd-migrate
index d76278b576c2..e0b0a8f1c914 100755
--- a/tests/qemu-iotests/tests/qsd-migrate
+++ b/tests/qemu-iotests/tests/qsd-migrate
@@ -20,12 +20,11 @@
import iotests
-from iotests import filter_qemu_io, filter_qtest
+from iotests import filter_qtest
iotests.script_initialize(supported_fmts=['qcow2', 'qed', 'raw'],
supported_protocols=['file'],
- supported_platforms=['linux'],
- require_hmp=True)
+ supported_platforms=['linux'])
with iotests.FilePath('disk.img') as path, \
iotests.FilePath('nbd-src.sock', base_dir=iotests.sock_dir) as nbd_src, \
@@ -75,9 +74,9 @@ with iotests.FilePath('disk.img') as path, \
vm_dst.launch()
iotests.log('\nTest I/O on the source')
- vm_src.hmp_qemu_io('virtio0/virtio-backend', 'write -P 0x11 0 4k',
+ vm_src.qmp_qemu_io('virtio0/virtio-backend', 'write -P 0x11 0 4k',
use_log=True, qdev=True)
- vm_src.hmp_qemu_io('virtio0/virtio-backend', 'read -P 0x11 0 4k',
+ vm_src.qmp_qemu_io('virtio0/virtio-backend', 'read -P 0x11 0 4k',
use_log=True, qdev=True)
iotests.log('\nStarting migration...')
@@ -100,9 +99,9 @@ with iotests.FilePath('disk.img') as path, \
# Reading is okay from both sides while the image is inactive. Note that
# the destination may have stale data until it activates the image, though.
- vm_src.hmp_qemu_io('virtio0/virtio-backend', 'read -P 0x11 0 4k',
+ vm_src.qmp_qemu_io('virtio0/virtio-backend', 'read -P 0x11 0 4k',
use_log=True, qdev=True)
- vm_dst.hmp_qemu_io('virtio0/virtio-backend', 'read 0 4k',
+ vm_dst.qmp_qemu_io('virtio0/virtio-backend', 'read 0 4k',
use_log=True, qdev=True)
iotests.log(qsd_dst.qmp('blockdev-set-active', {'active': True}))
@@ -115,13 +114,13 @@ with iotests.FilePath('disk.img') as path, \
iotests.log('\nTest I/O on the destination')
# Now the destination must see what the source wrote
- vm_dst.hmp_qemu_io('virtio0/virtio-backend', 'read -P 0x11 0 4k',
+ vm_dst.qmp_qemu_io('virtio0/virtio-backend', 'read -P 0x11 0 4k',
use_log=True, qdev=True)
# And be able to overwrite it
- vm_dst.hmp_qemu_io('virtio0/virtio-backend', 'write -P 0x22 0 4k',
+ vm_dst.qmp_qemu_io('virtio0/virtio-backend', 'write -P 0x22 0 4k',
use_log=True, qdev=True)
- vm_dst.hmp_qemu_io('virtio0/virtio-backend', 'read -P 0x22 0 4k',
+ vm_dst.qmp_qemu_io('virtio0/virtio-backend', 'read -P 0x22 0 4k',
use_log=True, qdev=True)
iotests.log('\nDone')
@@ -130,12 +129,12 @@ with iotests.FilePath('disk.img') as path, \
iotests.log('\n--- vm_src log ---')
log = vm_src.get_log()
if log:
- iotests.log(log, [filter_qtest, filter_qemu_io])
+ iotests.log(log, [filter_qtest])
qsd_src.stop()
vm_dst.shutdown()
iotests.log('\n--- vm_dst log ---')
log = vm_dst.get_log()
if log:
- iotests.log(log, [filter_qtest, filter_qemu_io])
+ iotests.log(log, [filter_qtest])
qsd_dst.stop()
diff --git a/tests/qemu-iotests/tests/qsd-migrate.out b/tests/qemu-iotests/tests/qsd-migrate.out
index 4a5241e5d40f..e606e857ce9c 100644
--- a/tests/qemu-iotests/tests/qsd-migrate.out
+++ b/tests/qemu-iotests/tests/qsd-migrate.out
@@ -5,10 +5,10 @@ Launching destination QSD...
Launching destination VM...
Test I/O on the source
-{"execute": "human-monitor-command", "arguments": {"command-line": "qemu-io -d virtio0/virtio-backend \"write -P 0x11 0 4k\""}}
-{"return": ""}
-{"execute": "human-monitor-command", "arguments": {"command-line": "qemu-io -d virtio0/virtio-backend \"read -P 0x11 0 4k\""}}
-{"return": ""}
+{"execute": "x-qemu-io", "arguments": {"command": "write -P 0x11 0 4k", "qdev": "virtio0/virtio-backend"}}
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"execute": "x-qemu-io", "arguments": {"command": "read -P 0x11 0 4k", "qdev": "virtio0/virtio-backend"}}
+{"return": {"human-readable-text": "read 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
Starting migration...
{"execute": "migrate-set-capabilities", "arguments": {"capabilities": [{"capability": "events", "state": true}, {"capability": "pause-before-switchover", "state": true}]}}
@@ -20,10 +20,10 @@ Starting migration...
Pre-switchover: Reconfigure QSD instances
{"return": {}}
-{"execute": "human-monitor-command", "arguments": {"command-line": "qemu-io -d virtio0/virtio-backend \"read -P 0x11 0 4k\""}}
-{"return": ""}
-{"execute": "human-monitor-command", "arguments": {"command-line": "qemu-io -d virtio0/virtio-backend \"read 0 4k\""}}
-{"return": ""}
+{"execute": "x-qemu-io", "arguments": {"command": "read -P 0x11 0 4k", "qdev": "virtio0/virtio-backend"}}
+{"return": {"human-readable-text": "read 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"execute": "x-qemu-io", "arguments": {"command": "read 0 4k", "qdev": "virtio0/virtio-backend"}}
+{"return": {"human-readable-text": "read 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
{"return": {}}
Completing migration...
@@ -31,29 +31,17 @@ Completing migration...
{"return": {}}
Test I/O on the destination
-{"execute": "human-monitor-command", "arguments": {"command-line": "qemu-io -d virtio0/virtio-backend \"read -P 0x11 0 4k\""}}
-{"return": ""}
-{"execute": "human-monitor-command", "arguments": {"command-line": "qemu-io -d virtio0/virtio-backend \"write -P 0x22 0 4k\""}}
-{"return": ""}
-{"execute": "human-monitor-command", "arguments": {"command-line": "qemu-io -d virtio0/virtio-backend \"read -P 0x22 0 4k\""}}
-{"return": ""}
+{"execute": "x-qemu-io", "arguments": {"command": "read -P 0x11 0 4k", "qdev": "virtio0/virtio-backend"}}
+{"return": {"human-readable-text": "read 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"execute": "x-qemu-io", "arguments": {"command": "write -P 0x22 0 4k", "qdev": "virtio0/virtio-backend"}}
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"execute": "x-qemu-io", "arguments": {"command": "read -P 0x22 0 4k", "qdev": "virtio0/virtio-backend"}}
+{"return": {"human-readable-text": "read 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
Done
--- vm_src log ---
-wrote 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-read 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-read 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
+
--- vm_dst log ---
-read 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-read 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-wrote 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-read 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
+
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 40/88] qemu-iotests/mirror-change-copy-mode: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (38 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 39/88] qemu-iotests/qsd-migrate: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 41/88] qemu-iotests/migrate-bitmaps-test: " Marc-André Lureau
` (49 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/tests/mirror-change-copy-mode | 15 +++++++--------
1 file changed, 7 insertions(+), 8 deletions(-)
diff --git a/tests/qemu-iotests/tests/mirror-change-copy-mode b/tests/qemu-iotests/tests/mirror-change-copy-mode
index c9c345f1397c..79a6a7396450 100755
--- a/tests/qemu-iotests/tests/mirror-change-copy-mode
+++ b/tests/qemu-iotests/tests/mirror-change-copy-mode
@@ -119,8 +119,8 @@ class TestMirrorChangeCopyMode(iotests.QMPTestCase):
copy_mode='background')
def test_background_to_active(self):
- self.vm.hmp_qemu_io('source', f'write 0 {image_size}')
- self.vm.hmp_qemu_io('target', f'write 0 {image_size}')
+ self.vm.qmp_qemu_io('source', f'write 0 {image_size}')
+ self.vm.qmp_qemu_io('target', f'write 0 {image_size}')
self.start_mirror()
@@ -137,7 +137,7 @@ class TestMirrorChangeCopyMode(iotests.QMPTestCase):
req_size = image_size // reqs
for i in range(0, reqs):
req = f'aio_write -P 7 {req_size * i} {req_size}'
- self.vm.hmp_qemu_io('source', req)
+ self.vm.qmp_qemu_io('source', req)
# Wait for the first few requests.
time.sleep(1)
@@ -174,15 +174,15 @@ class TestMirrorChangeCopyMode(iotests.QMPTestCase):
req_size = image_size // 2 // reqs
for i in range(0, reqs):
req = f'aio_write -P 19 {req_size * i} {req_size}'
- self.vm.hmp_qemu_io('source', req)
+ self.vm.qmp_qemu_io('source', req)
# Now issue a synchronous write in the second half of the image and
# immediately verify that it was written to the target too. This would
# fail without switching the copy mode. Note that this only produces a
# log line and the actual checking happens during tearDown().
req_args = f'-P 37 {3 * (image_size // 4)} {req_size}'
- self.vm.hmp_qemu_io('source', f'write {req_args}')
- self.vm.hmp_qemu_io('target', f'read {req_args}')
+ self.vm.qmp_qemu_io('source', f'write {req_args}')
+ self.vm.qmp_qemu_io('target', f'read {req_args}')
self.vm.cmd('block-job-cancel', device='mirror')
while len(self.vm.cmd('query-block-jobs')) > 0:
@@ -190,5 +190,4 @@ class TestMirrorChangeCopyMode(iotests.QMPTestCase):
if __name__ == '__main__':
iotests.main(supported_fmts=['qcow2', 'raw'],
- supported_protocols=['file'],
- require_hmp=True)
+ supported_protocols=['file'])
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 41/88] qemu-iotests/migrate-bitmaps-test: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (39 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 40/88] qemu-iotests/mirror-change-copy-mode: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 42/88] qemu-iotests/image-fleecing: " Marc-André Lureau
` (48 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/tests/migrate-bitmaps-test | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/tests/qemu-iotests/tests/migrate-bitmaps-test b/tests/qemu-iotests/tests/migrate-bitmaps-test
index 25439c9eb773..f386e960afa8 100755
--- a/tests/qemu-iotests/tests/migrate-bitmaps-test
+++ b/tests/qemu-iotests/tests/migrate-bitmaps-test
@@ -95,7 +95,7 @@ class TestDirtyBitmapMigration(iotests.QMPTestCase):
self.add_bitmap(self.vm_a, granularity, persistent)
for r in regions:
- self.vm_a.hmp_qemu_io('drive0', 'write %d %d' % r)
+ self.vm_a.qmp_qemu_io('drive0', 'write %d %d' % r)
sha256 = get_bitmap_hash(self.vm_a)
self.vm_a.cmd('migrate', uri=mig_cmd)
@@ -159,7 +159,7 @@ class TestDirtyBitmapMigration(iotests.QMPTestCase):
self.add_bitmap(self.vm_a, granularity, persistent)
for r in regions:
- self.vm_a.hmp_qemu_io('drive0', 'write %d %d' % r)
+ self.vm_a.qmp_qemu_io('drive0', 'write %d %d' % r)
sha256 = get_bitmap_hash(self.vm_a)
if pre_shutdown:
@@ -215,7 +215,7 @@ class TestDirtyBitmapMigration(iotests.QMPTestCase):
self.vm_b.add_drive(disk_b, 'read-only=on')
self.add_bitmap(self.vm_a, granularity, True)
- self.vm_a.hmp_qemu_io('drive0', 'write 0 4096')
+ self.vm_a.qmp_qemu_io('drive0', 'write 0 4096')
self.vm_a.cmd('migrate-set-capabilities', capabilities=mig_caps)
self.vm_a.cmd('migrate', uri=mig_cmd)
@@ -330,7 +330,6 @@ def main() -> None:
supported_fmts=['qcow2'],
supported_protocols=['file'],
unsupported_imgopts=['compat'],
- require_hmp=True,
)
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 42/88] qemu-iotests/image-fleecing: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (40 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 41/88] qemu-iotests/migrate-bitmaps-test: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 43/88] qemu-iotests/migrate-bitmaps-postcopy: " Marc-André Lureau
` (47 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
No need to log success.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/tests/image-fleecing | 5 ++---
tests/qemu-iotests/tests/image-fleecing.out | 20 --------------------
2 files changed, 2 insertions(+), 23 deletions(-)
diff --git a/tests/qemu-iotests/tests/image-fleecing b/tests/qemu-iotests/tests/image-fleecing
index 0142289843a8..5dff00977d3e 100755
--- a/tests/qemu-iotests/tests/image-fleecing
+++ b/tests/qemu-iotests/tests/image-fleecing
@@ -32,7 +32,6 @@ iotests.script_initialize(
supported_platforms=['linux'],
required_fmts=['copy-before-write'],
unsupported_imgopts=['compat'],
- require_hmp=True,
)
patterns = [('0x5d', '0', '64k'),
@@ -209,12 +208,12 @@ def do_test(vm, use_cbw, use_snapshot_access_filter, base_img_path,
for p in overwrite:
cmd = 'write -P%s %s %s' % p
log(cmd)
- log(vm.hmp_qemu_io(qom_path, cmd, qdev=True))
+ vm.qmp_qemu_io(qom_path, cmd, qdev=True)
if push_backup:
# Check that previous operations were done during backup, not after
# If backup is already finished, it's possible that it was finished
- # even before hmp qemu_io write, and we didn't actually test
+ # even before qemu_io write, and we didn't actually test
# copy-before-write operation. This should not happen, as we use
# speed=1. But worth checking.
result = vm.qmp('query-block-jobs')
diff --git a/tests/qemu-iotests/tests/image-fleecing.out b/tests/qemu-iotests/tests/image-fleecing.out
index acfc89ff0e99..a8c19615fc6b 100644
--- a/tests/qemu-iotests/tests/image-fleecing.out
+++ b/tests/qemu-iotests/tests/image-fleecing.out
@@ -31,13 +31,9 @@ read -P0 0x3fe0000 64k
--- Testing COW ---
write -P0xab 0 64k
-{"return": ""}
write -P0xad 0x00f8000 64k
-{"return": ""}
write -P0x1d 0x2008000 64k
-{"return": ""}
write -P0xea 0x3fe0000 64k
-{"return": ""}
--- Verifying Data ---
@@ -101,13 +97,9 @@ read -P0 0x3fe0000 64k
--- Testing COW ---
write -P0xab 0 64k
-{"return": ""}
write -P0xad 0x00f8000 64k
-{"return": ""}
write -P0x1d 0x2008000 64k
-{"return": ""}
write -P0xea 0x3fe0000 64k
-{"return": ""}
--- Verifying Data ---
@@ -172,13 +164,9 @@ read -P0 0x3fe0000 64k
--- Testing COW ---
write -P0xab 0 64k
-{"return": ""}
write -P0xad 0x00f8000 64k
-{"return": ""}
write -P0x1d 0x2008000 64k
-{"return": ""}
write -P0xea 0x3fe0000 64k
-{"return": ""}
--- Verifying Data ---
@@ -250,13 +238,9 @@ read failed: Invalid argument
--- Testing COW ---
write -P0xab 0 64k
-{"return": ""}
write -P0xad 0x00f8000 64k
-{"return": ""}
write -P0x1d 0x2008000 64k
-{"return": ""}
write -P0xea 0x3fe0000 64k
-{"return": ""}
--- Verifying Data ---
@@ -318,13 +302,9 @@ Done
--- Testing COW ---
write -P0xab 0 64k
-{"return": ""}
write -P0xad 0x00f8000 64k
-{"return": ""}
write -P0x1d 0x2008000 64k
-{"return": ""}
write -P0xea 0x3fe0000 64k
-{"return": ""}
{"data": {"device": "push-backup", "len": 67108864, "offset": 67108864, "speed": 0, "type": "backup"}, "event": "BLOCK_JOB_COMPLETED", "timestamp": {"microseconds": "USECS", "seconds": "SECS"}}
{"return": {}}
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 43/88] qemu-iotests/migrate-bitmaps-postcopy: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (41 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 42/88] qemu-iotests/image-fleecing: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 44/88] qemu-iotests/165: " Marc-André Lureau
` (46 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/tests/migrate-bitmaps-postcopy-test | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/tests/qemu-iotests/tests/migrate-bitmaps-postcopy-test b/tests/qemu-iotests/tests/migrate-bitmaps-postcopy-test
index b2b37ada4b27..6a424835d9f1 100755
--- a/tests/qemu-iotests/tests/migrate-bitmaps-postcopy-test
+++ b/tests/qemu-iotests/tests/migrate-bitmaps-postcopy-test
@@ -52,7 +52,7 @@ discards2 = (
def apply_discards(vm, discards):
for d in discards:
- vm.hmp_qemu_io('drive0', 'discard {} {}'.format(*d))
+ vm.qmp_qemu_io('drive0', 'discard {} {}'.format(*d))
def event_seconds(event):
@@ -279,5 +279,4 @@ class TestDirtyBitmapPostcopyMigration(iotests.QMPTestCase):
if __name__ == '__main__':
iotests.main(supported_fmts=['qcow2'],
- unsupported_imgopts=['compat'],
- require_hmp=True)
+ unsupported_imgopts=['compat'])
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 44/88] qemu-iotests/165: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (42 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 43/88] qemu-iotests/migrate-bitmaps-postcopy: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 45/88] qemu-iotests/iothreads-create: doesn't actually depend on HMP Marc-André Lureau
` (45 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
For the read-only write test, call qmp() directly and assert
the expected GenericError, since qmp_qemu_io() assumes success.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/165 | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/tests/qemu-iotests/165 b/tests/qemu-iotests/165
index 13b784fcc64d..e1e557424cec 100755
--- a/tests/qemu-iotests/165
+++ b/tests/qemu-iotests/165
@@ -66,7 +66,7 @@ class TestPersistentDirtyBitmap(iotests.QMPTestCase):
def writeRegions(self, regions):
for r in regions:
- self.vm.hmp_qemu_io('drive0',
+ self.vm.qmp_qemu_io('drive0',
'write %d %d' % r)
def qmpAddBitmap(self):
@@ -138,7 +138,10 @@ class TestPersistentDirtyBitmap(iotests.QMPTestCase):
assert sha256_1 == self.getSha256()
# Check that we are in RO mode and can't modify bitmap.
- self.writeRegions(regions2)
+ for r in regions2:
+ result = self.vm.qmp('x-qemu-io', device='drive0',
+ command='write %d %d' % r)
+ self.assert_qmp(result, 'error/class', 'GenericError')
assert sha256_1 == self.getSha256()
# Reopen to RW
@@ -162,5 +165,4 @@ class TestPersistentDirtyBitmap(iotests.QMPTestCase):
if __name__ == '__main__':
iotests.main(supported_fmts=['qcow2', 'parallels'],
supported_protocols=['file'],
- unsupported_imgopts=['compat'],
- require_hmp=True)
+ unsupported_imgopts=['compat'])
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 45/88] qemu-iotests/iothreads-create: doesn't actually depend on HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (43 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 44/88] qemu-iotests/165: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 46/88] qemu-iotests/045: remove HMP monitor dependency Marc-André Lureau
` (44 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Fixes: 73baa14be2d5 ("tests: skip HMP-dependent tests when HMP is disabled")
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/tests/iothreads-create | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/tests/qemu-iotests/tests/iothreads-create b/tests/qemu-iotests/tests/iothreads-create
index 09fe57a09ac0..0c862d73f20e 100755
--- a/tests/qemu-iotests/tests/iothreads-create
+++ b/tests/qemu-iotests/tests/iothreads-create
@@ -22,8 +22,7 @@ import asyncio
import iotests
iotests.script_initialize(supported_fmts=['qcow2', 'qcow', 'qed', 'vdi',
- 'vmdk', 'parallels'],
- require_hmp=True)
+ 'vmdk', 'parallels'])
iotests.verify_virtio_scsi_pci_or_ccw()
with iotests.FilePath('disk.img') as img_path, \
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 46/88] qemu-iotests/045: remove HMP monitor dependency
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (44 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 45/88] qemu-iotests/iothreads-create: doesn't actually depend on HMP Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 21:06 ` John Snow
2026-09-22 20:17 ` [PATCH 47/88] qemu-iotests/common: add _run_qmp_job helper Marc-André Lureau
` (43 subsequent siblings)
89 siblings, 1 reply; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel
Cc: Kevin Wolf, Marc-André Lureau, John Snow, Cleber Rosa,
Hanna Reitz, qemu-block
Test 045 (TestSCMFd) is adding a null HMP monitor via
add_monitor_null() to exercise fd operations with two monitors
present. With HMP disabled, -monitor null is no longer valid.
Remove the add_monitor_null() call and the now-unused method
from the Python machine module.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
python/qemu/machine/machine.py | 7 -------
tests/qemu-iotests/045 | 6 +-----
2 files changed, 1 insertion(+), 12 deletions(-)
diff --git a/python/qemu/machine/machine.py b/python/qemu/machine/machine.py
index 393750655589..71b4696227f6 100644
--- a/python/qemu/machine/machine.py
+++ b/python/qemu/machine/machine.py
@@ -202,13 +202,6 @@ def __exit__(self,
exc_tb: Optional[TracebackType]) -> None:
self.shutdown()
- def add_monitor_null(self) -> None:
- """
- This can be used to add an unused monitor instance.
- """
- self._args.append('-monitor')
- self._args.append('null')
-
def add_fd(self: _T, fd: int, fdset: int,
opaque: str, opts: str = '') -> _T:
"""
diff --git a/tests/qemu-iotests/045 b/tests/qemu-iotests/045
index cd1b35edb17f..900bf85220f7 100755
--- a/tests/qemu-iotests/045
+++ b/tests/qemu-iotests/045
@@ -129,9 +129,6 @@ class TestSCMFd(iotests.QMPTestCase):
def setUp(self):
self.vm = iotests.VM()
qemu_img('create', '-f', iotests.imgfmt, image0, '128K')
- # Add an unused monitor, to verify it works fine when two monitor
- # instances present
- self.vm.add_monitor_null()
self.vm.launch()
def tearDown(self):
@@ -172,5 +169,4 @@ class TestSCMFd(iotests.QMPTestCase):
if __name__ == '__main__':
iotests.main(supported_fmts=['raw'],
- supported_protocols=['file'],
- require_hmp=True)
+ supported_protocols=['file'])
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* Re: [PATCH 46/88] qemu-iotests/045: remove HMP monitor dependency
2026-09-22 20:17 ` [PATCH 46/88] qemu-iotests/045: remove HMP monitor dependency Marc-André Lureau
@ 2026-09-22 21:06 ` John Snow
0 siblings, 0 replies; 98+ messages in thread
From: John Snow @ 2026-09-22 21:06 UTC (permalink / raw)
To: Marc-André Lureau
Cc: qemu-devel, Kevin Wolf, Cleber Rosa, Hanna Reitz, qemu-block
On Tue, Sep 22, 2026 at 4:21 PM Marc-André Lureau
<marcandre.lureau@redhat.com> wrote:
>
> Test 045 (TestSCMFd) is adding a null HMP monitor via
> add_monitor_null() to exercise fd operations with two monitors
> present. With HMP disabled, -monitor null is no longer valid.
>
> Remove the add_monitor_null() call and the now-unused method
> from the Python machine module.
>
> Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
> ---
> python/qemu/machine/machine.py | 7 -------
> tests/qemu-iotests/045 | 6 +-----
> 2 files changed, 1 insertion(+), 12 deletions(-)
>
> diff --git a/python/qemu/machine/machine.py b/python/qemu/machine/machine.py
> index 393750655589..71b4696227f6 100644
> --- a/python/qemu/machine/machine.py
> +++ b/python/qemu/machine/machine.py
> @@ -202,13 +202,6 @@ def __exit__(self,
> exc_tb: Optional[TracebackType]) -> None:
> self.shutdown()
>
> - def add_monitor_null(self) -> None:
> - """
> - This can be used to add an unused monitor instance.
> - """
> - self._args.append('-monitor')
> - self._args.append('null')
> -
> def add_fd(self: _T, fd: int, fdset: int,
> opaque: str, opts: str = '') -> _T:
> """
Fine by me so long as block folks are okay with dropping that part of the test.
ACK
> diff --git a/tests/qemu-iotests/045 b/tests/qemu-iotests/045
> index cd1b35edb17f..900bf85220f7 100755
> --- a/tests/qemu-iotests/045
> +++ b/tests/qemu-iotests/045
> @@ -129,9 +129,6 @@ class TestSCMFd(iotests.QMPTestCase):
> def setUp(self):
> self.vm = iotests.VM()
> qemu_img('create', '-f', iotests.imgfmt, image0, '128K')
> - # Add an unused monitor, to verify it works fine when two monitor
> - # instances present
> - self.vm.add_monitor_null()
> self.vm.launch()
>
> def tearDown(self):
> @@ -172,5 +169,4 @@ class TestSCMFd(iotests.QMPTestCase):
>
> if __name__ == '__main__':
> iotests.main(supported_fmts=['raw'],
> - supported_protocols=['file'],
> - require_hmp=True)
> + supported_protocols=['file'])
>
> --
> 2.56.0.rc0.29.g47ce80527c56
>
^ permalink raw reply [flat|nested] 98+ messages in thread
* [PATCH 47/88] qemu-iotests/common: add _run_qmp_job helper
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (45 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 46/88] qemu-iotests/045: remove HMP monitor dependency Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 48/88] qemu-iotests/007: migrate away from HMP Marc-André Lureau
` (42 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/common.qemu | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)
diff --git a/tests/qemu-iotests/common.qemu b/tests/qemu-iotests/common.qemu
index e5b6a6a87494..458ea9566818 100644
--- a/tests/qemu-iotests/common.qemu
+++ b/tests/qemu-iotests/common.qemu
@@ -287,6 +287,28 @@ _wait_event()
done
}
+# Run a QMP job command and wait for it to complete
+#
+# Sends the given QMP command, waits for the job to reach
+# "concluded" status, then dismisses it.
+#
+# $1: QEMU handle
+# $2: Job ID (must match the job-id in the command)
+# $3: QMP command string to send
+_run_qmp_job()
+{
+ local h=${1}
+ local job_id=${2}
+ local cmd=${3}
+
+ _send_qemu_cmd $h "$cmd" 'return'
+ _send_qemu_cmd $h '' '"concluded"'
+ _send_qemu_cmd $h \
+ "{ 'execute': 'job-dismiss',
+ 'arguments': { 'id': '$job_id' } }" 'return'
+}
+
+
# Launch a QEMU process.
#
# Input parameters:
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 48/88] qemu-iotests/007: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (46 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 47/88] qemu-iotests/common: add _run_qmp_job helper Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 49/88] qemu-iotests/028: " Marc-André Lureau
` (41 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Replace HMP 'savevm' with QMP 'snapshot-save' job-based API.
Use _launch_qemu/_send_qemu_cmd for proper QMP interaction.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/007 | 25 +++++++++++++++++++------
1 file changed, 19 insertions(+), 6 deletions(-)
diff --git a/tests/qemu-iotests/007 b/tests/qemu-iotests/007
index 936d3f14fbad..06096149ce83 100755
--- a/tests/qemu-iotests/007
+++ b/tests/qemu-iotests/007
@@ -29,6 +29,7 @@ status=1 # failure is the default!
_cleanup()
{
+ _cleanup_qemu
_cleanup_test_img
true
}
@@ -37,6 +38,7 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
# get standard environment, filters and checks
. ./common.rc
. ./common.filter
+. ./common.qemu
# currently only qcow2 allows for consistency checks using qemu-img
_supported_fmt qcow2
@@ -50,12 +52,23 @@ echo
echo "creating image"
_make_test_img 1M
-for ((i=1;i<=10;i++)); do
- echo "savevm $i"
- $QEMU -nographic -hda "$TEST_IMG" -serial none -monitor stdio >/dev/null 2>&1 <<EOF
-savevm test-$i
-quit
-EOF
+silent=yes
+for ((n=1;n<=10;n++)); do
+ echo "savevm $n"
+ _launch_qemu \
+ -drive if=none,id=drive0,node-name=disk0,file="$TEST_IMG",format="$IMGFMT" \
+ -device virtio-scsi,id=hba0 -device scsi-hd,drive=drive0
+ _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'qmp_capabilities' }" 'return'
+ _run_qmp_job $QEMU_HANDLE 'save' \
+ "{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save',
+ 'tag': 'test-$n',
+ 'vmstate': 'disk0',
+ 'devices': ['disk0'] } }"
+ _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'quit' }" 'return'
+ _cleanup_qemu
done
echo
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 49/88] qemu-iotests/028: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (47 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 48/88] qemu-iotests/007: migrate away from HMP Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-23 20:30 ` Stefan Hajnoczi
2026-09-22 20:17 ` [PATCH 50/88] qemu-iotests/225: " Marc-André Lureau
` (40 subsequent siblings)
89 siblings, 1 reply; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Replace HMP drive_backup, info block-jobs, and quit with their QMP
equivalents (drive-backup, query-block-jobs, quit). Capture
BLOCK_JOB_COMPLETED and JOB_STATUS_CHANGE events during polling
to keep the output clean.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/028 | 27 ++++++++++++++++++++-------
tests/qemu-iotests/028.out | 17 +++++++++++++----
2 files changed, 33 insertions(+), 11 deletions(-)
diff --git a/tests/qemu-iotests/028 b/tests/qemu-iotests/028
index 28f01439c525..e570c3d303d5 100755
--- a/tests/qemu-iotests/028
+++ b/tests/qemu-iotests/028
@@ -49,7 +49,6 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
_supported_fmt qcow2 qed
_supported_proto file fuse
_supported_os Linux
-_require_hmp
# Choose a size that is not necessarily a cluster size multiple for image
# formats that use clusters. This will ensure that the base image doesn't end
@@ -109,7 +108,6 @@ echo
echo block-backup
echo
-qemu_comm_method="monitor"
_launch_qemu -drive file="${TEST_IMG}",cache=${CACHEMODE},aio=${AIOMODE},id=disk
h=$QEMU_HANDLE
if [ "${VALGRIND_QEMU}" == "y" ]; then
@@ -119,12 +117,27 @@ else
fi
TEST_IMG="$TEST_IMG.copy" _make_test_img $image_size
-_send_qemu_cmd $h "drive_backup -n disk ${TEST_IMG}.copy" "(qemu)" \
- | _filter_imgfmt
-silent=y qemu_cmd_repeat=20 _send_qemu_cmd $h "info block-jobs" "No active jobs"
-_send_qemu_cmd $h "info block-jobs" "No active jobs"
-_send_qemu_cmd $h 'quit' ""
+_send_qemu_cmd $h "{ 'execute': 'qmp_capabilities' }" 'return'
+
+capture_events="BLOCK_JOB_COMPLETED JOB_STATUS_CHANGE" \
+_send_qemu_cmd $h \
+ "{ 'execute': 'drive-backup',
+ 'arguments': { 'device': 'disk',
+ 'target': '${TEST_IMG}.copy',
+ 'sync': 'full',
+ 'mode': 'existing' } }" \
+ "return"
+
+capture_events="BLOCK_JOB_COMPLETED JOB_STATUS_CHANGE" \
+silent=y qemu_cmd_repeat=20 _send_qemu_cmd $h \
+ '{"execute":"query-block-jobs"}' '"return": \[\]'
+
+capture_events="BLOCK_JOB_COMPLETED JOB_STATUS_CHANGE" \
+_send_qemu_cmd $h '{"execute":"query-block-jobs"}' '"return": \[\]'
+
+_send_qemu_cmd $h '{"execute":"quit"}' 'return'
+wait=1 _cleanup_qemu
# Base image sectors
TEST_IMG="${TEST_IMG}.copy" io readv $(( offset )) 512 1024 32
diff --git a/tests/qemu-iotests/028.out b/tests/qemu-iotests/028.out
index e58048821686..0c63b15360f3 100644
--- a/tests/qemu-iotests/028.out
+++ b/tests/qemu-iotests/028.out
@@ -469,10 +469,19 @@ No errors were found on the image.
block-backup
Formatting 'TEST_DIR/t.IMGFMT.copy', fmt=IMGFMT size=4294968832
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) drive_backup -n disk TEST_DIR/t.IMGFMT.copy
-(qemu) info block-jobs
-No active jobs
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'drive-backup',
+ 'arguments': { 'device': 'disk',
+ 'target': 'TEST_DIR/t.IMGFMT.copy',
+ 'sync': 'full',
+ 'mode': 'existing' } }
+{"return": {}}
+{"execute":"query-block-jobs"}
+{"return": []}
+{"execute":"quit"}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
=== IO: pattern 195
read 512/512 bytes at offset 3221194240
512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* Re: [PATCH 49/88] qemu-iotests/028: migrate away from HMP
2026-09-22 20:17 ` [PATCH 49/88] qemu-iotests/028: " Marc-André Lureau
@ 2026-09-23 20:30 ` Stefan Hajnoczi
0 siblings, 0 replies; 98+ messages in thread
From: Stefan Hajnoczi @ 2026-09-23 20:30 UTC (permalink / raw)
To: Marc-André Lureau; +Cc: qemu-devel, Kevin Wolf, Hanna Reitz, qemu-block
[-- Attachment #1: Type: text/plain, Size: 601 bytes --]
On Wed, Sep 23, 2026 at 12:17:56AM +0400, Marc-André Lureau wrote:
> Replace HMP drive_backup, info block-jobs, and quit with their QMP
> equivalents (drive-backup, query-block-jobs, quit). Capture
> BLOCK_JOB_COMPLETED and JOB_STATUS_CHANGE events during polling
> to keep the output clean.
>
> Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
> ---
> tests/qemu-iotests/028 | 27 ++++++++++++++++++++-------
> tests/qemu-iotests/028.out | 17 +++++++++++++----
> 2 files changed, 33 insertions(+), 11 deletions(-)
Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 98+ messages in thread
* [PATCH 50/88] qemu-iotests/225: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (48 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 49/88] qemu-iotests/028: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 51/88] qemu-iotests/300: " Marc-André Lureau
` (39 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/225 | 28 ++++++++++++++++++----------
tests/qemu-iotests/225.out | 25 +++++++++++++++----------
2 files changed, 33 insertions(+), 20 deletions(-)
diff --git a/tests/qemu-iotests/225 b/tests/qemu-iotests/225
index 8128d583d609..9ec2741ecd8e 100755
--- a/tests/qemu-iotests/225
+++ b/tests/qemu-iotests/225
@@ -46,7 +46,6 @@ _supported_os Linux
_unsupported_imgopts "subformat=monolithicFlat" \
"subformat=twoGbMaxExtentFlat" \
"subformat=twoGbMaxExtentSparse"
-_require_hmp
TEST_IMG="$TEST_IMG.base" _make_test_img 1M
TEST_IMG="$TEST_IMG.not_base" _make_test_img 1M
@@ -83,11 +82,14 @@ echo
echo '=== Testing fitting VMDK backing image ==='
echo
-qemu_comm_method=monitor \
- _launch_qemu -blockdev "$base_opts" -blockdev "$overlay_opts"
+_launch_qemu -blockdev "$base_opts" -blockdev "$overlay_opts"
+_send_qemu_cmd $QEMU_HANDLE "{ 'execute': 'qmp_capabilities' }" "return"
# Should not return an error
-_send_qemu_cmd $QEMU_HANDLE 'qemu-io overlay "read 0 512"' 'ops'
+_send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'overlay', 'command': 'read 0 512' } }" \
+ "return"
_cleanup_qemu
@@ -96,11 +98,14 @@ echo
echo '=== Testing unrelated VMDK backing image ==='
echo
-qemu_comm_method=monitor \
- _launch_qemu -blockdev "$not_base_opts" -blockdev "$overlay_opts"
+_launch_qemu -blockdev "$not_base_opts" -blockdev "$overlay_opts"
+_send_qemu_cmd $QEMU_HANDLE "{ 'execute': 'qmp_capabilities' }" "return"
# Should fail (gracefully)
-_send_qemu_cmd $QEMU_HANDLE 'qemu-io overlay "read 0 512"' 'failed'
+_send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'overlay', 'command': 'read 0 512' } }" \
+ "error"
_cleanup_qemu
@@ -118,11 +123,14 @@ echo
# this a FIXME because with -blockdev, you cannot specify "partial"
# options, so setting file.filename but leaving the rest as specified
# by the user does not make sense.
-qemu_comm_method=monitor \
- _launch_qemu -blockdev "$not_vmdk_opts" -blockdev "$overlay_opts"
+_launch_qemu -blockdev "$not_vmdk_opts" -blockdev "$overlay_opts"
+_send_qemu_cmd $QEMU_HANDLE "{ 'execute': 'qmp_capabilities' }" "return"
# Should fail (gracefully)
-_send_qemu_cmd $QEMU_HANDLE 'qemu-io overlay "read 0 512"' 'failed'
+_send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'overlay', 'command': 'read 0 512' } }" \
+ "error"
_cleanup_qemu
diff --git a/tests/qemu-iotests/225.out b/tests/qemu-iotests/225.out
index beb8c23bd330..a5815afd0f0c 100644
--- a/tests/qemu-iotests/225.out
+++ b/tests/qemu-iotests/225.out
@@ -5,20 +5,25 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1048576 backing_file=TEST_DIR/t.
=== Testing fitting VMDK backing image ===
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io overlay "read 0 512"
-read 512/512 bytes at offset 0
-512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'overlay', 'command': 'read 0 512' } }
+{"return": {"human-readable-text": "read 512/512 bytes at offset 0\n512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
=== Testing unrelated VMDK backing image ===
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io overlay "read 0 512"
-Error: read failed: Invalid argument
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'overlay', 'command': 'read 0 512' } }
+{"error": {"class": "GenericError", "desc": "read failed: Invalid argument"}}
=== Testing non-VMDK backing image ===
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io overlay "read 0 512"
-Error: read failed: Invalid argument
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'overlay', 'command': 'read 0 512' } }
+{"error": {"class": "GenericError", "desc": "read failed: Invalid argument"}}
*** done
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 51/88] qemu-iotests/300: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (49 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 50/88] qemu-iotests/225: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:17 ` [PATCH 52/88] qemu-iotests/286: " Marc-André Lureau
` (38 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Migrate away from HMP "info migrate_parameters", and use QMP
query-migrate-parameters instead. We no longer check HMP formatting
output though, but this is not meant to be a testable interface.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/300 | 32 ++++++--------------------------
1 file changed, 6 insertions(+), 26 deletions(-)
diff --git a/tests/qemu-iotests/300 b/tests/qemu-iotests/300
index bcc6fa972581..c6a7519b67ce 100755
--- a/tests/qemu-iotests/300
+++ b/tests/qemu-iotests/300
@@ -21,7 +21,6 @@
import os
import random
-import re
from typing import Dict, List, Optional
import iotests
@@ -136,8 +135,8 @@ class TestDirtyBitmapMigration(iotests.QMPTestCase):
Invoke migrate-set-parameters on @vm to set the given @mapping.
Check for success if @error is None, or verify the error message
if it is not.
- On success, verify that "info migrate_parameters" on HMP returns
- our mapping. (Just to check its formatting code.)
+ On success, verify that query-migrate-parameters returns
+ our mapping.
"""
result = vm.qmp('migrate-set-parameters',
block_bitmap_mapping=mapping)
@@ -145,30 +144,12 @@ class TestDirtyBitmapMigration(iotests.QMPTestCase):
if error is None:
self.assert_qmp(result, 'return', {})
- result = vm.qmp('human-monitor-command',
- command_line='info migrate_parameters')
-
- m = re.search(r'^block-bitmap-mapping:\r?(\n .*)*\n',
- result['return'], flags=re.MULTILINE)
- hmp_mapping = m.group(0).replace('\r', '') if m else None
-
- self.assertEqual(hmp_mapping, self.to_hmp_mapping(mapping))
+ result = vm.qmp('query-migrate-parameters')
+ qmp_mapping = result['return'].get('block-bitmap-mapping')
+ self.assertEqual(qmp_mapping, mapping)
else:
self.assert_qmp(result, 'error/desc', error)
- @staticmethod
- def to_hmp_mapping(mapping: BlockBitmapMapping) -> str:
- result = 'block-bitmap-mapping:\n'
-
- for node in mapping:
- result += f" '{node['node-name']}' -> '{node['alias']}'\n"
-
- assert isinstance(node['bitmaps'], list)
- for bitmap in node['bitmaps']:
- result += f" '{bitmap['name']}' -> '{bitmap['alias']}'\n"
-
- return result
-
class TestAliasMigration(TestDirtyBitmapMigration):
src_node_name = 'node0'
@@ -683,5 +664,4 @@ class TestAliasTransformMigration(TestDirtyBitmapMigration):
self.verify_dest_error(None)
if __name__ == '__main__':
- iotests.main(supported_protocols=['file'],
- require_hmp=True)
+ iotests.main(supported_protocols=['file'])
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 52/88] qemu-iotests/286: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (50 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 51/88] qemu-iotests/300: " Marc-André Lureau
@ 2026-09-22 20:17 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 53/88] qemu-iotests/142: " Marc-André Lureau
` (37 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:17 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Replaced qemu_comm_method=monitor _launch_qemu -m 512 "$TEST_IMG" with
_launch_qemu using -blockdev to set explicit node names (disk0-file and
disk0), and HMP savevm with QMP snapshot-save (job-based), waiting for
"concluded" status.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/286 | 15 +++++++++++----
tests/qemu-iotests/286.out | 8 +++++---
2 files changed, 16 insertions(+), 7 deletions(-)
diff --git a/tests/qemu-iotests/286 b/tests/qemu-iotests/286
index 3b030ec58aa0..565a960e9eb3 100755
--- a/tests/qemu-iotests/286
+++ b/tests/qemu-iotests/286
@@ -40,7 +40,6 @@ _supported_proto file fuse
# Internal snapshots are (currently) impossible with refcount_bits=1,
# and generally impossible with external data files
_unsupported_imgopts 'refcount_bits=1[^0-9]' data_file
-_require_hmp
_make_test_img 64M
@@ -49,10 +48,18 @@ sn_name=abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyz
# More memory will give us a larger VM state, i.e. one above 1 MB.
# This way, we get a number with a decimal point.
-qemu_comm_method=monitor _launch_qemu -m 512 "$TEST_IMG"
+_launch_qemu -m 512 \
+ -blockdev driver=file,filename="$TEST_IMG",node-name=disk0-file \
+ -blockdev driver=$IMGFMT,file=disk0-file,node-name=disk0
-_send_qemu_cmd $QEMU_HANDLE "savevm $sn_name" '(qemu)'
-_send_qemu_cmd $QEMU_HANDLE 'quit' '(qemu)'
+_send_qemu_cmd $QEMU_HANDLE "{ 'execute': 'qmp_capabilities' }" 'return'
+silent=yes _run_qmp_job $QEMU_HANDLE 'save0' \
+ "{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save0',
+ 'tag': '$sn_name',
+ 'vmstate': 'disk0',
+ 'devices': ['disk0'] } }"
+_send_qemu_cmd $QEMU_HANDLE "{ 'execute': 'quit' }" 'return'
wait=yes _cleanup_qemu
# Check that all fields are separated by spaces.
diff --git a/tests/qemu-iotests/286.out b/tests/qemu-iotests/286.out
index bb04748e0808..33f1905a45ce 100644
--- a/tests/qemu-iotests/286.out
+++ b/tests/qemu-iotests/286.out
@@ -1,8 +1,10 @@
QA output created by 286
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) savevm abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyz
-(qemu) quit
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Output structure:
(snapshot ID) (snapshot name) (VM state size value) (VM state size unit) (snapshot date) (snapshot time) (VM clock) (icount)
*** done
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 53/88] qemu-iotests/142: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (51 preceding siblings ...)
2026-09-22 20:17 ` [PATCH 52/88] qemu-iotests/286: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 54/88] qemu-iotests/146: " Marc-André Lureau
` (36 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Replace the HMP monitor (-monitor stdio) with QMP (-qmp stdio) for
testing cache mode configuration and inheritance.
The main changes are:
- Use query-block and query-named-block-nodes QMP commands instead of
HMP "info block" to retrieve cache settings.
- Introduce _filter_qmp_cache(), a Python helper that parses QMP
responses and prints cache modes. Device names are looked up in
query-block (backend-level cache) while node names are looked up in
query-named-block-nodes (BDS-level cache), preserving the same
semantics as HMP "info block <name>".
- Use QMP blockdev-snapshot-sync instead of HMP snapshot_blkdev.
- Use QMP x-qemu-io instead of HMP qemu-io for reopen operations.
The expected output changes only in formatting (QMP banners and JSON
responses replacing HMP banners).
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/142 | 233 ++++++++++++++++++++++++++-------------------
tests/qemu-iotests/142.out | 30 ++++--
2 files changed, 157 insertions(+), 106 deletions(-)
diff --git a/tests/qemu-iotests/142 b/tests/qemu-iotests/142
index 8538a727ac08..7a88c63d4acb 100755
--- a/tests/qemu-iotests/142
+++ b/tests/qemu-iotests/142
@@ -43,25 +43,92 @@ _supported_proto file
# We test all cache modes anyway, but O_DIRECT needs to be supported
_default_cache_mode none
_supported_cache_modes none directsync
-_require_hmp
do_run_qemu()
{
- echo Testing: "$@"
(
+ echo "{ 'execute': 'qmp_capabilities' }"
if ! test -t 0; then
while read cmd; do
- echo $cmd
+ echo "$cmd"
done
fi
- echo quit
- ) | $QEMU -nographic -monitor stdio -nodefaults "$@"
- echo
+ echo "{ 'execute': 'quit' }"
+ ) | $QEMU -nographic -qmp stdio -nodefaults "$@" 2>&1
}
run_qemu()
{
- do_run_qemu "$@" 2>&1 | _filter_testdir | _filter_qemu | _filter_hmp
+ (
+ echo Testing: "$@"
+ do_run_qemu "$@" | _filter_qmp
+ ) | _filter_testdir | _filter_qemu
+ echo
+}
+
+# Extract cache info from query-block and query-named-block-nodes QMP
+# output. For each name passed as argument, prints its cache mode.
+# Device names are looked up in query-block (backend-level cache).
+# Node names are looked up in query-named-block-nodes (BDS-level cache).
+# Non-JSON lines (startup errors) are passed through.
+_filter_qmp_cache()
+{
+ local nodes=("$@")
+ python3 -c '
+import sys, json
+
+nodes = sys.argv[1:]
+lines = sys.stdin.read().strip().split("\n")
+
+cache_map = {}
+for line in lines:
+ line = line.strip()
+ if not line.startswith("{"):
+ if line and not line.startswith("Formatting"):
+ print(line)
+ continue
+ try:
+ resp = json.loads(line)
+ except json.JSONDecodeError:
+ continue
+ if "error" in resp:
+ print(resp["error"]["desc"])
+ continue
+ ret = resp.get("return")
+ if not isinstance(ret, list):
+ continue
+ for entry in ret:
+ if not isinstance(entry, dict):
+ continue
+ device = entry.get("device")
+ inserted = entry.get("inserted") if device is not None else entry
+ if inserted is None:
+ continue
+ cache = inserted.get("cache")
+ if cache is None:
+ continue
+ node_name = inserted.get("node-name", "")
+ if device is not None and device in nodes:
+ cache_map[device] = cache
+ elif device is None and node_name in nodes and node_name not in cache_map:
+ cache_map[node_name] = cache
+
+for name in nodes:
+ if name in cache_map:
+ c = cache_map[name]
+ mode = "writeback" if c["writeback"] else "writethrough"
+ if c["direct"]:
+ mode += ", direct"
+ if c["no-flush"]:
+ mode += ", ignore flushes"
+ print(" Cache mode: %s" % mode)
+' "${nodes[@]}"
+}
+
+run_qemu_cache()
+{
+ do_run_qemu "$@" | _filter_qmp_cache $cache_nodes | \
+ _filter_testdir | _filter_qemu
}
size=128M
@@ -88,42 +155,45 @@ echo
files="if=none,file=$TEST_IMG,backing.file.filename=$TEST_IMG.base"
ids="node-name=image,backing.node-name=backing,backing.file.node-name=backing-file,file.node-name=file"
+qmp_query="{ 'execute': 'query-block' }
+{ 'execute': 'query-named-block-nodes' }"
+
check_cache_all()
{
# cache.direct is supposed to be inherited by both bs->file and
# bs->backing
printf "cache.direct=on on none0\n"
- echo "$hmp_cmds" | run_qemu -drive "$files","$ids",cache.direct=on | grep -e "Cache" -e "[Cc]annot|[Cc]ould not|[Cc]an't"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$files","$ids",cache.direct=on
printf "\ncache.direct=on on file\n"
- echo "$hmp_cmds" | run_qemu -drive "$files","$ids",file.cache.direct=on | grep -e "Cache" -e "[Cc]annot|[Cc]ould not|[Cc]an't"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$files","$ids",file.cache.direct=on
printf "\ncache.direct=on on backing\n"
- echo "$hmp_cmds" | run_qemu -drive "$files","$ids",backing.cache.direct=on | grep -e "Cache" -e "[Cc]annot|[Cc]ould not|[Cc]an't"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$files","$ids",backing.cache.direct=on
printf "\ncache.direct=on on backing-file\n"
- echo "$hmp_cmds" | run_qemu -drive "$files","$ids",backing.file.cache.direct=on | grep -e "Cache" -e "[Cc]annot|[Cc]ould not|[Cc]an't"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$files","$ids",backing.file.cache.direct=on
# cache.writeback is supposed to be inherited by bs->backing; bs->file
# always gets cache.writeback=on
printf "\n\ncache.writeback=off on none0\n"
- echo "$hmp_cmds" | run_qemu -drive "$files","$ids",cache.writeback=off | grep -e "Cache" -e "[Cc]annot\|[Cc]ould not\|[Cc]an't"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$files","$ids",cache.writeback=off
printf "\ncache.writeback=off on file\n"
- echo "$hmp_cmds" | run_qemu -drive "$files","$ids",file.cache.writeback=off | grep -e "doesn't" -e "does not"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$files","$ids",file.cache.writeback=off
printf "\ncache.writeback=off on backing\n"
- echo "$hmp_cmds" | run_qemu -drive "$files","$ids",backing.cache.writeback=off | grep -e "doesn't" -e "does not"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$files","$ids",backing.cache.writeback=off
printf "\ncache.writeback=off on backing-file\n"
- echo "$hmp_cmds" | run_qemu -drive "$files","$ids",backing.file.cache.writeback=off | grep -e "doesn't" -e "does not"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$files","$ids",backing.file.cache.writeback=off
# cache.no-flush is supposed to be inherited by both bs->file and bs->backing
printf "\n\ncache.no-flush=on on none0\n"
- echo "$hmp_cmds" | run_qemu -drive "$files","$ids",cache.no-flush=on | grep -e "Cache" -e "[Cc]annot\|[Cc]ould not\|[Cc]an't"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$files","$ids",cache.no-flush=on
printf "\ncache.no-flush=on on file\n"
- echo "$hmp_cmds" | run_qemu -drive "$files","$ids",file.cache.no-flush=on | grep -e "Cache" -e "[Cc]annot\|[Cc]ould not\|[Cc]an't"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$files","$ids",file.cache.no-flush=on
printf "\ncache.no-flush=on on backing\n"
- echo "$hmp_cmds" | run_qemu -drive "$files","$ids",backing.cache.no-flush=on | grep -e "Cache" -e "[Cc]annot\|[Cc]ould not\|[Cc]an't"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$files","$ids",backing.cache.no-flush=on
printf "\ncache.no-flush=on on backing-file\n"
- echo "$hmp_cmds" | run_qemu -drive "$files","$ids",backing.file.cache.no-flush=on | grep -e "Cache" -e "[Cc]annot\|[Cc]ould not\|[Cc]an't"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$files","$ids",backing.file.cache.no-flush=on
}
echo
@@ -132,11 +202,8 @@ echo
# First check the inherited cache mode after opening the image.
-hmp_cmds="info block none0
-info block image
-info block file
-info block backing
-info block backing-file"
+qmp_cmds="$qmp_query"
+cache_nodes="none0 image file backing backing-file"
check_cache_all
@@ -146,12 +213,9 @@ echo
# Then trigger a reopen and check that the cache modes are still the same.
-hmp_cmds="snapshot_blkdev -n none0 $TEST_IMG.snap $IMGFMT
-info block
-info block image
-info block file
-info block backing
-info block backing-file"
+qmp_cmds="{ 'execute': 'blockdev-snapshot-sync', 'arguments': { 'device': 'none0', 'snapshot-file': '$TEST_IMG.snap', 'format': '$IMGFMT' } }
+$qmp_query"
+cache_nodes="none0 image file backing backing-file"
check_cache_all
@@ -162,12 +226,9 @@ echo
# This one actually changes the cache mode with the reopen. For this test, the
# new cache mode is specified in the flags, not as an option.
-hmp_cmds='qemu-io none0 "reopen -c none"
-info block none0
-info block image
-info block file
-info block backing
-info block backing-file'
+qmp_cmds="{ 'execute': 'x-qemu-io', 'arguments': { 'device': 'none0', 'command': 'reopen -c none' } }
+$qmp_query"
+cache_nodes="none0 image file backing backing-file"
check_cache_all
@@ -178,12 +239,9 @@ echo
# This one actually changes the cache mode with the reopen. For this test, the
# new cache mode is specified as an option, not in the flags.
-hmp_cmds='qemu-io none0 "reopen -o cache.direct=on"
-info block none0
-info block image
-info block file
-info block backing
-info block backing-file'
+qmp_cmds="{ 'execute': 'x-qemu-io', 'arguments': { 'device': 'none0', 'command': 'reopen -o cache.direct=on' } }
+$qmp_query"
+cache_nodes="none0 image file backing backing-file"
check_cache_all
@@ -193,13 +251,10 @@ echo
# This checks that the original image doesn't inherit from the snapshot
-hmp_cmds="snapshot_blkdev -n none0 $TEST_IMG.snap $IMGFMT
-qemu-io none0 \"reopen -c none\"
-info block none0
-info block image
-info block file
-info block backing
-info block backing-file"
+qmp_cmds="{ 'execute': 'blockdev-snapshot-sync', 'arguments': { 'device': 'none0', 'snapshot-file': '$TEST_IMG.snap', 'format': '$IMGFMT' } }
+{ 'execute': 'x-qemu-io', 'arguments': { 'device': 'none0', 'command': 'reopen -c none' } }
+$qmp_query"
+cache_nodes="none0 image file backing backing-file"
check_cache_all
@@ -214,13 +269,11 @@ echo
# BDS initialised with the json: pseudo-protocol, but still have it inherit
# options from its parent node.
-hmp_cmds="qemu-io none0 \"reopen -o cache.direct=on,cache.no-flush=on\"
-info block none0
-info block image
-info block blkdebug
-info block file"
+qmp_cmds="{ 'execute': 'x-qemu-io', 'arguments': { 'device': 'none0', 'command': 'reopen -o cache.direct=on,cache.no-flush=on' } }
+$qmp_query"
+cache_nodes="none0 image blkdebug file"
-echo "$hmp_cmds" | run_qemu -drive if=none,file="blkdebug::json:{\"filename\":\"$TEST_IMG\",,\"cache\":{\"direct\":false}}",node-name=image,file.node-name=blkdebug,file.image.node-name=file | grep "Cache"
+echo "$qmp_cmds" | run_qemu_cache -drive if=none,file="blkdebug::json:{\"filename\":\"$TEST_IMG\",,\"cache\":{\"direct\":false}}",node-name=image,file.node-name=blkdebug,file.image.node-name=file
echo
echo "=== Check that referenced BDSes don't inherit ==="
@@ -236,35 +289,35 @@ check_cache_all_separate()
# Check cache.direct
printf "cache.direct=on on blk\n"
- echo "$hmp_cmds" | run_qemu -drive "$drv_bkfile" -drive "$drv_bk" -drive "$drv_file" -drive "$drv_img",cache.direct=on | grep -e "Cache" -e "[Cc]annot\|[Cc]ould not\|[Cc]an't"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$drv_bkfile" -drive "$drv_bk" -drive "$drv_file" -drive "$drv_img",cache.direct=on
printf "\ncache.direct=on on file\n"
- echo "$hmp_cmds" | run_qemu -drive "$drv_bkfile" -drive "$drv_bk" -drive "$drv_file",cache.direct=on -drive "$drv_img" | grep -e "Cache" -e "[Cc]annot\|[Cc]ould not\|[Cc]an't"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$drv_bkfile" -drive "$drv_bk" -drive "$drv_file",cache.direct=on -drive "$drv_img"
printf "\ncache.direct=on on backing\n"
- echo "$hmp_cmds" | run_qemu -drive "$drv_bkfile" -drive "$drv_bk",cache.direct=on -drive "$drv_file" -drive "$drv_img" | grep -e "Cache" -e "[Cc]annot\|[Cc]ould not\|[Cc]an't"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$drv_bkfile" -drive "$drv_bk",cache.direct=on -drive "$drv_file" -drive "$drv_img"
printf "\ncache.direct=on on backing-file\n"
- echo "$hmp_cmds" | run_qemu -drive "$drv_bkfile",cache.direct=on -drive "$drv_bk" -drive "$drv_file" -drive "$drv_img" | grep -e "Cache" -e "[Cc]annot\|[Cc]ould not\|[Cc]an't"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$drv_bkfile",cache.direct=on -drive "$drv_bk" -drive "$drv_file" -drive "$drv_img"
# Check cache.writeback
printf "\n\ncache.writeback=off on blk\n"
- echo "$hmp_cmds" | run_qemu -drive "$drv_bkfile" -drive "$drv_bk" -drive "$drv_file" -drive "$drv_img",cache.writeback=off | grep -e "Cache" -e "[Cc]annot\|[Cc]ould not\|[Cc]an't"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$drv_bkfile" -drive "$drv_bk" -drive "$drv_file" -drive "$drv_img",cache.writeback=off
printf "\ncache.writeback=off on file\n"
- echo "$hmp_cmds" | run_qemu -drive "$drv_bkfile" -drive "$drv_bk" -drive "$drv_file",cache.writeback=off -drive "$drv_img" | grep -e "Cache" -e "[Cc]annot\|[Cc]ould not\|[Cc]an't"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$drv_bkfile" -drive "$drv_bk" -drive "$drv_file",cache.writeback=off -drive "$drv_img"
printf "\ncache.writeback=off on backing\n"
- echo "$hmp_cmds" | run_qemu -drive "$drv_bkfile" -drive "$drv_bk",cache.writeback=off -drive "$drv_file" -drive "$drv_img" | grep -e "Cache" -e "[Cc]annot\|[Cc]ould not\|[Cc]an't"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$drv_bkfile" -drive "$drv_bk",cache.writeback=off -drive "$drv_file" -drive "$drv_img"
printf "\ncache.writeback=off on backing-file\n"
- echo "$hmp_cmds" | run_qemu -drive "$drv_bkfile",cache.writeback=off -drive "$drv_bk" -drive "$drv_file" -drive "$drv_img" | grep -e "Cache" -e "[Cc]annot\|[Cc]ould not\|[Cc]an't"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$drv_bkfile",cache.writeback=off -drive "$drv_bk" -drive "$drv_file" -drive "$drv_img"
# Check cache.no-flush
printf "\n\ncache.no-flush=on on blk\n"
- echo "$hmp_cmds" | run_qemu -drive "$drv_bkfile" -drive "$drv_bk" -drive "$drv_file" -drive "$drv_img",cache.no-flush=on | grep -e "Cache" -e "[Cc]annot\|[Cc]ould not\|[Cc]an't"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$drv_bkfile" -drive "$drv_bk" -drive "$drv_file" -drive "$drv_img",cache.no-flush=on
printf "\ncache.no-flush=on on file\n"
- echo "$hmp_cmds" | run_qemu -drive "$drv_bkfile" -drive "$drv_bk" -drive "$drv_file",cache.no-flush=on -drive "$drv_img" | grep -e "Cache" -e "[Cc]annot\|[Cc]ould not\|[Cc]an't"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$drv_bkfile" -drive "$drv_bk" -drive "$drv_file",cache.no-flush=on -drive "$drv_img"
printf "\ncache.no-flush=on on backing\n"
- echo "$hmp_cmds" | run_qemu -drive "$drv_bkfile" -drive "$drv_bk",cache.no-flush=on -drive "$drv_file" -drive "$drv_img" | grep -e "Cache" -e "[Cc]annot\|[Cc]ould not\|[Cc]an't"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$drv_bkfile" -drive "$drv_bk",cache.no-flush=on -drive "$drv_file" -drive "$drv_img"
printf "\ncache.no-flush=on on backing-file\n"
- echo "$hmp_cmds" | run_qemu -drive "$drv_bkfile",cache.no-flush=on -drive "$drv_bk" -drive "$drv_file" -drive "$drv_img" | grep -e "Cache" -e "[Cc]annot\|[Cc]ould not\|[Cc]an't"
+ echo "$qmp_cmds" | run_qemu_cache -drive "$drv_bkfile",cache.no-flush=on -drive "$drv_bk" -drive "$drv_file" -drive "$drv_img"
}
echo
@@ -273,10 +326,8 @@ echo
# First check the inherited cache mode after opening the image.
-hmp_cmds="info block image
-info block file
-info block backing
-info block backing-file"
+qmp_cmds="$qmp_query"
+cache_nodes="image file backing backing-file"
check_cache_all_separate
@@ -286,12 +337,9 @@ echo
# Then trigger a reopen and check that the cache modes are still the same.
-hmp_cmds="snapshot_blkdev -n blk $TEST_IMG.snap $IMGFMT
-info block blk
-info block image
-info block file
-info block backing
-info block backing-file"
+qmp_cmds="{ 'execute': 'blockdev-snapshot-sync', 'arguments': { 'device': 'blk', 'snapshot-file': '$TEST_IMG.snap', 'format': '$IMGFMT' } }
+$qmp_query"
+cache_nodes="blk image file backing backing-file"
check_cache_all_separate
@@ -302,11 +350,9 @@ echo
# This one actually changes the cache mode with the reopen. For this test, the
# new cache mode is specified as flags, not as option.
-hmp_cmds='qemu-io blk "reopen -c none"
-info block image
-info block file
-info block backing
-info block backing-file'
+qmp_cmds="{ 'execute': 'x-qemu-io', 'arguments': { 'device': 'blk', 'command': 'reopen -c none' } }
+$qmp_query"
+cache_nodes="image file backing backing-file"
check_cache_all_separate
@@ -322,12 +368,9 @@ echo
echo "--- Basic reopen ---"
echo
-hmp_cmds='qemu-io none0 "reopen -o backing.cache.direct=on"
-info block none0
-info block image
-info block file
-info block backing
-info block backing-file'
+qmp_cmds="{ 'execute': 'x-qemu-io', 'arguments': { 'device': 'none0', 'command': 'reopen -o backing.cache.direct=on' } }
+$qmp_query"
+cache_nodes="none0 image file backing backing-file"
check_cache_all
@@ -341,15 +384,13 @@ echo
# TODO Implement node-name support for 'qemu-io' HMP command for -c
# Can use only -o to access child node options for now
-hmp_cmds="qemu-io none0 \"reopen -o file.cache.direct=off,file.cache.no-flush=off\"
-qemu-io none0 \"reopen -o backing.file.cache.direct=off,backing.file.cache.no-flush=on\"
-qemu-io none0 \"reopen -c none\"
-info block image
-info block file
-info block backing
-info block backing-file"
+qmp_cmds="{ 'execute': 'x-qemu-io', 'arguments': { 'device': 'none0', 'command': 'reopen -o file.cache.direct=off,file.cache.no-flush=off' } }
+{ 'execute': 'x-qemu-io', 'arguments': { 'device': 'none0', 'command': 'reopen -o backing.file.cache.direct=off,backing.file.cache.no-flush=on' } }
+{ 'execute': 'x-qemu-io', 'arguments': { 'device': 'none0', 'command': 'reopen -c none' } }
+$qmp_query"
+cache_nodes="image file backing backing-file"
-echo "$hmp_cmds" | run_qemu -drive "$files","$ids" | grep "Cache"
+echo "$qmp_cmds" | run_qemu_cache -drive "$files","$ids"
echo
echo "--- Alignment after changing O_DIRECT ---"
diff --git a/tests/qemu-iotests/142.out b/tests/qemu-iotests/142.out
index e20cfc8eb812..2769f354e867 100644
--- a/tests/qemu-iotests/142.out
+++ b/tests/qemu-iotests/142.out
@@ -6,24 +6,34 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728 backing_file=TEST_DIR/
=== Simple test for all cache modes ===
Testing: -drive file=TEST_DIR/t.qcow2,cache=none
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive file=TEST_DIR/t.qcow2,cache=directsync
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive file=TEST_DIR/t.qcow2,cache=writeback
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive file=TEST_DIR/t.qcow2,cache=writethrough
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive file=TEST_DIR/t.qcow2,cache=unsafe
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive file=TEST_DIR/t.qcow2,cache=invalid_value
QEMU_PROG: -drive file=TEST_DIR/t.qcow2,cache=invalid_value: invalid cache option
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 54/88] qemu-iotests/146: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (52 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 53/88] qemu-iotests/142: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 55/88] qemu-iotests/117: " Marc-André Lureau
` (35 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
HMP is actually unused.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/146 | 5 -----
1 file changed, 5 deletions(-)
diff --git a/tests/qemu-iotests/146 b/tests/qemu-iotests/146
index f63291d0ffba..3cd41e8180a0 100755
--- a/tests/qemu-iotests/146
+++ b/tests/qemu-iotests/146
@@ -42,11 +42,6 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
_supported_fmt vpc
_supported_proto file
_supported_os Linux
-_require_hmp
-
-
-qemu_comm_method="monitor"
-silent=
echo
echo === Testing VPC Autodetect ===
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 55/88] qemu-iotests/117: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (53 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 54/88] qemu-iotests/146: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 56/88] qemu-iotests/119: " Marc-André Lureau
` (34 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/117 | 5 ++---
tests/qemu-iotests/117.out | 8 +++-----
2 files changed, 5 insertions(+), 8 deletions(-)
diff --git a/tests/qemu-iotests/117 b/tests/qemu-iotests/117
index 5cc9433f4a67..69d3a862d5e5 100755
--- a/tests/qemu-iotests/117
+++ b/tests/qemu-iotests/117
@@ -41,7 +41,6 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
_supported_fmt qcow2
_supported_proto file fuse
-_require_hmp
_make_test_img 64k
@@ -66,8 +65,8 @@ _send_qemu_cmd $QEMU_HANDLE \
'return'
_send_qemu_cmd $QEMU_HANDLE \
- "{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line': 'qemu-io format \"write -P 42 0 64k\"' } }" \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'format', 'command': 'write -P 42 0 64k' } }" \
'return'
_send_qemu_cmd $QEMU_HANDLE \
diff --git a/tests/qemu-iotests/117.out b/tests/qemu-iotests/117.out
index 1cea9e021730..af2a30be9e84 100644
--- a/tests/qemu-iotests/117.out
+++ b/tests/qemu-iotests/117.out
@@ -12,11 +12,9 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=65536
'driver': 'IMGFMT',
'file': 'protocol' } }
{"return": {}}
-{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line': 'qemu-io format "write -P 42 0 64k"' } }
-wrote 65536/65536 bytes at offset 0
-64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-{"return": ""}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'format', 'command': 'write -P 42 0 64k' } }
+{"return": {"human-readable-text": "wrote 65536/65536 bytes at offset 0\n64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
{ 'execute': 'quit' }
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
{"return": {}}
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 56/88] qemu-iotests/119: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (54 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 55/88] qemu-iotests/117: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 57/88] qemu-iotests/060: " Marc-André Lureau
` (33 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/119 | 5 ++---
tests/qemu-iotests/119.out | 4 +---
2 files changed, 3 insertions(+), 6 deletions(-)
diff --git a/tests/qemu-iotests/119 b/tests/qemu-iotests/119
index ce1b62521f59..6b95f9224b3e 100755
--- a/tests/qemu-iotests/119
+++ b/tests/qemu-iotests/119
@@ -41,13 +41,12 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
_supported_fmt raw
_supported_proto nbd
_supported_os Linux
-_require_hmp
_make_test_img 64M
# This should not crash
echo "{'execute': 'qmp_capabilities'}
- {'execute': 'human-monitor-command',
- 'arguments': {'command-line': 'qemu-io drv \"read -P 0 0 64k\"'}}
+ {'execute': 'x-qemu-io',
+ 'arguments': {'device': 'drv', 'command': 'read -P 0 0 64k'}}
{'execute': 'quit'}" \
| $QEMU -nographic -drive id=drv,if=none,file="$TEST_IMG",driver=nbd \
-qmp stdio -nodefaults \
diff --git a/tests/qemu-iotests/119.out b/tests/qemu-iotests/119.out
index 45f82a4faa93..edd555fdd2d7 100644
--- a/tests/qemu-iotests/119.out
+++ b/tests/qemu-iotests/119.out
@@ -2,9 +2,7 @@ QA output created by 119
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
QMP_VERSION
{"return": {}}
-read 65536/65536 bytes at offset 0
-64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-{"return": ""}
+{"return": {"human-readable-text": "read 65536/65536 bytes at offset 0\n64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
{"return": {}}
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 57/88] qemu-iotests/060: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (55 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 56/88] qemu-iotests/119: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 58/88] qemu-iotests/071: " Marc-André Lureau
` (32 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/060 | 9 ++++-----
tests/qemu-iotests/060.out | 2 +-
2 files changed, 5 insertions(+), 6 deletions(-)
diff --git a/tests/qemu-iotests/060 b/tests/qemu-iotests/060
index 8d06f84df16b..c2c1cd815f0f 100755
--- a/tests/qemu-iotests/060
+++ b/tests/qemu-iotests/060
@@ -56,7 +56,6 @@ _unsupported_imgopts 'compat=0.10' data_file \
# The repair process will create a large file - so check for availability first
_require_large_file 64G
-_require_hmp
rt_offset=65536 # 0x10000 (XXX: just an assumption)
rb_offset=131072 # 0x20000 (XXX: just an assumption)
@@ -450,8 +449,8 @@ echo
_make_test_img 64M
poke_file "$TEST_IMG" "$rt_offset" "\x00\x00\x00\x00\x00\x00\x00\x00"
echo "{'execute': 'qmp_capabilities'}
- {'execute': 'human-monitor-command',
- 'arguments': {'command-line': 'qemu-io drive \"write 0 512\"'}}
+ {'execute': 'x-qemu-io',
+ 'arguments': {'device': 'drive', 'command': 'write 0 512'}}
{'execute': 'quit'}" \
| $QEMU -qmp stdio -nographic -nodefaults \
-drive if=none,node-name=drive,file="$TEST_IMG",driver=qcow2 \
@@ -469,8 +468,8 @@ poke_file "$TEST_IMG" "$l1_offset" "\x00\x00\x00\x00\x2a\x2a\x2a\x2a"
# Inactive images are effectively read-only images, so this should be a
# non-fatal corruption (which does not modify the image)
echo "{'execute': 'qmp_capabilities'}
- {'execute': 'human-monitor-command',
- 'arguments': {'command-line': 'qemu-io drive \"read 0 512\"'}}
+ {'execute': 'x-qemu-io',
+ 'arguments': {'device': 'drive', 'command': 'read 0 512'}}
{'execute': 'quit'}" \
| $QEMU -qmp stdio -nographic -nodefaults \
-blockdev "{'node-name': 'drive',
diff --git a/tests/qemu-iotests/060.out b/tests/qemu-iotests/060.out
index 8870a478231c..833f29c9b031 100644
--- a/tests/qemu-iotests/060.out
+++ b/tests/qemu-iotests/060.out
@@ -419,7 +419,7 @@ qcow2: Marking image as corrupt: Preventing invalid write on metadata (overlaps
QMP_VERSION
{"return": {}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "BLOCK_IMAGE_CORRUPTED", "data": {"device": "none0", "msg": "Preventing invalid write on metadata (overlaps with refcount table)", "offset": 65536, "node-name": "drive", "fatal": true, "size": 65536}}
-{"return": "Error: write failed: Input/output error\r\n"}
+{"error": {"class": "GenericError", "desc": "write failed: Input/output error"}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
{"return": {}}
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 58/88] qemu-iotests/071: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (56 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 57/88] qemu-iotests/060: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 59/88] qemu-iotests/081: " Marc-André Lureau
` (31 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/071 | 31 ++++++++++++++++++-------------
tests/qemu-iotests/071.out | 12 ++++--------
2 files changed, 22 insertions(+), 21 deletions(-)
diff --git a/tests/qemu-iotests/071 b/tests/qemu-iotests/071
index 83c4ce6314c5..463f5c02349c 100755
--- a/tests/qemu-iotests/071
+++ b/tests/qemu-iotests/071
@@ -43,7 +43,6 @@ _require_drivers blkdebug blkverify
# blkdebug can only inject errors on bs->file, not on the data_file,
# so this test does not work with external data files
_unsupported_imgopts data_file
-_require_hmp
do_run_qemu()
{
@@ -140,9 +139,10 @@ run_qemu <<EOF
}
}
}
-{ "execute": "human-monitor-command",
+{ "execute": "x-qemu-io",
"arguments": {
- "command-line": 'qemu-io drive0-debug "read 0 512"'
+ "device": "drive0-debug",
+ "command": "read 0 512"
}
}
{ "execute": "quit" }
@@ -175,9 +175,10 @@ run_qemu <<EOF
}
}
}
-{ "execute": "human-monitor-command",
+{ "execute": "x-qemu-io",
"arguments": {
- "command-line": 'qemu-io drive0-verify "read 0 512"'
+ "device": "drive0-verify",
+ "command": "read 0 512"
}
}
{ "execute": "quit" }
@@ -210,9 +211,10 @@ run_qemu <<EOF
"raw": "drive0"
}
}
-{ "execute": "human-monitor-command",
+{ "execute": "x-qemu-io",
"arguments": {
- "command-line": 'qemu-io drive0-verify "read 0 512"'
+ "device": "drive0-verify",
+ "command": "read 0 512"
}
}
{ "execute": "quit" }
@@ -249,19 +251,22 @@ run_qemu <<EOF
}
}
}
-{ "execute": "human-monitor-command",
+{ "execute": "x-qemu-io",
"arguments": {
- "command-line": 'qemu-io drive0-debug "read 0 512"'
+ "device": "drive0-debug",
+ "command": "read 0 512"
}
}
-{ "execute": "human-monitor-command",
+{ "execute": "x-qemu-io",
"arguments": {
- "command-line": 'qemu-io drive0-debug "write 0 512"'
+ "device": "drive0-debug",
+ "command": "write 0 512"
}
}
-{ "execute": "human-monitor-command",
+{ "execute": "x-qemu-io",
"arguments": {
- "command-line": 'qemu-io drive0-debug "read 0 512"'
+ "device": "drive0-debug",
+ "command": "read 0 512"
}
}
{ "execute": "quit" }
diff --git a/tests/qemu-iotests/071.out b/tests/qemu-iotests/071.out
index 15353aba08b9..1e956d4bc1ec 100644
--- a/tests/qemu-iotests/071.out
+++ b/tests/qemu-iotests/071.out
@@ -43,7 +43,7 @@ QMP_VERSION
{"return": {}}
{"return": {}}
{"return": {}}
-{"return": "Error: read failed: Input/output error\r\n"}
+{"error": {"class": "GenericError", "desc": "read failed: Input/output error"}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
{"return": {}}
@@ -75,13 +75,9 @@ QMP_VERSION
{"return": {}}
{"return": {}}
{"return": {}}
-read 512/512 bytes at offset 0
-512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-{"return": ""}
-wrote 512/512 bytes at offset 0
-512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-{"return": ""}
-{"return": "Error: read failed: Input/output error\r\n"}
+{"return": {"human-readable-text": "read 512/512 bytes at offset 0\n512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"return": {"human-readable-text": "wrote 512/512 bytes at offset 0\n512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"error": {"class": "GenericError", "desc": "read failed: Input/output error"}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
QEMU_PROG: Failed to flush the L2 table cache: Input/output error
QEMU_PROG: Failed to flush the refcount block cache: Input/output error
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 59/88] qemu-iotests/081: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (57 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 58/88] qemu-iotests/071: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 60/88] qemu-iotests/102: " Marc-André Lureau
` (30 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/081 | 11 ++++++-----
tests/qemu-iotests/081.out | 8 ++------
2 files changed, 8 insertions(+), 11 deletions(-)
diff --git a/tests/qemu-iotests/081 b/tests/qemu-iotests/081
index d9e729f674c6..f8bf9232bb58 100755
--- a/tests/qemu-iotests/081
+++ b/tests/qemu-iotests/081
@@ -44,7 +44,6 @@ _supported_proto file
_supported_os Linux
_require_drivers quorum
_require_devices virtio-scsi
-_require_hmp
do_run_qemu()
{
@@ -138,9 +137,10 @@ run_qemu <<EOF
]
}
}
-{ "execute": "human-monitor-command",
+{ "execute": "x-qemu-io",
"arguments": {
- "command-line": 'qemu-io drive0-quorum "read -P 0x32 0 $size"'
+ "device": "drive0-quorum",
+ "command": "read -P 0x32 0 $size"
}
}
{ "execute": "quit" }
@@ -200,9 +200,10 @@ run_qemu \
<<EOF
{ "execute": "qmp_capabilities" }
{
- "execute": "human-monitor-command",
+ "execute": "x-qemu-io",
"arguments": {
- "command-line": 'qemu-io -d quorum-drive "read -P 0x32 0 $size"'
+ "qdev": "quorum-drive",
+ "command": "read -P 0x32 0 $size"
}
}
{ "execute": "quit" }
diff --git a/tests/qemu-iotests/081.out b/tests/qemu-iotests/081.out
index 084b6fbff66a..30a1c67af03c 100644
--- a/tests/qemu-iotests/081.out
+++ b/tests/qemu-iotests/081.out
@@ -32,9 +32,7 @@ QMP_VERSION
{"return": {}}
{"return": {}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "QUORUM_REPORT_BAD", "data": {"node-name": "drive2", "sectors-count": 20480, "sector-num": 0, "type": "read"}}
-read 10485760/10485760 bytes at offset 0
-10 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-{"return": ""}
+{"return": {"human-readable-text": "read 10485760/10485760 bytes at offset 0\n10 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
{"return": {}}
@@ -64,9 +62,7 @@ Testing: -blockdev file,node-name=file1,filename=TEST_DIR/1.IMGFMT -blockdev fil
QMP_VERSION
{"return": {}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "QUORUM_REPORT_BAD", "data": {"node-name": "file2", "sectors-count": 20480, "sector-num": 0, "type": "read"}}
-read 10485760/10485760 bytes at offset 0
-10 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-{"return": ""}
+{"return": {"human-readable-text": "read 10485760/10485760 bytes at offset 0\n10 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
{"return": {}}
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 60/88] qemu-iotests/102: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (58 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 59/88] qemu-iotests/081: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 61/88] qemu-iotests/091: " Marc-André Lureau
` (29 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
No need to substitute qemu-io command.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/102 | 21 ++++++++++++++-------
tests/qemu-iotests/102.out | 12 ++++++++----
2 files changed, 22 insertions(+), 11 deletions(-)
diff --git a/tests/qemu-iotests/102 b/tests/qemu-iotests/102
index 5db8180d3bb7..b70053eee302 100755
--- a/tests/qemu-iotests/102
+++ b/tests/qemu-iotests/102
@@ -41,7 +41,6 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
_supported_fmt qcow2
_supported_proto file fuse
-_require_hmp
IMG_SIZE=64K
@@ -67,18 +66,26 @@ echo
_make_test_img $IMG_SIZE
$QEMU_IO -c 'write 0 64k' "$TEST_IMG" | _filter_qemu_io
-qemu_comm_method=monitor _launch_qemu -drive if=none,file="$TEST_IMG",id=drv0
+_launch_qemu -drive if=none,file="$TEST_IMG",id=drv0
-# Wait for a prompt to appear (so we know qemu has opened the image)
-_send_qemu_cmd $QEMU_HANDLE '' '(qemu)'
+_send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'qmp_capabilities' }" \
+ 'return'
$QEMU_IMG resize --shrink --image-opts \
"driver=raw,file.driver=file,file.filename=$TEST_IMG,file.locking=off" \
$((5 * 64 * 1024))
-_send_qemu_cmd $QEMU_HANDLE 'qemu-io drv0 map' 'allocated' \
- | sed -e 's/^(qemu).*qemu-io drv0 map...$/(qemu) qemu-io drv0 map/'
-_send_qemu_cmd $QEMU_HANDLE 'quit' ''
+_send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'drv0', 'command': 'map' } }" \
+ 'return'
+
+_send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'quit' }" \
+ 'return'
+
+wait=1 _cleanup_qemu
# success, all done
echo '*** done'
diff --git a/tests/qemu-iotests/102.out b/tests/qemu-iotests/102.out
index 320ed5a52ba9..13dee5bdecd6 100644
--- a/tests/qemu-iotests/102.out
+++ b/tests/qemu-iotests/102.out
@@ -15,9 +15,13 @@ Offset Length File
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=65536
wrote 65536/65536 bytes at offset 0
64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu)
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
Image resized.
-(qemu) qemu-io drv0 map
-64 KiB (0x10000) bytes allocated at offset 0 bytes (0x0)
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'drv0', 'command': 'map' } }
+{"return": {"human-readable-text": "64 KiB (0x10000) bytes allocated at offset 0 bytes (0x0)\n"}}
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
*** done
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 61/88] qemu-iotests/091: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (59 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 60/88] qemu-iotests/102: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 62/88] qemu-iotests/120: " Marc-André Lureau
` (28 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/091 | 45 +++++++++++++++++++++++++++++++++++----------
1 file changed, 35 insertions(+), 10 deletions(-)
diff --git a/tests/qemu-iotests/091 b/tests/qemu-iotests/091
index 626203d6fc93..d777f94e00e9 100755
--- a/tests/qemu-iotests/091
+++ b/tests/qemu-iotests/091
@@ -48,7 +48,6 @@ _supported_fmt qcow2
_supported_proto file fuse
_supported_os Linux
_supported_cache_modes writethrough none writeback
-_require_hmp
_default_cache_mode none writeback
size=1G
@@ -61,7 +60,6 @@ echo
echo === Starting QEMU VM1 ===
echo
-qemu_comm_method="monitor"
_launch_qemu -drive file="${TEST_IMG}",cache=${CACHEMODE},aio=${AIOMODE},id=disk
h1=$QEMU_HANDLE
@@ -77,26 +75,53 @@ echo === VM 1: Migrate from VM1 to VM2 ===
echo
silent=yes
-_send_qemu_cmd $h1 'qemu-io disk "write -P 0x22 0 4M"' "(qemu)"
+_send_qemu_cmd $h1 \
+ "{ 'execute': 'qmp_capabilities' }" \
+ 'return'
+_send_qemu_cmd $h2 \
+ "{ 'execute': 'qmp_capabilities' }" \
+ 'return'
+
+_send_qemu_cmd $h1 \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk', 'command': 'write -P 0x22 0 4M' } }" \
+ 'return'
echo "vm1: qemu-io disk write complete"
-_send_qemu_cmd $h1 "migrate \"exec: cat > '${MIG_FIFO}'\"" "(qemu)"
+_send_qemu_cmd $h1 \
+ "{ 'execute': 'migrate',
+ 'arguments': { 'uri': 'exec:cat > ${MIG_FIFO}' } }" \
+ 'return'
echo "vm1: live migration started"
-qemu_cmd_repeat=20 _send_qemu_cmd $h1 "info migrate" "completed"
+qemu_cmd_repeat=20 _send_qemu_cmd $h1 \
+ "{ 'execute': 'query-migrate' }" \
+ '"status": "completed"'
echo "vm1: live migration completed"
echo
echo === VM 2: Post-migration, write to disk, verify running ===
echo
-_send_qemu_cmd $h2 'qemu-io disk "write 4M 1M"' "(qemu)"
+_send_qemu_cmd $h2 \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk', 'command': 'write 4M 1M' } }" \
+ 'return'
echo "vm2: qemu-io disk write complete"
-qemu_cmd_repeat=20 _send_qemu_cmd $h2 "info status" "running"
+qemu_cmd_repeat=20 _send_qemu_cmd $h2 \
+ "{ 'execute': 'query-status' }" \
+ '"status": "running"'
echo "vm2: qemu process running successfully"
echo "vm2: flush io, and quit"
-_send_qemu_cmd $h2 'qemu-io disk flush' "(qemu)"
-_send_qemu_cmd $h2 'quit' ""
-_send_qemu_cmd $h1 'quit' ""
+_send_qemu_cmd $h2 \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk', 'command': 'flush' } }" \
+ 'return'
+_send_qemu_cmd $h2 \
+ "{ 'execute': 'quit' }" \
+ 'return'
+_send_qemu_cmd $h1 \
+ "{ 'execute': 'quit' }" \
+ 'return'
wait=yes _cleanup_qemu >/dev/null
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 62/88] qemu-iotests/120: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (60 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 61/88] qemu-iotests/091: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 63/88] qemu-iotests/161: " Marc-André Lureau
` (27 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/120 | 5 ++---
tests/qemu-iotests/120.out | 4 +---
2 files changed, 3 insertions(+), 6 deletions(-)
diff --git a/tests/qemu-iotests/120 b/tests/qemu-iotests/120
index e4ed87e1a705..fb9ac5a165ef 100755
--- a/tests/qemu-iotests/120
+++ b/tests/qemu-iotests/120
@@ -42,13 +42,12 @@ _supported_fmt generic
_supported_proto file fuse
_unsupported_fmt luks
_require_drivers raw
-_require_hmp
_make_test_img 64M
echo "{'execute': 'qmp_capabilities'}
- {'execute': 'human-monitor-command',
- 'arguments': {'command-line': 'qemu-io drv \"write -P 42 0 64k\"'}}
+ {'execute': 'x-qemu-io',
+ 'arguments': {'device': 'drv', 'command': 'write -P 42 0 64k'}}
{'execute': 'quit'}" \
| $QEMU -qmp stdio -nographic -nodefaults \
-drive id=drv,if=none,file="$TEST_IMG",driver=raw,file.driver=$IMGFMT \
diff --git a/tests/qemu-iotests/120.out b/tests/qemu-iotests/120.out
index 35d84a5bc5a8..c32ae81feb05 100644
--- a/tests/qemu-iotests/120.out
+++ b/tests/qemu-iotests/120.out
@@ -2,9 +2,7 @@ QA output created by 120
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
QMP_VERSION
{"return": {}}
-wrote 65536/65536 bytes at offset 0
-64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-{"return": ""}
+{"return": {"human-readable-text": "wrote 65536/65536 bytes at offset 0\n64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
{"return": {}}
read 65536/65536 bytes at offset 0
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 63/88] qemu-iotests/161: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (61 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 62/88] qemu-iotests/120: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 64/88] qemu-iotests/249: " Marc-André Lureau
` (26 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/161 | 19 +++++++++----------
tests/qemu-iotests/161.out | 24 ++++++++++++------------
2 files changed, 21 insertions(+), 22 deletions(-)
diff --git a/tests/qemu-iotests/161 b/tests/qemu-iotests/161
index 8ca139262975..0f4d59b97d24 100755
--- a/tests/qemu-iotests/161
+++ b/tests/qemu-iotests/161
@@ -45,7 +45,6 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
_supported_fmt qcow2 qed
_supported_proto file fuse
_supported_os Linux
-_require_hmp
IMG_SIZE=1M
@@ -65,9 +64,9 @@ _send_qemu_cmd $QEMU_HANDLE \
'return'
_send_qemu_cmd $QEMU_HANDLE \
- "{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line':
- 'qemu-io none0 \"reopen -o backing.detect-zeroes=on\"' } }" \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'none0',
+ 'command': 'reopen -o backing.detect-zeroes=on' } }" \
"return"
_cleanup_qemu
@@ -93,9 +92,9 @@ _send_qemu_cmd $QEMU_HANDLE \
sleep 0.5
_send_qemu_cmd $QEMU_HANDLE \
- "{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line':
- 'qemu-io none0 \"reopen -o backing.detect-zeroes=on\"' } }" \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'none0',
+ 'command': 'reopen -o backing.detect-zeroes=on' } }" \
"return"
_cleanup_qemu
@@ -126,9 +125,9 @@ _send_qemu_cmd $QEMU_HANDLE \
sleep 0.5
_send_qemu_cmd $QEMU_HANDLE \
- "{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line':
- 'qemu-io none0 \"reopen -o backing.detect-zeroes=on\"' } }" \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'none0',
+ 'command': 'reopen -o backing.detect-zeroes=on' } }" \
"return"
_cleanup_qemu
diff --git a/tests/qemu-iotests/161.out b/tests/qemu-iotests/161.out
index 6cc285afcfdc..ebadca1c79a2 100644
--- a/tests/qemu-iotests/161.out
+++ b/tests/qemu-iotests/161.out
@@ -7,10 +7,10 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1048576 backing_file=TEST_DIR/t.
{ 'execute': 'qmp_capabilities' }
{"return": {}}
-{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line':
- 'qemu-io none0 "reopen -o backing.detect-zeroes=on"' } }
-{"return": ""}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'none0',
+ 'command': 'reopen -o backing.detect-zeroes=on' } }
+{"return": {"human-readable-text": ""}}
*** Stream and then change an option on the backing file
@@ -21,15 +21,15 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1048576 backing_file=TEST_DIR/t.
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "none0"}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "none0"}}
{"return": {}}
-{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line':
- 'qemu-io none0 "reopen -o backing.detect-zeroes=on"' } }
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'none0',
+ 'command': 'reopen -o backing.detect-zeroes=on' } }
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "waiting", "id": "none0"}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "pending", "id": "none0"}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "BLOCK_JOB_COMPLETED", "data": {"device": "none0", "len": 1048576, "offset": 1048576, "speed": 0, "type": "stream"}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "concluded", "id": "none0"}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "none0"}}
-{"return": ""}
+{"return": {"human-readable-text": ""}}
*** Commit and then change an option on the backing file
@@ -43,13 +43,13 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1048576 backing_file=TEST_DIR/t.
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "none0"}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "none0"}}
{"return": {}}
-{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line':
- 'qemu-io none0 "reopen -o backing.detect-zeroes=on"' } }
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'none0',
+ 'command': 'reopen -o backing.detect-zeroes=on' } }
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "waiting", "id": "none0"}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "pending", "id": "none0"}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "BLOCK_JOB_COMPLETED", "data": {"device": "none0", "len": 1048576, "offset": 1048576, "speed": 0, "type": "commit"}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "concluded", "id": "none0"}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "none0"}}
-{"return": ""}
+{"return": {"human-readable-text": ""}}
*** done
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 64/88] qemu-iotests/249: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (62 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 63/88] qemu-iotests/161: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 65/88] qemu-iotests/156: " Marc-André Lureau
` (25 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/249 | 19 +++++++++----------
tests/qemu-iotests/249.out | 18 +++++++++---------
2 files changed, 18 insertions(+), 19 deletions(-)
diff --git a/tests/qemu-iotests/249 b/tests/qemu-iotests/249
index 1254bf942913..fb3a4c480a78 100755
--- a/tests/qemu-iotests/249
+++ b/tests/qemu-iotests/249
@@ -45,7 +45,6 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
_supported_fmt qcow2 qed
_supported_proto file fuse
_supported_os Linux
-_require_hmp
IMG_SIZE=1M
@@ -68,9 +67,9 @@ echo
echo '=== Send a write command to a drive opened in read-only mode (1)'
echo
_send_qemu_cmd $QEMU_HANDLE \
- "{ 'execute': 'human-monitor-command',
- 'arguments': {'command-line': 'qemu-io none0 \"aio_write 0 2k\"'}}" \
- 'return'
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': {'device': 'none0', 'command': 'aio_write 0 2k'}}" \
+ 'error'
echo
echo '=== Run block-commit on base using an invalid filter node name'
@@ -85,9 +84,9 @@ echo
echo '=== Send a write command to a drive opened in read-only mode (2)'
echo
_send_qemu_cmd $QEMU_HANDLE \
- "{ 'execute': 'human-monitor-command',
- 'arguments': {'command-line': 'qemu-io none0 \"aio_write 0 2k\"'}}" \
- 'return'
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': {'device': 'none0', 'command': 'aio_write 0 2k'}}" \
+ 'error'
echo
echo '=== Run block-commit on base using the default filter node name'
@@ -105,9 +104,9 @@ echo
echo '=== Send a write command to a drive opened in read-only mode (3)'
echo
_send_qemu_cmd $QEMU_HANDLE \
- "{ 'execute': 'human-monitor-command',
- 'arguments': {'command-line': 'qemu-io none0 \"aio_write 0 2k\"'}}" \
- 'return'
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': {'device': 'none0', 'command': 'aio_write 0 2k'}}" \
+ 'error'
_cleanup_qemu
diff --git a/tests/qemu-iotests/249.out b/tests/qemu-iotests/249.out
index 3d37709a9ef8..79f69cd26513 100644
--- a/tests/qemu-iotests/249.out
+++ b/tests/qemu-iotests/249.out
@@ -7,9 +7,9 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1048576 backing_file=TEST_DIR/t.
=== Send a write command to a drive opened in read-only mode (1)
-{ 'execute': 'human-monitor-command',
- 'arguments': {'command-line': 'qemu-io none0 "aio_write 0 2k"'}}
-{"return": "Error: Block node is read-onlyrn"}
+{ 'execute': 'x-qemu-io',
+ 'arguments': {'device': 'none0', 'command': 'aio_write 0 2k'}}
+{"error": {"class": "GenericError", "desc": "Block node is read-only"}}
=== Run block-commit on base using an invalid filter node name
@@ -22,9 +22,9 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1048576 backing_file=TEST_DIR/t.
=== Send a write command to a drive opened in read-only mode (2)
-{ 'execute': 'human-monitor-command',
- 'arguments': {'command-line': 'qemu-io none0 "aio_write 0 2k"'}}
-{"return": "Error: Block node is read-onlyrn"}
+{ 'execute': 'x-qemu-io',
+ 'arguments': {'device': 'none0', 'command': 'aio_write 0 2k'}}
+{"error": {"class": "GenericError", "desc": "Block node is read-only"}}
=== Run block-commit on base using the default filter node name
@@ -41,7 +41,7 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1048576 backing_file=TEST_DIR/t.
=== Send a write command to a drive opened in read-only mode (3)
-{ 'execute': 'human-monitor-command',
- 'arguments': {'command-line': 'qemu-io none0 "aio_write 0 2k"'}}
-{"return": "Error: Block node is read-onlyrn"}
+{ 'execute': 'x-qemu-io',
+ 'arguments': {'device': 'none0', 'command': 'aio_write 0 2k'}}
+{"error": {"class": "GenericError", "desc": "Block node is read-only"}}
*** done
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 65/88] qemu-iotests/156: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (63 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 64/88] qemu-iotests/249: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 66/88] qemu-iotests/write-zeroes-unmap: " Marc-André Lureau
` (24 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/156 | 37 ++++++++++++++--------------
tests/qemu-iotests/156.out | 60 +++++++++++++++++++---------------------------
2 files changed, 42 insertions(+), 55 deletions(-)
diff --git a/tests/qemu-iotests/156 b/tests/qemu-iotests/156
index a0e4d1ffd42a..1b0c955c4222 100755
--- a/tests/qemu-iotests/156
+++ b/tests/qemu-iotests/156
@@ -53,7 +53,6 @@ _supported_fmt qcow2 qed
_supported_proto file
# Copying files around with cp does not work with external data files
_unsupported_imgopts data_file
-_require_hmp
# Create source disk
TEST_IMG="$TEST_IMG.backing" _make_test_img 1M
@@ -80,9 +79,9 @@ _send_qemu_cmd $QEMU_HANDLE \
# Write something to the snapshot
_send_qemu_cmd $QEMU_HANDLE \
- "{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line':
- 'qemu-io source \"write -P 3 128k 128k\"' } }" \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'source',
+ 'command': 'write -P 3 128k 128k' } }" \
'return'
# Create target image
@@ -105,9 +104,9 @@ _send_qemu_cmd $QEMU_HANDLE \
# Write some more
_send_qemu_cmd $QEMU_HANDLE \
- "{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line':
- 'qemu-io source \"write -P 4 192k 64k\"' } }" \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'source',
+ 'command': 'write -P 4 192k 64k' } }" \
'return'
# Copy source backing chain to the target before completing the job
@@ -134,27 +133,27 @@ echo
# Check online disk contents
_send_qemu_cmd $QEMU_HANDLE \
- "{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line':
- 'qemu-io source \"read -P 1 0k 64k\"' } }" \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'source',
+ 'command': 'read -P 1 0k 64k' } }" \
'return'
_send_qemu_cmd $QEMU_HANDLE \
- "{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line':
- 'qemu-io source \"read -P 2 64k 64k\"' } }" \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'source',
+ 'command': 'read -P 2 64k 64k' } }" \
'return'
_send_qemu_cmd $QEMU_HANDLE \
- "{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line':
- 'qemu-io source \"read -P 3 128k 64k\"' } }" \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'source',
+ 'command': 'read -P 3 128k 64k' } }" \
'return'
_send_qemu_cmd $QEMU_HANDLE \
- "{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line':
- 'qemu-io source \"read -P 4 192k 64k\"' } }" \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'source',
+ 'command': 'read -P 4 192k 64k' } }" \
'return'
echo
diff --git a/tests/qemu-iotests/156.out b/tests/qemu-iotests/156.out
index 07e5e83f5d4b..f91ce91d0d60 100644
--- a/tests/qemu-iotests/156.out
+++ b/tests/qemu-iotests/156.out
@@ -14,12 +14,10 @@ Formatting 'TEST_DIR/t.IMGFMT.overlay', fmt=IMGFMT size=1048576 backing_file=TES
'format': 'IMGFMT',
'mode': 'existing' } }
{"return": {}}
-{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line':
- 'qemu-io source "write -P 3 128k 128k"' } }
-wrote 131072/131072 bytes at offset 131072
-128 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-{"return": ""}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'source',
+ 'command': 'write -P 3 128k 128k' } }
+{"return": {"human-readable-text": "wrote 131072/131072 bytes at offset 131072\n128 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
Formatting 'TEST_DIR/t.IMGFMT.target.overlay', fmt=IMGFMT size=1048576 backing_file=TEST_DIR/t.IMGFMT.target backing_fmt=IMGFMT
{ 'execute': 'drive-mirror',
'arguments': { 'device': 'source',
@@ -31,12 +29,10 @@ Formatting 'TEST_DIR/t.IMGFMT.target.overlay', fmt=IMGFMT size=1048576 backing_f
{"return": {}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "ready", "id": "source"}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "BLOCK_JOB_READY", "data": {"device": "source", "len": 131072, "offset": 131072, "speed": 0, "type": "mirror"}}
-{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line':
- 'qemu-io source "write -P 4 192k 64k"' } }
-wrote 65536/65536 bytes at offset 196608
-64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-{"return": ""}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'source',
+ 'command': 'write -P 4 192k 64k' } }
+{"return": {"human-readable-text": "wrote 65536/65536 bytes at offset 196608\n64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
{ 'execute': 'block-job-complete',
'arguments': { 'device': 'source' } }
{"return": {}}
@@ -46,30 +42,22 @@ wrote 65536/65536 bytes at offset 196608
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "concluded", "id": "source"}}
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "source"}}
-{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line':
- 'qemu-io source "read -P 1 0k 64k"' } }
-read 65536/65536 bytes at offset 0
-64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-{"return": ""}
-{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line':
- 'qemu-io source "read -P 2 64k 64k"' } }
-read 65536/65536 bytes at offset 65536
-64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-{"return": ""}
-{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line':
- 'qemu-io source "read -P 3 128k 64k"' } }
-read 65536/65536 bytes at offset 131072
-64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-{"return": ""}
-{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line':
- 'qemu-io source "read -P 4 192k 64k"' } }
-read 65536/65536 bytes at offset 196608
-64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-{"return": ""}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'source',
+ 'command': 'read -P 1 0k 64k' } }
+{"return": {"human-readable-text": "read 65536/65536 bytes at offset 0\n64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'source',
+ 'command': 'read -P 2 64k 64k' } }
+{"return": {"human-readable-text": "read 65536/65536 bytes at offset 65536\n64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'source',
+ 'command': 'read -P 3 128k 64k' } }
+{"return": {"human-readable-text": "read 65536/65536 bytes at offset 131072\n64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'source',
+ 'command': 'read -P 4 192k 64k' } }
+{"return": {"human-readable-text": "read 65536/65536 bytes at offset 196608\n64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
{ 'execute': 'quit' }
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 66/88] qemu-iotests/write-zeroes-unmap: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (64 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 65/88] qemu-iotests/156: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 67/88] qemu-iotests/luks-detached-header: " Marc-André Lureau
` (23 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Introduce qmp_qemu_io() to help with sending just one x-qemu-io command.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/tests/write-zeroes-unmap | 42 +++++++------
tests/qemu-iotests/tests/write-zeroes-unmap.out | 80 ++++++++++++-------------
2 files changed, 64 insertions(+), 58 deletions(-)
diff --git a/tests/qemu-iotests/tests/write-zeroes-unmap b/tests/qemu-iotests/tests/write-zeroes-unmap
index 506ced647bc1..b5c019c85acf 100755
--- a/tests/qemu-iotests/tests/write-zeroes-unmap
+++ b/tests/qemu-iotests/tests/write-zeroes-unmap
@@ -33,27 +33,33 @@ _supported_fmt raw
_supported_proto file
_supported_os Linux
_require_disk_usage
-_require_hmp
create_test_image() {
_make_test_img -f $IMGFMT 1m
}
filter_command() {
- _filter_testdir | _filter_qemu_io | _filter_qemu | _filter_hmp
+ _filter_qmp | _filter_testdir | _filter_qemu_io | _filter_qemu
}
print_disk_usage() {
du -sh $TEST_IMG | _filter_testdir
}
+qmp_qemu_io() {
+ printf '%s\n' \
+ '{"execute":"qmp_capabilities"}' \
+ "{\"execute\":\"x-qemu-io\",\"arguments\":{\"device\":\"none0\",\"command\":\"$1\"}}" \
+ '{"execute":"quit"}'
+}
+
echo
echo "=== defaults - write zeros ==="
echo
create_test_image
-echo -e 'qemu-io none0 "write -z 0 1m"\nquit' \
- | $QEMU -monitor stdio -drive if=none,file=$TEST_IMG,format=$IMGFMT \
+qmp_qemu_io "write -z 0 1m" \
+ | $QEMU -qmp stdio -drive if=none,file=$TEST_IMG,format=$IMGFMT \
| filter_command
print_disk_usage
@@ -62,8 +68,8 @@ echo "=== defaults - write zeros unmap ==="
echo
create_test_image
-echo -e 'qemu-io none0 "write -zu 0 1m"\nquit' \
- | $QEMU -monitor stdio -drive if=none,file=$TEST_IMG,format=$IMGFMT \
+qmp_qemu_io "write -zu 0 1m" \
+ | $QEMU -qmp stdio -drive if=none,file=$TEST_IMG,format=$IMGFMT \
| filter_command
print_disk_usage
@@ -73,8 +79,8 @@ echo "=== defaults - write actual zeros ==="
echo
create_test_image
-echo -e 'qemu-io none0 "write -P 0 0 1m"\nquit' \
- | $QEMU -monitor stdio -drive if=none,file=$TEST_IMG,format=$IMGFMT \
+qmp_qemu_io "write -P 0 0 1m" \
+ | $QEMU -qmp stdio -drive if=none,file=$TEST_IMG,format=$IMGFMT \
| filter_command
print_disk_usage
@@ -83,8 +89,8 @@ echo "=== discard=off - write zeroes unmap ==="
echo
create_test_image
-echo -e 'qemu-io none0 "write -zu 0 1m"\nquit' \
- | $QEMU -monitor stdio -drive if=none,file=$TEST_IMG,format=$IMGFMT,discard=off \
+qmp_qemu_io "write -zu 0 1m" \
+ | $QEMU -qmp stdio -drive if=none,file=$TEST_IMG,format=$IMGFMT,discard=off \
| filter_command
print_disk_usage
@@ -93,8 +99,8 @@ echo "=== detect-zeroes=on - write actual zeros ==="
echo
create_test_image
-echo -e 'qemu-io none0 "write -P 0 0 1m"\nquit' \
- | $QEMU -monitor stdio -drive if=none,file=$TEST_IMG,format=$IMGFMT,detect-zeroes=on \
+qmp_qemu_io "write -P 0 0 1m" \
+ | $QEMU -qmp stdio -drive if=none,file=$TEST_IMG,format=$IMGFMT,detect-zeroes=on \
| filter_command
print_disk_usage
@@ -103,8 +109,8 @@ echo "=== detect-zeroes=on,discard=on - write actual zeros ==="
echo
create_test_image
-echo -e 'qemu-io none0 "write -P 0 0 1m"\nquit' \
- | $QEMU -monitor stdio -drive if=none,file=$TEST_IMG,format=$IMGFMT,detect-zeroes=on,discard=on \
+qmp_qemu_io "write -P 0 0 1m" \
+ | $QEMU -qmp stdio -drive if=none,file=$TEST_IMG,format=$IMGFMT,detect-zeroes=on,discard=on \
| filter_command
print_disk_usage
@@ -113,8 +119,8 @@ echo "=== discard=on - write zeroes ==="
echo
create_test_image
-echo -e 'qemu-io none0 "write -z 0 1m"\nquit' \
- | $QEMU -monitor stdio -drive if=none,file=$TEST_IMG,format=$IMGFMT,discard=on \
+qmp_qemu_io "write -z 0 1m" \
+ | $QEMU -qmp stdio -drive if=none,file=$TEST_IMG,format=$IMGFMT,discard=on \
| filter_command
print_disk_usage
@@ -123,7 +129,7 @@ echo "=== discard=on - write zeroes unmap ==="
echo
create_test_image
-echo -e 'qemu-io none0 "write -zu 0 1m"\nquit' \
- | $QEMU -monitor stdio -drive if=none,file=$TEST_IMG,format=$IMGFMT,discard=on \
+qmp_qemu_io "write -zu 0 1m" \
+ | $QEMU -qmp stdio -drive if=none,file=$TEST_IMG,format=$IMGFMT,discard=on \
| filter_command
print_disk_usage
diff --git a/tests/qemu-iotests/tests/write-zeroes-unmap.out b/tests/qemu-iotests/tests/write-zeroes-unmap.out
index c9319948976f..1ac940a8badc 100644
--- a/tests/qemu-iotests/tests/write-zeroes-unmap.out
+++ b/tests/qemu-iotests/tests/write-zeroes-unmap.out
@@ -3,79 +3,79 @@ QA output created by write-zeroes-unmap
=== defaults - write zeros ===
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1048576
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io none0 "write -z 0 1m"
-wrote 1048576/1048576 bytes at offset 0
-1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": {"human-readable-text": "wrote 1048576/1048576 bytes at offset 0\n1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
1.0M TEST_DIR/t.raw
=== defaults - write zeros unmap ===
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1048576
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io none0 "write -zu 0 1m"
-wrote 1048576/1048576 bytes at offset 0
-1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": {"human-readable-text": "wrote 1048576/1048576 bytes at offset 0\n1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
1.0M TEST_DIR/t.raw
=== defaults - write actual zeros ===
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1048576
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io none0 "write -P 0 0 1m"
-wrote 1048576/1048576 bytes at offset 0
-1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": {"human-readable-text": "wrote 1048576/1048576 bytes at offset 0\n1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
1.0M TEST_DIR/t.raw
=== discard=off - write zeroes unmap ===
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1048576
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io none0 "write -zu 0 1m"
-wrote 1048576/1048576 bytes at offset 0
-1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": {"human-readable-text": "wrote 1048576/1048576 bytes at offset 0\n1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
1.0M TEST_DIR/t.raw
=== detect-zeroes=on - write actual zeros ===
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1048576
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io none0 "write -P 0 0 1m"
-wrote 1048576/1048576 bytes at offset 0
-1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": {"human-readable-text": "wrote 1048576/1048576 bytes at offset 0\n1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
1.0M TEST_DIR/t.raw
=== detect-zeroes=on,discard=on - write actual zeros ===
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1048576
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io none0 "write -P 0 0 1m"
-wrote 1048576/1048576 bytes at offset 0
-1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": {"human-readable-text": "wrote 1048576/1048576 bytes at offset 0\n1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
1.0M TEST_DIR/t.raw
=== discard=on - write zeroes ===
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1048576
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io none0 "write -z 0 1m"
-wrote 1048576/1048576 bytes at offset 0
-1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": {"human-readable-text": "wrote 1048576/1048576 bytes at offset 0\n1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
1.0M TEST_DIR/t.raw
=== discard=on - write zeroes unmap ===
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1048576
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io none0 "write -zu 0 1m"
-wrote 1048576/1048576 bytes at offset 0
-1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": {"human-readable-text": "wrote 1048576/1048576 bytes at offset 0\n1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
0 TEST_DIR/t.raw
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 67/88] qemu-iotests/luks-detached-header: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (65 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 66/88] qemu-iotests/write-zeroes-unmap: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-23 4:18 ` Hy Man
2026-09-22 20:18 ` [PATCH 68/88] qemu-iotests/qcow2-internal-snapshots: " Marc-André Lureau
` (22 subsequent siblings)
89 siblings, 1 reply; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel
Cc: Kevin Wolf, Marc-André Lureau, Hyman Huang, Hanna Reitz,
qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
| 49 +++++++--------------------
1 file changed, 13 insertions(+), 36 deletions(-)
--git a/tests/qemu-iotests/tests/luks-detached-header b/tests/qemu-iotests/tests/luks-detached-header
index 58eb3c2cc484..fbf812902832 100755
--- a/tests/qemu-iotests/tests/luks-detached-header
+++ b/tests/qemu-iotests/tests/luks-detached-header
@@ -266,52 +266,29 @@ class TestDetachedLUKSHeader(QMPTestCase):
# (Pattern verification will be checked by tearDown())
# Normal LUKS disk
- result = self.vm.qmp_log(
- "human-monitor-command",
- command_line='qemu-io luks-1-format "write -P 40 0 64k"',
- )
- self.assert_qmp(result, "return", "")
+ self.vm.qmp_qemu_io("luks-1-format", "write -P 40 0 64k",
+ use_log=True)
- result = self.vm.qmp_log(
- "human-monitor-command",
- command_line='qemu-io luks-1-format "read -P 40 0 64k"',
- )
- self.assert_qmp(result, "return", "")
+ self.vm.qmp_qemu_io("luks-1-format", "read -P 40 0 64k",
+ use_log=True)
# Detached LUKS header with raw payload
- cmd = 'qemu-io luks-2-payload-raw-format "write -P 41 0 64k"'
- result = self.vm.qmp(
- "human-monitor-command",
- command_line=cmd
- )
- self.assert_qmp(result, "return", "")
+ self.vm.qmp_qemu_io("luks-2-payload-raw-format",
+ "write -P 41 0 64k")
- cmd = 'qemu-io luks-2-payload-raw-format "read -P 41 0 64k"'
- result = self.vm.qmp(
- "human-monitor-command",
- command_line=cmd
- )
- self.assert_qmp(result, "return", "")
+ self.vm.qmp_qemu_io("luks-2-payload-raw-format",
+ "read -P 41 0 64k")
# Detached LUKS header with qcow2 payload
- cmd = 'qemu-io luks-3-payload-qcow2-format "write -P 42 0 64k"'
- result = self.vm.qmp(
- "human-monitor-command",
- command_line=cmd
- )
- self.assert_qmp(result, "return", "")
+ self.vm.qmp_qemu_io("luks-3-payload-qcow2-format",
+ "write -P 42 0 64k")
- cmd = 'qemu-io luks-3-payload-qcow2-format "read -P 42 0 64k"'
- result = self.vm.qmp(
- "human-monitor-command",
- command_line=cmd
- )
- self.assert_qmp(result, "return", "")
+ self.vm.qmp_qemu_io("luks-3-payload-qcow2-format",
+ "read -P 42 0 64k")
self.vm.shutdown()
if __name__ == "__main__":
# Test image creation and I/O
- iotests.main(supported_fmts=["luks"], supported_protocols=["file"],
- require_hmp=True)
+ iotests.main(supported_fmts=["luks"], supported_protocols=["file"])
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* Re: [PATCH 67/88] qemu-iotests/luks-detached-header: migrate away from HMP
2026-09-22 20:18 ` [PATCH 67/88] qemu-iotests/luks-detached-header: " Marc-André Lureau
@ 2026-09-23 4:18 ` Hy Man
0 siblings, 0 replies; 98+ messages in thread
From: Hy Man @ 2026-09-23 4:18 UTC (permalink / raw)
To: Marc-André Lureau; +Cc: qemu-devel, Kevin Wolf, Hanna Reitz, qemu-block
Reviewed-by: Hyman Huang <yong.huang@bitdeer.com>
Thks, Yong
On Wed, Sep 23, 2026 at 4:23 AM Marc-André Lureau
<marcandre.lureau@redhat.com> wrote:
>
> Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
> ---
> tests/qemu-iotests/tests/luks-detached-header | 49 +++++++--------------------
> 1 file changed, 13 insertions(+), 36 deletions(-)
>
> diff --git a/tests/qemu-iotests/tests/luks-detached-header b/tests/qemu-iotests/tests/luks-detached-header
> index 58eb3c2cc484..fbf812902832 100755
> --- a/tests/qemu-iotests/tests/luks-detached-header
> +++ b/tests/qemu-iotests/tests/luks-detached-header
> @@ -266,52 +266,29 @@ class TestDetachedLUKSHeader(QMPTestCase):
> # (Pattern verification will be checked by tearDown())
>
> # Normal LUKS disk
> - result = self.vm.qmp_log(
> - "human-monitor-command",
> - command_line='qemu-io luks-1-format "write -P 40 0 64k"',
> - )
> - self.assert_qmp(result, "return", "")
> + self.vm.qmp_qemu_io("luks-1-format", "write -P 40 0 64k",
> + use_log=True)
>
> - result = self.vm.qmp_log(
> - "human-monitor-command",
> - command_line='qemu-io luks-1-format "read -P 40 0 64k"',
> - )
> - self.assert_qmp(result, "return", "")
> + self.vm.qmp_qemu_io("luks-1-format", "read -P 40 0 64k",
> + use_log=True)
>
> # Detached LUKS header with raw payload
> - cmd = 'qemu-io luks-2-payload-raw-format "write -P 41 0 64k"'
> - result = self.vm.qmp(
> - "human-monitor-command",
> - command_line=cmd
> - )
> - self.assert_qmp(result, "return", "")
> + self.vm.qmp_qemu_io("luks-2-payload-raw-format",
> + "write -P 41 0 64k")
>
> - cmd = 'qemu-io luks-2-payload-raw-format "read -P 41 0 64k"'
> - result = self.vm.qmp(
> - "human-monitor-command",
> - command_line=cmd
> - )
> - self.assert_qmp(result, "return", "")
> + self.vm.qmp_qemu_io("luks-2-payload-raw-format",
> + "read -P 41 0 64k")
>
> # Detached LUKS header with qcow2 payload
> - cmd = 'qemu-io luks-3-payload-qcow2-format "write -P 42 0 64k"'
> - result = self.vm.qmp(
> - "human-monitor-command",
> - command_line=cmd
> - )
> - self.assert_qmp(result, "return", "")
> + self.vm.qmp_qemu_io("luks-3-payload-qcow2-format",
> + "write -P 42 0 64k")
>
> - cmd = 'qemu-io luks-3-payload-qcow2-format "read -P 42 0 64k"'
> - result = self.vm.qmp(
> - "human-monitor-command",
> - command_line=cmd
> - )
> - self.assert_qmp(result, "return", "")
> + self.vm.qmp_qemu_io("luks-3-payload-qcow2-format",
> + "read -P 42 0 64k")
>
> self.vm.shutdown()
>
>
> if __name__ == "__main__":
> # Test image creation and I/O
> - iotests.main(supported_fmts=["luks"], supported_protocols=["file"],
> - require_hmp=True)
> + iotests.main(supported_fmts=["luks"], supported_protocols=["file"])
>
> --
> 2.56.0.rc0.29.g47ce80527c56
>
^ permalink raw reply [flat|nested] 98+ messages in thread
* [PATCH 68/88] qemu-iotests/qcow2-internal-snapshots: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (66 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 67/88] qemu-iotests/luks-detached-header: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 69/88] qemu-iotests/185: " Marc-André Lureau
` (21 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Replace the HMP-based test infrastructure with QMP using common.qemu.
The old _qemu() function piped HMP commands (savevm, loadvm, delvm,
qemu-io) through a monitor stdio pipe. Replace it with interactive QMP
control via _launch_qemu / _send_qemu_cmd, using the job-based QMP
commands snapshot-save, snapshot-load, and snapshot-delete.
These snapshot commands use the JOB_MANUAL_DISMISS flag, so jobs
remain in the "concluded" state until explicitly dismissed. The test
handles this through two helpers:
- _do_snapshot_cmd(): captures noisy QMP events (JOB_STATUS_CHANGE,
STOP, RESUME) during the snapshot operation, silently waits for the
job to reach "concluded", then dismisses it with job-dismiss.
- _do_snapshot_error(): same flow, but before dismissing, queries the
concluded job with query-jobs to retrieve the error message. This
preserves the error verification that HMP provided natively through
its text output.
I/O operations use x-qemu-io via _do_qemu_io(). CLI error cases
(e.g. conflicting -loadvm with -incoming defer or -preconfig) invoke
QEMU directly with stderr redirected, since those errors are emitted
before QMP is available.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/tests/qcow2-internal-snapshots | 226 +++++++++++++++------
.../tests/qcow2-internal-snapshots.out | 175 ++++++++++------
2 files changed, 284 insertions(+), 117 deletions(-)
diff --git a/tests/qemu-iotests/tests/qcow2-internal-snapshots b/tests/qemu-iotests/tests/qcow2-internal-snapshots
index d301f0941b5c..3d6da93e6931 100755
--- a/tests/qemu-iotests/tests/qcow2-internal-snapshots
+++ b/tests/qemu-iotests/tests/qcow2-internal-snapshots
@@ -29,13 +29,16 @@ status=1 # failure is the default!
_cleanup()
{
+ _cleanup_qemu
_cleanup_test_img
}
trap "_cleanup; exit \$status" 0 1 2 3 15
# get standard environment, filters and checks
-. ../common.rc
-. ../common.filter
+cd ..
+. ./common.rc
+. ./common.filter
+. ./common.qemu
# This tests qcow2-specific low-level functionality
_supported_fmt qcow2
@@ -43,20 +46,78 @@ _supported_proto file
# Internal snapshots are (currently) impossible with refcount_bits=1,
# and generally impossible with external data files
_unsupported_imgopts 'compat=0.10' 'refcount_bits=1[^0-9]' data_file
-_require_hmp
IMG_SIZE=64M
-_qemu()
+QEMU_ARGS="-no-shutdown -nodefaults \
+ -blockdev file,filename=$TEST_IMG,node-name=disk0-file \
+ -blockdev $IMGFMT,file=disk0-file,node-name=disk0 \
+ -object iothread,id=iothread0 \
+ -device virtio-scsi,iothread=iothread0 \
+ -device scsi-hd,drive=disk0,share-rw=on"
+
+_do_qemu_io()
{
- $QEMU -no-shutdown -nographic -monitor stdio -serial none \
- -blockdev file,filename="$TEST_IMG",node-name=disk0-file \
- -blockdev "$IMGFMT",file=disk0-file,node-name=disk0 \
- -object iothread,id=iothread0 \
- -device virtio-scsi,iothread=iothread0 \
- -device scsi-hd,drive=disk0,share-rw=on \
- "$@" 2>&1 |\
- _filter_qemu | _filter_hmp | _filter_qemu_io
+ _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk0',
+ 'command': '$1' } }" \
+ 'return'
+}
+
+_do_snapshot_cmd()
+{
+ local cmd="$1" job_id="$2"
+ capture_events="JOB_STATUS_CHANGE STOP RESUME" \
+ _send_qemu_cmd $QEMU_HANDLE "$cmd" 'return'
+ silent=yes _send_qemu_cmd $QEMU_HANDLE '' '"concluded"'
+ silent=yes capture_events="JOB_STATUS_CHANGE" \
+ _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'job-dismiss',
+ 'arguments': { 'id': '$job_id' } }" \
+ 'return'
+}
+
+_do_snapshot_save()
+{
+ _do_snapshot_cmd \
+ "{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': '$2', 'tag': '$1',
+ 'vmstate': 'disk0',
+ 'devices': [\"disk0\"] } }" "$2"
+}
+
+_do_snapshot_load()
+{
+ _do_snapshot_cmd \
+ "{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': '$2', 'tag': '$1',
+ 'vmstate': 'disk0',
+ 'devices': [\"disk0\"] } }" "$2"
+}
+
+_do_snapshot_delete()
+{
+ _do_snapshot_cmd \
+ "{ 'execute': 'snapshot-delete',
+ 'arguments': { 'job-id': '$2', 'tag': '$1',
+ 'devices': [\"disk0\"] } }" "$2"
+}
+
+_do_snapshot_error()
+{
+ local cmd="$1" job_id="$2"
+ capture_events="JOB_STATUS_CHANGE STOP RESUME" \
+ _send_qemu_cmd $QEMU_HANDLE "$cmd" 'return'
+ silent=yes _send_qemu_cmd $QEMU_HANDLE '' '"concluded"'
+ _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'query-jobs' }" \
+ 'return'
+ silent=yes capture_events="JOB_STATUS_CHANGE" \
+ _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'job-dismiss',
+ 'arguments': { 'id': '$job_id' } }" \
+ 'return'
}
_make_test_img $IMG_SIZE
@@ -65,14 +126,16 @@ echo
echo "=== Write some data, take a snapshot and overwrite part of it ==="
echo
-{
- echo 'qemu-io disk0 "write -P0x11 0 1M"'
- # Give qemu some time to boot before saving the VM state
- sleep 0.5
- echo "savevm snap0"
- echo 'qemu-io disk0 "write -P0x22 0 512k"'
- echo "quit"
-} | _qemu
+_launch_qemu $QEMU_ARGS
+_send_qemu_cmd $QEMU_HANDLE "{ 'execute': 'qmp_capabilities' }" 'return'
+
+_do_qemu_io "write -P0x11 0 1M"
+_do_snapshot_save snap0 save0
+_do_qemu_io "write -P0x22 0 512k"
+
+capture_events="JOB_STATUS_CHANGE SHUTDOWN" \
+_send_qemu_cmd $QEMU_HANDLE "{ 'execute': 'quit' }" 'return'
+wait=1 _cleanup_qemu
echo
$QEMU_IMG snapshot -l "$TEST_IMG" | _filter_date | _filter_vmstate_size
@@ -82,26 +145,29 @@ echo
echo "=== Verify that loading the snapshot reverts to the old content ==="
echo
-{
- # -loadvm reverted the write from the previous QEMU instance
- echo 'qemu-io disk0 "read -P0x11 0 1M"'
+# -loadvm reverts the write from the previous QEMU instance
+_launch_qemu $QEMU_ARGS -loadvm snap0
+_send_qemu_cmd $QEMU_HANDLE "{ 'execute': 'qmp_capabilities' }" 'return'
- # Verify that it works without restarting QEMU, too
- echo 'qemu-io disk0 "write -P0x33 512k 512k"'
- echo "loadvm snap0"
- echo 'qemu-io disk0 "read -P0x11 0 1M"'
+_do_qemu_io "read -P0x11 0 1M"
- # Verify COW by writing a partial cluster
- echo 'qemu-io disk0 "write -P0x33 63k 2k"'
- echo 'qemu-io disk0 "read -P0x11 0 63k"'
- echo 'qemu-io disk0 "read -P0x33 63k 2k"'
- echo 'qemu-io disk0 "read -P0x11 65k 63k"'
+# Verify that it works without restarting QEMU, too
+_do_qemu_io "write -P0x33 512k 512k"
+_do_snapshot_load snap0 load0
+_do_qemu_io "read -P0x11 0 1M"
- # Take a second snapshot
- echo "savevm snap1"
+# Verify COW by writing a partial cluster
+_do_qemu_io "write -P0x33 63k 2k"
+_do_qemu_io "read -P0x11 0 63k"
+_do_qemu_io "read -P0x33 63k 2k"
+_do_qemu_io "read -P0x11 65k 63k"
- echo "quit"
-} | _qemu -loadvm snap0
+# Take a second snapshot
+_do_snapshot_save snap1 save1
+
+capture_events="JOB_STATUS_CHANGE SHUTDOWN" \
+_send_qemu_cmd $QEMU_HANDLE "{ 'execute': 'quit' }" 'return'
+wait=1 _cleanup_qemu
echo
$QEMU_IMG snapshot -l "$TEST_IMG" | _filter_date | _filter_vmstate_size
@@ -123,15 +189,19 @@ $QEMU_IO \
echo
echo "=== Deleting snapshots ==="
echo
-{
- # The active layer stays unaffected by deleting the snapshot
- echo "delvm snap1"
- echo 'qemu-io disk0 "read -P0x11 0 63k"'
- echo 'qemu-io disk0 "read -P0x33 63k 2k"'
- echo 'qemu-io disk0 "read -P0x11 65k 63k"'
- echo "quit"
-} | _qemu
+_launch_qemu $QEMU_ARGS
+_send_qemu_cmd $QEMU_HANDLE "{ 'execute': 'qmp_capabilities' }" 'return'
+
+# The active layer stays unaffected by deleting the snapshot
+_do_snapshot_delete snap1 del0
+_do_qemu_io "read -P0x11 0 63k"
+_do_qemu_io "read -P0x33 63k 2k"
+_do_qemu_io "read -P0x11 65k 63k"
+
+capture_events="JOB_STATUS_CHANGE SHUTDOWN" \
+_send_qemu_cmd $QEMU_HANDLE "{ 'execute': 'quit' }" 'return'
+wait=1 _cleanup_qemu
echo
@@ -143,27 +213,69 @@ echo "=== Error cases ==="
echo
# snap1 should not exist any more
-_qemu -loadvm snap1
+$QEMU -no-shutdown -nographic -serial none -nodefaults \
+ -blockdev file,filename="$TEST_IMG",node-name=disk0-file \
+ -blockdev "$IMGFMT",file=disk0-file,node-name=disk0 \
+ -object iothread,id=iothread0 \
+ -device virtio-scsi,iothread=iothread0 \
+ -device scsi-hd,drive=disk0,share-rw=on \
+ -loadvm snap1 2>&1 | _filter_qemu
echo
-{
- echo "loadvm snap1"
- echo "quit"
-} | _qemu
+_launch_qemu $QEMU_ARGS
+_send_qemu_cmd $QEMU_HANDLE "{ 'execute': 'qmp_capabilities' }" 'return'
+_do_snapshot_error \
+ "{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': 'load1', 'tag': 'snap1',
+ 'vmstate': 'disk0',
+ 'devices': [\"disk0\"] } }" load1
+capture_events="JOB_STATUS_CHANGE SHUTDOWN" \
+_send_qemu_cmd $QEMU_HANDLE "{ 'execute': 'quit' }" 'return'
+wait=1 _cleanup_qemu
# Snapshot operations and inactive images are incompatible
echo
-_qemu -loadvm snap0 -incoming defer
-{
- echo "loadvm snap0"
- echo "delvm snap0"
- echo "savevm snap1"
- echo "quit"
-} | _qemu -incoming defer
+$QEMU -no-shutdown -nographic -serial none -nodefaults \
+ -blockdev file,filename="$TEST_IMG",node-name=disk0-file \
+ -blockdev "$IMGFMT",file=disk0-file,node-name=disk0 \
+ -object iothread,id=iothread0 \
+ -device virtio-scsi,iothread=iothread0 \
+ -device scsi-hd,drive=disk0,share-rw=on \
+ -loadvm snap0 -incoming defer 2>&1 | _filter_qemu
+
+_launch_qemu $QEMU_ARGS -incoming defer
+_send_qemu_cmd $QEMU_HANDLE "{ 'execute': 'qmp_capabilities' }" 'return'
+
+_do_snapshot_error \
+ "{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': 'load2', 'tag': 'snap0',
+ 'vmstate': 'disk0',
+ 'devices': [\"disk0\"] } }" load2
+
+_do_snapshot_error \
+ "{ 'execute': 'snapshot-delete',
+ 'arguments': { 'job-id': 'del2', 'tag': 'snap0',
+ 'devices': [\"disk0\"] } }" del2
+
+_do_snapshot_error \
+ "{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save2', 'tag': 'snap1',
+ 'vmstate': 'disk0',
+ 'devices': [\"disk0\"] } }" save2
+
+capture_events="JOB_STATUS_CHANGE SHUTDOWN" \
+_send_qemu_cmd $QEMU_HANDLE "{ 'execute': 'quit' }" 'return'
+wait=1 _cleanup_qemu
# -loadvm and -preconfig are incompatible
echo
-_qemu -loadvm snap0 -preconfig
+$QEMU -no-shutdown -nographic -serial none -nodefaults \
+ -blockdev file,filename="$TEST_IMG",node-name=disk0-file \
+ -blockdev "$IMGFMT",file=disk0-file,node-name=disk0 \
+ -object iothread,id=iothread0 \
+ -device virtio-scsi,iothread=iothread0 \
+ -device scsi-hd,drive=disk0,share-rw=on \
+ -loadvm snap0 -preconfig 2>&1 | _filter_qemu
# success, all done
echo "*** done"
diff --git a/tests/qemu-iotests/tests/qcow2-internal-snapshots.out b/tests/qemu-iotests/tests/qcow2-internal-snapshots.out
index fedb09224ea4..fb602505553b 100644
--- a/tests/qemu-iotests/tests/qcow2-internal-snapshots.out
+++ b/tests/qemu-iotests/tests/qcow2-internal-snapshots.out
@@ -3,15 +3,23 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
=== Write some data, take a snapshot and overwrite part of it ===
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io disk0 "write -P0x11 0 1M"
-wrote 1048576/1048576 bytes at offset 0
-1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) savevm snap0
-(qemu) qemu-io disk0 "write -P0x22 0 512k"
-wrote 524288/524288 bytes at offset 0
-512 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk0',
+ 'command': 'write -P0x11 0 1M' } }
+{"return": {"human-readable-text": "wrote 1048576/1048576 bytes at offset 0\n1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save0', 'tag': 'snap0',
+ 'vmstate': 'disk0',
+ 'devices': ["disk0"] } }
+{"return": {}}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk0',
+ 'command': 'write -P0x22 0 512k' } }
+{"return": {"human-readable-text": "wrote 524288/524288 bytes at offset 0\n512 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{ 'execute': 'quit' }
+{"return": {}}
Snapshot list:
ID TAG VM_SIZE DATE VM_CLOCK ICOUNT
@@ -20,31 +28,48 @@ No errors were found on the image.
=== Verify that loading the snapshot reverts to the old content ===
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io disk0 "read -P0x11 0 1M"
-read 1048576/1048576 bytes at offset 0
-1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) qemu-io disk0 "write -P0x33 512k 512k"
-wrote 524288/524288 bytes at offset 524288
-512 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) loadvm snap0
-(qemu) qemu-io disk0 "read -P0x11 0 1M"
-read 1048576/1048576 bytes at offset 0
-1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) qemu-io disk0 "write -P0x33 63k 2k"
-wrote 2048/2048 bytes at offset 64512
-2 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) qemu-io disk0 "read -P0x11 0 63k"
-read 64512/64512 bytes at offset 0
-63 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) qemu-io disk0 "read -P0x33 63k 2k"
-read 2048/2048 bytes at offset 64512
-2 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) qemu-io disk0 "read -P0x11 65k 63k"
-read 64512/64512 bytes at offset 66560
-63 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) savevm snap1
-(qemu) quit
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk0',
+ 'command': 'read -P0x11 0 1M' } }
+{"return": {"human-readable-text": "read 1048576/1048576 bytes at offset 0\n1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk0',
+ 'command': 'write -P0x33 512k 512k' } }
+{"return": {"human-readable-text": "wrote 524288/524288 bytes at offset 524288\n512 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': 'load0', 'tag': 'snap0',
+ 'vmstate': 'disk0',
+ 'devices': ["disk0"] } }
+{"return": {}}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk0',
+ 'command': 'read -P0x11 0 1M' } }
+{"return": {"human-readable-text": "read 1048576/1048576 bytes at offset 0\n1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk0',
+ 'command': 'write -P0x33 63k 2k' } }
+{"return": {"human-readable-text": "wrote 2048/2048 bytes at offset 64512\n2 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk0',
+ 'command': 'read -P0x11 0 63k' } }
+{"return": {"human-readable-text": "read 64512/64512 bytes at offset 0\n63 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk0',
+ 'command': 'read -P0x33 63k 2k' } }
+{"return": {"human-readable-text": "read 2048/2048 bytes at offset 64512\n2 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk0',
+ 'command': 'read -P0x11 65k 63k' } }
+{"return": {"human-readable-text": "read 64512/64512 bytes at offset 66560\n63 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save1', 'tag': 'snap1',
+ 'vmstate': 'disk0',
+ 'devices': ["disk0"] } }
+{"return": {}}
+{ 'execute': 'quit' }
+{"return": {}}
Snapshot list:
ID TAG VM_SIZE DATE VM_CLOCK ICOUNT
@@ -65,18 +90,26 @@ read 64512/64512 bytes at offset 66560
=== Deleting snapshots ===
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) delvm snap1
-(qemu) qemu-io disk0 "read -P0x11 0 63k"
-read 64512/64512 bytes at offset 0
-63 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) qemu-io disk0 "read -P0x33 63k 2k"
-read 2048/2048 bytes at offset 64512
-2 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) qemu-io disk0 "read -P0x11 65k 63k"
-read 64512/64512 bytes at offset 66560
-63 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'snapshot-delete',
+ 'arguments': { 'job-id': 'del0', 'tag': 'snap1',
+ 'devices': ["disk0"] } }
+{"return": {}}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk0',
+ 'command': 'read -P0x11 0 63k' } }
+{"return": {"human-readable-text": "read 64512/64512 bytes at offset 0\n63 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk0',
+ 'command': 'read -P0x33 63k 2k' } }
+{"return": {"human-readable-text": "read 2048/2048 bytes at offset 64512\n2 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk0',
+ 'command': 'read -P0x11 65k 63k' } }
+{"return": {"human-readable-text": "read 64512/64512 bytes at offset 66560\n63 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{ 'execute': 'quit' }
+{"return": {}}
Snapshot list:
ID TAG VM_SIZE DATE VM_CLOCK ICOUNT
@@ -85,23 +118,45 @@ No errors were found on the image.
=== Error cases ===
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) QEMU_PROG: Snapshot 'snap1' does not exist in one or more devices
+QEMU_PROG: Snapshot 'snap1' does not exist in one or more devices
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) loadvm snap1
-Error: Snapshot 'snap1' does not exist in one or more devices
-(qemu) quit
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': 'load1', 'tag': 'snap1',
+ 'vmstate': 'disk0',
+ 'devices': ["disk0"] } }
+{"return": {}}
+{ 'execute': 'query-jobs' }
+{"return": [{"current-progress": 1, "status": "concluded", "total-progress": 1, "type": "snapshot-load", "id": "load1", "error": "Snapshot 'snap1' does not exist in one or more devices"}]}
+{ 'execute': 'quit' }
+{"return": {}}
QEMU_PROG: 'incoming' and 'loadvm' options are mutually exclusive
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) loadvm snap0
-Error: Device 'disk0' is writable but does not support snapshots
-(qemu) delvm snap0
-Error: Device 'disk0' is writable but does not support snapshots
-(qemu) savevm snap1
-Error: Device 'disk0' is writable but does not support snapshots
-(qemu) quit
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': 'load2', 'tag': 'snap0',
+ 'vmstate': 'disk0',
+ 'devices': ["disk0"] } }
+{"return": {}}
+{ 'execute': 'query-jobs' }
+{"return": [{"current-progress": 1, "status": "concluded", "total-progress": 1, "type": "snapshot-load", "id": "load2", "error": "Device 'disk0' is writable but does not support snapshots"}]}
+{ 'execute': 'snapshot-delete',
+ 'arguments': { 'job-id': 'del2', 'tag': 'snap0',
+ 'devices': ["disk0"] } }
+{"return": {}}
+{ 'execute': 'query-jobs' }
+{"return": [{"current-progress": 1, "status": "concluded", "total-progress": 1, "type": "snapshot-delete", "id": "del2", "error": "Device 'disk0' is writable but does not support snapshots"}]}
+{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save2', 'tag': 'snap1',
+ 'vmstate': 'disk0',
+ 'devices': ["disk0"] } }
+{"return": {}}
+{ 'execute': 'query-jobs' }
+{"return": [{"current-progress": 1, "status": "concluded", "total-progress": 1, "type": "snapshot-save", "id": "save2", "error": "Device 'disk0' is writable but does not support snapshots"}]}
+{ 'execute': 'quit' }
+{"return": {}}
QEMU_PROG: 'preconfig' and 'loadvm' options are mutually exclusive
*** done
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 69/88] qemu-iotests/185: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (67 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 68/88] qemu-iotests/qcow2-internal-snapshots: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 70/88] qemu-iotests/246: " Marc-André Lureau
` (20 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/185 | 15 ++++++---------
tests/qemu-iotests/185.out | 10 ++++------
2 files changed, 10 insertions(+), 15 deletions(-)
diff --git a/tests/qemu-iotests/185 b/tests/qemu-iotests/185
index bb577a9cc999..c43d579676eb 100755
--- a/tests/qemu-iotests/185
+++ b/tests/qemu-iotests/185
@@ -50,7 +50,6 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
_supported_fmt qcow2
_supported_proto file
_supported_os Linux
-_require_hmp
_flaky_test https://gitlab.com/qemu-project/qemu/-/issues/3270
size=$((64 * 1048576))
@@ -80,9 +79,9 @@ _send_qemu_cmd $h \
"return"
_send_qemu_cmd $h \
- "{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line':
- 'qemu-io disk \"write 0 4M\"' } }" \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk',
+ 'command': 'write 0 4M' } }" \
"return"
_send_qemu_cmd $h \
@@ -307,15 +306,13 @@ wait_for_job_and_quit() {
echo '--- Writing data to the virtio-blk device ---'
for ofs in $(seq 0 $step $((size - step))); do
- qemu_io_cmd="qemu-io -d vblk/virtio-backend "
- qemu_io_cmd+="\\\"aio_write $ofs $cluster_size\\\""
-
# Do not include these requests in the reference output
# (it's just too much)
silent=yes _send_qemu_cmd $h \
- "{\"execute\": \"human-monitor-command\",
+ "{\"execute\": \"x-qemu-io\",
\"arguments\": {
- \"command-line\": \"$qemu_io_cmd\"
+ \"qdev\": \"vblk/virtio-backend\",
+ \"command\": \"aio_write $ofs $cluster_size\"
}}" \
'return'
done
diff --git a/tests/qemu-iotests/185.out b/tests/qemu-iotests/185.out
index 6af0953c4d68..d05f359080b9 100644
--- a/tests/qemu-iotests/185.out
+++ b/tests/qemu-iotests/185.out
@@ -15,12 +15,10 @@ Formatting 'TEST_DIR/t.IMGFMT.base', fmt=IMGFMT size=67108864
'mode': 'absolute-paths' } }
Formatting 'TEST_DIR/t.qcow2.mid', fmt=qcow2 cluster_size=65536 extended_l2=off compression_type=zlib size=67108864 backing_file=TEST_DIR/t.qcow2.base backing_fmt=qcow2 lazy_refcounts=off refcount_bits=16
{"return": {}}
-{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line':
- 'qemu-io disk "write 0 4M"' } }
-wrote 4194304/4194304 bytes at offset 0
-4 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-{"return": ""}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk',
+ 'command': 'write 0 4M' } }
+{"return": {"human-readable-text": "wrote 4194304/4194304 bytes at offset 0\n4 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
{ 'execute': 'blockdev-snapshot-sync',
'arguments': { 'device': 'disk',
'snapshot-file': 'TEST_DIR/t.IMGFMT',
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 70/88] qemu-iotests/246: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (68 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 69/88] qemu-iotests/185: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 71/88] qemu-iotests/274: " Marc-André Lureau
` (19 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/246 | 11 +++++------
tests/qemu-iotests/246.out | 8 ++++----
2 files changed, 9 insertions(+), 10 deletions(-)
diff --git a/tests/qemu-iotests/246 b/tests/qemu-iotests/246
index cee5131c3ce4..a821e2cab8ea 100755
--- a/tests/qemu-iotests/246
+++ b/tests/qemu-iotests/246
@@ -24,8 +24,7 @@ import iotests
from iotests import log
iotests.script_initialize(supported_fmts=['qcow2'],
- unsupported_imgopts=['compat'],
- require_hmp=True)
+ unsupported_imgopts=['compat'])
size = 64 * 1024 * 1024 * 1024
gran_small = 32 * 1024
gran_large = 128 * 1024
@@ -69,8 +68,8 @@ with iotests.FilePath('img') as img_path, \
log('--- Adding new bitmap, growing image, and adding 2nd new bitmap ---')
vm.qmp_log("block-dirty-bitmap-add", node="drive0",
name="New", persistent=True)
- vm.qmp_log("human-monitor-command",
- command_line="block_resize drive0 70G")
+ vm.qmp_log("block_resize", device="drive0",
+ size=70 * 1024 * 1024 * 1024)
vm.qmp_log("block-dirty-bitmap-add", node="drive0",
name="Newtwo", persistent=True)
log(query_bitmaps(vm), indent=2)
@@ -90,8 +89,8 @@ with iotests.FilePath('img') as img_path, \
name="New")
log('--- Truncating image ---\n')
- vm.qmp_log("human-monitor-command",
- command_line="block_resize drive0 50G")
+ vm.qmp_log("block_resize", device="drive0",
+ size=50 * 1024 * 1024 * 1024)
log('--- Adding "NewC" bitmap, removing "NewTwo" bitmap ---')
vm.qmp_log("block-dirty-bitmap-add", node="drive0",
diff --git a/tests/qemu-iotests/246.out b/tests/qemu-iotests/246.out
index eeb98ab37c93..dde5bfb6d42c 100644
--- a/tests/qemu-iotests/246.out
+++ b/tests/qemu-iotests/246.out
@@ -88,8 +88,8 @@
--- Adding new bitmap, growing image, and adding 2nd new bitmap ---
{"execute": "block-dirty-bitmap-add", "arguments": {"name": "New", "node": "drive0", "persistent": true}}
{"return": {}}
-{"execute": "human-monitor-command", "arguments": {"command-line": "block_resize drive0 70G"}}
-{"return": ""}
+{"execute": "block_resize", "arguments": {"device": "drive0", "size": 75161927680}}
+{"return": {}}
{"execute": "block-dirty-bitmap-add", "arguments": {"name": "Newtwo", "node": "drive0", "persistent": true}}
{"return": {}}
{
@@ -195,8 +195,8 @@
{"return": {}}
--- Truncating image ---
-{"execute": "human-monitor-command", "arguments": {"command-line": "block_resize drive0 50G"}}
-{"return": ""}
+{"execute": "block_resize", "arguments": {"device": "drive0", "size": 53687091200}}
+{"return": {}}
--- Adding "NewC" bitmap, removing "NewTwo" bitmap ---
{"execute": "block-dirty-bitmap-add", "arguments": {"name": "NewC", "node": "drive0", "persistent": true}}
{"return": {}}
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 71/88] qemu-iotests/274: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (69 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 70/88] qemu-iotests/246: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 72/88] qemu-iotests/145: " Marc-André Lureau
` (18 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Drop the quite redundant HMP code path.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/274 | 14 +-------------
tests/qemu-iotests/274.out | 26 --------------------------
2 files changed, 1 insertion(+), 39 deletions(-)
diff --git a/tests/qemu-iotests/274 b/tests/qemu-iotests/274
index d91c11c70d2e..917982ec63bf 100755
--- a/tests/qemu-iotests/274
+++ b/tests/qemu-iotests/274
@@ -24,8 +24,7 @@ import iotests
iotests.script_initialize(supported_fmts=['qcow2'],
supported_platforms=['linux'],
- unsupported_imgopts=['refcount_bits', 'compat'],
- require_hmp=True)
+ unsupported_imgopts=['refcount_bits', 'compat'])
size_short = 1 * 1024 * 1024
size_long = 2 * 1024 * 1024
@@ -93,17 +92,6 @@ with iotests.FilePath('base') as base, \
iotests.qemu_io_log('-c', 'read -P 1 0 %d' % size_short, mid)
iotests.qemu_io_log('-c', 'read -P 0 %d %d' % (size_short, size_diff), mid)
- iotests.log('=== Testing HMP commit (top -> mid) ===')
-
- create_chain()
- with create_vm() as vm:
- vm.launch()
- vm.qmp_log('human-monitor-command', command_line='commit drive0')
-
- iotests.img_info_log(mid)
- iotests.qemu_io_log('-c', 'read -P 1 0 %d' % size_short, mid)
- iotests.qemu_io_log('-c', 'read -P 0 %d %d' % (size_short, size_diff), mid)
-
iotests.log('=== Testing QMP active commit (top -> mid) ===')
create_chain()
diff --git a/tests/qemu-iotests/274.out b/tests/qemu-iotests/274.out
index c2967335ca09..ef1d2d993c9f 100644
--- a/tests/qemu-iotests/274.out
+++ b/tests/qemu-iotests/274.out
@@ -59,32 +59,6 @@ read 1048576/1048576 bytes at offset 0
read 1048576/1048576 bytes at offset 1048576
1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-=== Testing HMP commit (top -> mid) ===
-wrote 2097152/2097152 bytes at offset 0
-2 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-
-{"execute": "human-monitor-command", "arguments": {"command-line": "commit drive0"}}
-{"return": ""}
-image: TEST_IMG
-file format: IMGFMT
-virtual size: 2 MiB (2097152 bytes)
-cluster_size: 65536
-backing file: TEST_DIR/PID-base
-backing file format: IMGFMT
-Format specific information:
- compat: 1.1
- compression type: COMPRESSION_TYPE
- lazy refcounts: false
- refcount bits: 16
- corrupt: false
- extended l2: false
-
-read 1048576/1048576 bytes at offset 0
-1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-
-read 1048576/1048576 bytes at offset 1048576
-1 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-
=== Testing QMP active commit (top -> mid) ===
wrote 2097152/2097152 bytes at offset 0
2 MiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 72/88] qemu-iotests/145: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (70 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 71/88] qemu-iotests/274: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 73/88] qemu-iotests/068: " Marc-André Lureau
` (17 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/145 | 8 ++++----
tests/qemu-iotests/145.out | 6 ++++--
2 files changed, 8 insertions(+), 6 deletions(-)
diff --git a/tests/qemu-iotests/145 b/tests/qemu-iotests/145
index f61a50f63951..d763ea14417a 100755
--- a/tests/qemu-iotests/145
+++ b/tests/qemu-iotests/145
@@ -40,7 +40,6 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
_supported_fmt generic
_supported_proto generic
-_require_hmp
_make_test_img 1M
@@ -57,9 +56,10 @@ else
SYSEMU_EXTRA_ARGS=""
fi
-echo quit | $QEMU -nographic $SYSEMU_EXTRA_ARGS -drive $SYSEMU_DRIVE_ARG \
- -incoming 'exec:true' -snapshot -serial none -monitor stdio \
- | _filter_qemu | _filter_hmp
+printf '%s\n' '{"execute":"qmp_capabilities"}' '{"execute":"quit"}' \
+ | $QEMU -nographic $SYSEMU_EXTRA_ARGS -drive $SYSEMU_DRIVE_ARG \
+ -incoming 'exec:true' -snapshot -serial none -qmp stdio \
+ | _filter_qmp | _filter_qemu
# success, all done
echo "*** done"
diff --git a/tests/qemu-iotests/145.out b/tests/qemu-iotests/145.out
index 9a90009e44e3..d7ab88904278 100644
--- a/tests/qemu-iotests/145.out
+++ b/tests/qemu-iotests/145.out
@@ -1,5 +1,7 @@
QA output created by 145
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=1048576
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
*** done
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 73/88] qemu-iotests/068: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (71 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 72/88] qemu-iotests/145: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 74/88] qemu-iotests/130: " Marc-André Lureau
` (16 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Replace HMP savevm/loadvm with QMP snapshot-save/snapshot-load
job-based API. Use _run_qmp_job() helper to factor the common
send/wait/dismiss pattern.
The sleep before sending commands is no longer needed: the QMP
qmp_capabilities handshake is synchronous, so QEMU is guaranteed
to be ready.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/068 | 56 ++++++++++++++++++++++++++++++++++------------
tests/qemu-iotests/068.out | 26 ++++++++++-----------
2 files changed, 54 insertions(+), 28 deletions(-)
diff --git a/tests/qemu-iotests/068 b/tests/qemu-iotests/068
index 11b660a8b7c4..0b756862c1c3 100755
--- a/tests/qemu-iotests/068
+++ b/tests/qemu-iotests/068
@@ -29,6 +29,7 @@ status=1 # failure is the default!
_cleanup()
{
+ _cleanup_qemu
_cleanup_test_img
}
trap "_cleanup; exit \$status" 0 1 2 3 15
@@ -36,6 +37,7 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
# get standard environment, filters and checks
. ./common.rc
. ./common.filter
+. ./common.qemu
# This tests qcow2-specific low-level functionality
_supported_fmt qcow2
@@ -43,7 +45,6 @@ _supported_proto generic
# Internal snapshots are (currently) impossible with refcount_bits=1,
# and generally impossible with external data files
_unsupported_imgopts 'compat=0.10' 'refcount_bits=1[^0-9]' data_file
-_require_hmp
IMG_SIZE=128K
@@ -56,16 +57,6 @@ case "$QEMU_DEFAULT_MACHINE" in
;;
esac
-_qemu()
-{
- $QEMU $platform_parm -nographic -monitor stdio -serial none \
- -drive if=none,id=drive0,file="$TEST_IMG",format="$IMGFMT" \
- -device virtio-scsi,id=hba0 \
- -device scsi-hd,drive=drive0 \
- "$@" |\
- _filter_qemu | _filter_hmp
-}
-
for extra_args in \
"" \
"-object iothread,id=iothread0 -set device.hba0.iothread=iothread0"; do
@@ -75,10 +66,47 @@ for extra_args in \
_make_test_img $IMG_SIZE
- # Give qemu some time to boot before saving the VM state
- { sleep 1; printf "savevm 0\nquit\n"; } | _qemu $extra_args
+ # Save VM state
+ _launch_qemu $platform_parm \
+ -drive if=none,id=drive0,node-name=disk0,file="$TEST_IMG",format="$IMGFMT" \
+ -device virtio-scsi,id=hba0 \
+ -device scsi-hd,drive=drive0 \
+ $extra_args
+ silent=yes _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'qmp_capabilities' }" \
+ 'return'
+ silent=yes _run_qmp_job $QEMU_HANDLE 'save0' \
+ "{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save0',
+ 'tag': '0',
+ 'vmstate': 'disk0',
+ 'devices': ['disk0'] } }"
+ _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'quit' }" \
+ 'return'
+ wait=1 _cleanup_qemu
+
# Now try to continue from that VM state (this should just work)
- { sleep 1; printf "loadvm 0\nloadvm 0\nquit\n"; } | _qemu $extra_args -S
+ _launch_qemu $platform_parm \
+ -drive if=none,id=drive0,node-name=disk0,file="$TEST_IMG",format="$IMGFMT" \
+ -device virtio-scsi,id=hba0 \
+ -device scsi-hd,drive=drive0 \
+ -S $extra_args
+ silent=yes _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'qmp_capabilities' }" \
+ 'return'
+ for i in 1 2; do
+ silent=yes _run_qmp_job $QEMU_HANDLE "load$i" \
+ "{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': 'load$i',
+ 'tag': '0',
+ 'vmstate': 'disk0',
+ 'devices': ['disk0'] } }"
+ done
+ _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'quit' }" \
+ 'return'
+ wait=1 _cleanup_qemu
done
# success, all done
diff --git a/tests/qemu-iotests/068.out b/tests/qemu-iotests/068.out
index f07a938a3838..3bc0b5a771db 100644
--- a/tests/qemu-iotests/068.out
+++ b/tests/qemu-iotests/068.out
@@ -3,22 +3,20 @@ QA output created by 068
=== Saving and reloading a VM state to/from a qcow2 image () ===
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=131072
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) savevm 0
-(qemu) quit
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) loadvm 0
-(qemu) loadvm 0
-(qemu) quit
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
=== Saving and reloading a VM state to/from a qcow2 image (-object iothread,id=iothread0 -set device.hba0.iothread=iothread0) ===
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=131072
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) savevm 0
-(qemu) quit
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) loadvm 0
-(qemu) loadvm 0
-(qemu) quit
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
*** done
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 74/88] qemu-iotests/130: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (72 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 73/88] qemu-iotests/068: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 75/88] qemu-iotests/153: " Marc-André Lureau
` (15 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Replace HMP commit with QMP block-commit job-based API, using
_run_qmp_job() helper for the complete/dismiss sequence. Silence
all QMP output since the test validates backing file path
preservation via _img_info, not the commit protocol itself.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/130 | 53 +++++++++++++++++++++++++++++++++++++---------
tests/qemu-iotests/130.out | 8 +------
2 files changed, 44 insertions(+), 17 deletions(-)
diff --git a/tests/qemu-iotests/130 b/tests/qemu-iotests/130
index 3d10aba2594e..beb5ef24c0f1 100755
--- a/tests/qemu-iotests/130
+++ b/tests/qemu-iotests/130
@@ -46,9 +46,6 @@ _supported_proto file
_supported_os Linux
# We are going to use lazy-refcounts
_unsupported_imgopts 'compat=0.10'
-_require_hmp
-
-qemu_comm_method="monitor"
TEST_IMG="$TEST_IMG.orig" _make_test_img 64M
@@ -57,24 +54,60 @@ _make_test_img 64M
_img_info | _filter_img_info
echo
-echo "=== HMP commit ==="
+echo "=== commit ==="
echo
# bdrv_make_empty() involves a header update for qcow2
# Test that a backing file isn't written
_launch_qemu -drive id=testdisk,file="$TEST_IMG",backing.file.filename="$TEST_IMG.base"
-_send_qemu_cmd $QEMU_HANDLE "commit testdisk" "(qemu)"
-_send_qemu_cmd $QEMU_HANDLE '' '(qemu)'
-_cleanup_qemu
+silent=yes _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'qmp_capabilities' }" \
+ 'return'
+silent=yes _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'block-commit',
+ 'arguments': { 'device': 'testdisk',
+ 'job-id': 'job0',
+ 'auto-dismiss': false } }" \
+ 'BLOCK_JOB_READY'
+silent=yes _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'block-job-complete',
+ 'arguments': { 'device': 'job0' } }" \
+ 'return'
+silent=yes _send_qemu_cmd $QEMU_HANDLE '' '"concluded"'
+silent=yes _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'job-dismiss',
+ 'arguments': { 'id': 'job0' } }" 'return'
+silent=yes _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'quit' }" \
+ 'return'
+wait=1 _cleanup_qemu
_img_info | _filter_img_info
# Make sure that if there was a backing file that was just overridden on the
# command line, that backing file is retained, with the right format
_make_test_img -F raw -b "$TEST_IMG.orig" 64M
_launch_qemu -drive id=testdisk,file="$TEST_IMG",backing.file.filename="$TEST_IMG.base",backing.driver=$IMGFMT
-_send_qemu_cmd $QEMU_HANDLE "commit testdisk" "(qemu)"
-_send_qemu_cmd $QEMU_HANDLE '' '(qemu)'
-_cleanup_qemu
+silent=yes _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'qmp_capabilities' }" \
+ 'return'
+silent=yes _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'block-commit',
+ 'arguments': { 'device': 'testdisk',
+ 'job-id': 'job0',
+ 'auto-dismiss': false } }" \
+ 'BLOCK_JOB_READY'
+silent=yes _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'block-job-complete',
+ 'arguments': { 'device': 'job0' } }" \
+ 'return'
+silent=yes _send_qemu_cmd $QEMU_HANDLE '' '"concluded"'
+silent=yes _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'job-dismiss',
+ 'arguments': { 'id': 'job0' } }" 'return'
+silent=yes _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'quit' }" \
+ 'return'
+wait=1 _cleanup_qemu
_img_info | _filter_img_info
echo
diff --git a/tests/qemu-iotests/130.out b/tests/qemu-iotests/130.out
index e45285ccc311..f9109d6ed9db 100644
--- a/tests/qemu-iotests/130.out
+++ b/tests/qemu-iotests/130.out
@@ -6,18 +6,12 @@ image: TEST_DIR/t.IMGFMT
file format: IMGFMT
virtual size: 64 MiB (67108864 bytes)
-=== HMP commit ===
+=== commit ===
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) commit testdisk
-(qemu)
image: TEST_DIR/t.IMGFMT
file format: IMGFMT
virtual size: 64 MiB (67108864 bytes)
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864 backing_file=TEST_DIR/t.IMGFMT.orig backing_fmt=raw
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) commit testdisk
-(qemu)
image: TEST_DIR/t.IMGFMT
file format: IMGFMT
virtual size: 64 MiB (67108864 bytes)
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 75/88] qemu-iotests/153: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (73 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 74/88] qemu-iotests/130: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 76/88] qemu-iotests/157: " Marc-André Lureau
` (14 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Replace HMP drive_add/drive_del with QMP blockdev-add/blockdev-del.
Convert pipe-based monitor to QMP.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/153 | 37 +++++++++++++++++++++----------------
tests/qemu-iotests/153.out | 44 ++++++++++++++++++++++++++------------------
2 files changed, 47 insertions(+), 34 deletions(-)
diff --git a/tests/qemu-iotests/153 b/tests/qemu-iotests/153
index def01d6f3ea4..12807c2cb5c1 100755
--- a/tests/qemu-iotests/153
+++ b/tests/qemu-iotests/153
@@ -59,7 +59,6 @@ _check_ofd || _notrun "OFD lock not available"
_supported_fmt qcow2
_supported_proto file
-_require_hmp
_run_cmd()
{
@@ -70,13 +69,14 @@ _run_cmd()
_do_run_qemu()
{
(
+ echo '{"execute":"qmp_capabilities"}'
if ! test -t 0; then
while read cmd; do
- echo $cmd
+ echo "$cmd"
done
fi
- echo quit
- ) | $QEMU -nographic -monitor stdio -serial none "$@" 1>/dev/null
+ echo '{"execute":"quit"}'
+ ) | $QEMU -nographic -qmp stdio -serial none "$@" 1>/dev/null
}
_run_qemu_with_images()
@@ -106,8 +106,8 @@ for opts1 in "" "read-only=on" "read-only=on,force-share=on"; do
for opts2 in "" "read-only=on" "read-only=on,force-share=on"; do
echo
echo "== Launching another QEMU, opts: '$opts2' =="
- echo "quit" | \
- $QEMU -nographic -monitor stdio \
+ printf '%s\n' '{"execute":"qmp_capabilities"}' '{"execute":"quit"}' | \
+ $QEMU -nographic -qmp stdio \
-drive file="${TEST_IMG}",if=none,$opts2 2>&1 1>/dev/null | \
_filter_testdir | _filter_qemu
done
@@ -213,8 +213,10 @@ _send_qemu_cmd $QEMU_HANDLE \
echo "Adding drive"
_send_qemu_cmd $QEMU_HANDLE \
- "{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line': 'drive_add 0 if=none,id=d0,file=${TEST_IMG}' } }" \
+ "{ 'execute': 'blockdev-add',
+ 'arguments': { 'driver': '$IMGFMT', 'node-name': 'd0',
+ 'file': { 'driver': 'file',
+ 'filename': '${TEST_IMG}' } } }" \
'return'
_run_cmd $QEMU_IO "${TEST_IMG}" -c 'write 0 512'
@@ -224,8 +226,8 @@ _run_cmd $QEMU_IMG create -f $IMGFMT -b "${TEST_IMG}" -F $IMGFMT "${TEST_IMG}.ov
echo "== Closing an image should unlock it =="
_send_qemu_cmd $QEMU_HANDLE \
- "{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line': 'drive_del d0' } }" \
+ "{ 'execute': 'blockdev-del',
+ 'arguments': { 'node-name': 'd0' } }" \
'return'
_run_cmd $QEMU_IO "${TEST_IMG}" -c 'write 0 512'
@@ -233,24 +235,27 @@ _run_cmd $QEMU_IO "${TEST_IMG}" -c 'write 0 512'
echo "Adding two and closing one"
for d in d0 d1; do
_send_qemu_cmd $QEMU_HANDLE \
- "{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line': 'drive_add 0 if=none,id=$d,file=${TEST_IMG},readonly=on' } }" \
+ "{ 'execute': 'blockdev-add',
+ 'arguments': { 'driver': '$IMGFMT', 'node-name': '$d',
+ 'read-only': true,
+ 'file': { 'driver': 'file',
+ 'filename': '${TEST_IMG}' } } }" \
'return'
done
_run_cmd $QEMU_IMG info "${TEST_IMG}"
_send_qemu_cmd $QEMU_HANDLE \
- "{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line': 'drive_del d0' } }" \
+ "{ 'execute': 'blockdev-del',
+ 'arguments': { 'node-name': 'd0' } }" \
'return'
_run_cmd $QEMU_IO "${TEST_IMG}" -c 'write 0 512'
echo "Closing the other"
_send_qemu_cmd $QEMU_HANDLE \
- "{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line': 'drive_del d1' } }" \
+ "{ 'execute': 'blockdev-del',
+ 'arguments': { 'node-name': 'd1' } }" \
'return'
_run_cmd $QEMU_IO "${TEST_IMG}" -c 'write 0 512'
diff --git a/tests/qemu-iotests/153.out b/tests/qemu-iotests/153.out
index 1607a79b36b7..90d0ac660a1f 100644
--- a/tests/qemu-iotests/153.out
+++ b/tests/qemu-iotests/153.out
@@ -425,9 +425,11 @@ _qemu_img_wrapper commit -b TEST_DIR/t.qcow2.b TEST_DIR/t.qcow2.c
{ 'execute': 'qmp_capabilities' }
{"return": {}}
Adding drive
-{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line': 'drive_add 0 if=none,id=d0,file=TEST_DIR/t.IMGFMT' } }
-{"return": "OKrn"}
+{ 'execute': 'blockdev-add',
+ 'arguments': { 'driver': 'IMGFMT', 'node-name': 'd0',
+ 'file': { 'driver': 'file',
+ 'filename': 'TEST_DIR/t.IMGFMT' } } }
+{"return": {}}
_qemu_io_wrapper TEST_DIR/t.qcow2 -c write 0 512
can't open device TEST_DIR/t.qcow2: Failed to get "write" lock
@@ -436,31 +438,37 @@ Creating overlay with qemu-img when the guest is running should be allowed
_qemu_img_wrapper create -f qcow2 -b TEST_DIR/t.qcow2 -F qcow2 TEST_DIR/t.qcow2.overlay
== Closing an image should unlock it ==
-{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line': 'drive_del d0' } }
-{"return": ""}
+{ 'execute': 'blockdev-del',
+ 'arguments': { 'node-name': 'd0' } }
+{"return": {}}
_qemu_io_wrapper TEST_DIR/t.qcow2 -c write 0 512
Adding two and closing one
-{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line': 'drive_add 0 if=none,id=d0,file=TEST_DIR/t.IMGFMT,readonly=on' } }
-{"return": "OKrn"}
-{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line': 'drive_add 0 if=none,id=d1,file=TEST_DIR/t.IMGFMT,readonly=on' } }
-{"return": "OKrn"}
+{ 'execute': 'blockdev-add',
+ 'arguments': { 'driver': 'IMGFMT', 'node-name': 'd0',
+ 'read-only': true,
+ 'file': { 'driver': 'file',
+ 'filename': 'TEST_DIR/t.IMGFMT' } } }
+{"return": {}}
+{ 'execute': 'blockdev-add',
+ 'arguments': { 'driver': 'IMGFMT', 'node-name': 'd1',
+ 'read-only': true,
+ 'file': { 'driver': 'file',
+ 'filename': 'TEST_DIR/t.IMGFMT' } } }
+{"return": {}}
_qemu_img_wrapper info TEST_DIR/t.qcow2
-{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line': 'drive_del d0' } }
-{"return": ""}
+{ 'execute': 'blockdev-del',
+ 'arguments': { 'node-name': 'd0' } }
+{"return": {}}
_qemu_io_wrapper TEST_DIR/t.qcow2 -c write 0 512
can't open device TEST_DIR/t.qcow2: Failed to get "write" lock
Is another process using the image [TEST_DIR/t.qcow2]?
Closing the other
-{ 'execute': 'human-monitor-command',
- 'arguments': { 'command-line': 'drive_del d1' } }
-{"return": ""}
+{ 'execute': 'blockdev-del',
+ 'arguments': { 'node-name': 'd1' } }
+{"return": {}}
_qemu_io_wrapper TEST_DIR/t.qcow2 -c write 0 512
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 76/88] qemu-iotests/157: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (74 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 75/88] qemu-iotests/153: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 77/88] qemu-iotests/181: " Marc-André Lureau
` (13 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Replace HMP "info block" with QMP "query-block". The expected
output changes from HMP "Cache mode: writeback/writethrough" to
QMP "writeback": true/false.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/157 | 10 +++++-----
tests/qemu-iotests/157.out | 16 ++++++++--------
2 files changed, 13 insertions(+), 13 deletions(-)
diff --git a/tests/qemu-iotests/157 b/tests/qemu-iotests/157
index 531dbd3122b1..2f9d73155a10 100755
--- a/tests/qemu-iotests/157
+++ b/tests/qemu-iotests/157
@@ -41,18 +41,18 @@ _supported_fmt generic
_supported_proto file
_require_devices virtio-blk
-_require_hmp
do_run_qemu()
{
(
+ printf '%s\n' '{"execute":"qmp_capabilities"}'
if ! test -t 0; then
while read cmd; do
echo $cmd
done
fi
- echo quit
- ) | $QEMU -nodefaults -nographic -monitor stdio -serial none "$@"
+ printf '%s\n' '{"execute":"quit"}'
+ ) | $QEMU -nodefaults -nographic -qmp stdio -serial none "$@"
echo
}
@@ -89,10 +89,10 @@ echo
for cache in "writeback" "writethrough"; do
for wce in "" ",write-cache=auto" ",write-cache=on" ",write-cache=off"; do
echo "Testing: cache='$cache' wce='$wce'"
- echo "info block" \
+ echo '{"execute":"query-block"}' \
| run_qemu $SYSEMU_EXTRA_ARGS -drive "$SYSEMU_DRIVE_ARG,cache=$cache" \
-device "virtio-blk,drive=none0$wce" \
- | grep -e "Testing" -e "Cache mode"
+ | grep -o '"writeback": *[a-z]*'
done
done
diff --git a/tests/qemu-iotests/157.out b/tests/qemu-iotests/157.out
index fdc807f541f3..f6c345f143cc 100644
--- a/tests/qemu-iotests/157.out
+++ b/tests/qemu-iotests/157.out
@@ -4,19 +4,19 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
=== Setting WCE with qdev and with manually created BB ===
Testing: cache='writeback' wce=''
- Cache mode: writeback
+"writeback": true
Testing: cache='writeback' wce=',write-cache=auto'
- Cache mode: writeback
+"writeback": true
Testing: cache='writeback' wce=',write-cache=on'
- Cache mode: writeback
+"writeback": true
Testing: cache='writeback' wce=',write-cache=off'
- Cache mode: writethrough
+"writeback": false
Testing: cache='writethrough' wce=''
- Cache mode: writethrough
+"writeback": false
Testing: cache='writethrough' wce=',write-cache=auto'
- Cache mode: writethrough
+"writeback": false
Testing: cache='writethrough' wce=',write-cache=on'
- Cache mode: writeback
+"writeback": true
Testing: cache='writethrough' wce=',write-cache=off'
- Cache mode: writethrough
+"writeback": false
*** done
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 77/88] qemu-iotests/181: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (75 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 76/88] qemu-iotests/157: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 78/88] qemu-iotests/182: " Marc-André Lureau
` (12 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Replace HMP migration and savevm/loadvm commands with QMP equivalents.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/181 | 86 ++++++++++++++++++++++++++++++++--------------
tests/qemu-iotests/181.out | 36 +++++++++----------
2 files changed, 78 insertions(+), 44 deletions(-)
diff --git a/tests/qemu-iotests/181 b/tests/qemu-iotests/181
index 458cb737f1cb..d814a1b8226e 100755
--- a/tests/qemu-iotests/181
+++ b/tests/qemu-iotests/181
@@ -47,7 +47,6 @@ _supported_fmt generic
_unsupported_fmt qcow vdi vhdx vmdk vpc vvfat parallels
_supported_proto generic
_supported_os Linux
-_require_hmp
_flaky_test https://gitlab.com/qemu-project/qemu/-/work_items/3515
@@ -58,8 +57,6 @@ echo
echo === Starting VMs ===
echo
-qemu_comm_method="monitor"
-
if [ "$IMGOPTSSYNTAX" = "true" ]; then
_launch_qemu \
-drive "${TEST_IMG}",cache=${CACHEMODE},aio=$AIOMODE,id=disk
@@ -80,15 +77,27 @@ else
fi
dest=$QEMU_HANDLE
+silent=yes
+_send_qemu_cmd $src \
+ "{ 'execute': 'qmp_capabilities' }" \
+ 'return'
+_send_qemu_cmd $dest \
+ "{ 'execute': 'qmp_capabilities' }" \
+ 'return'
+
echo
echo === Write something on the source ===
echo
silent=
-_send_qemu_cmd $src 'qemu-io disk "write -P 0x55 0 64k"' "(qemu)"
-_send_qemu_cmd $src "" "ops/sec"
-_send_qemu_cmd $src 'qemu-io disk "read -P 0x55 0 64k"' "(qemu)"
-_send_qemu_cmd $src "" "ops/sec"
+_send_qemu_cmd $src \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk', 'command': 'write -P 0x55 0 64k' } }" \
+ 'return'
+_send_qemu_cmd $src \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk', 'command': 'read -P 0x55 0 64k' } }" \
+ 'return'
echo
echo === Do postcopy migration to destination ===
@@ -98,28 +107,45 @@ echo
# switch to postcopy
# Enable postcopy-ram capability both on source and destination
silent=yes
-_send_qemu_cmd $dest 'migrate_set_capability postcopy-ram on' "(qemu)"
-
qemu_error_no_exit=yes success_or_failure=yes \
- _send_qemu_cmd $dest '' "(qemu)" "Postcopy is not supported"
+ _send_qemu_cmd $dest \
+ "{ 'execute': 'migrate-set-capabilities',
+ 'arguments': { 'capabilities': [
+ { 'capability': 'postcopy-ram', 'state': true } ] } }" \
+ 'return' 'error'
if [ ${QEMU_STATUS[$dest]} -lt 0 ]; then
- _send_qemu_cmd $dest '' "(qemu)"
-
- _send_qemu_cmd $src 'quit' ""
- _send_qemu_cmd $dest 'quit' ""
+ _send_qemu_cmd $src \
+ "{ 'execute': 'quit' }" \
+ 'return'
+ _send_qemu_cmd $dest \
+ "{ 'execute': 'quit' }" \
+ 'return'
wait=1 _cleanup_qemu
_notrun 'Postcopy is not supported'
fi
-_send_qemu_cmd $src 'migrate_set_parameter max-bandwidth 4k' "(qemu)"
-_send_qemu_cmd $src 'migrate_set_capability postcopy-ram on' "(qemu)"
-_send_qemu_cmd $src "migrate -d unix:${MIG_SOCKET}" "(qemu)"
-_send_qemu_cmd $src 'migrate_start_postcopy' "(qemu)"
+_send_qemu_cmd $src \
+ "{ 'execute': 'migrate-set-parameters',
+ 'arguments': { 'max-bandwidth': 4096 } }" \
+ 'return'
+_send_qemu_cmd $src \
+ "{ 'execute': 'migrate-set-capabilities',
+ 'arguments': { 'capabilities': [
+ { 'capability': 'postcopy-ram', 'state': true } ] } }" \
+ 'return'
+_send_qemu_cmd $src \
+ "{ 'execute': 'migrate',
+ 'arguments': { 'uri': 'unix:${MIG_SOCKET}' } }" \
+ 'return'
+_send_qemu_cmd $src \
+ "{ 'execute': 'migrate-start-postcopy' }" \
+ 'return'
QEMU_COMM_TIMEOUT=1 qemu_cmd_repeat=10 silent=yes \
- _send_qemu_cmd $src "info migrate" "completed\|failed"
-silent=yes _send_qemu_cmd $src "" "(qemu)"
+ _send_qemu_cmd $src \
+ "{ 'execute': 'query-migrate' }" \
+ '"status": "completed"\|"status": "failed"'
echo
echo === Do some I/O on the destination ===
@@ -129,17 +155,25 @@ echo
# of the node name, which would create a new BlockBackend and not test whether
# the guest has the necessary permissions to access the image now
silent=
-_send_qemu_cmd $dest 'qemu-io disk "read -P 0x55 0 64k"' "(qemu)"
-_send_qemu_cmd $dest "" "ops/sec"
-_send_qemu_cmd $dest 'qemu-io disk "write -P 0x66 1M 64k"' "(qemu)"
-_send_qemu_cmd $dest "" "ops/sec"
+_send_qemu_cmd $dest \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk', 'command': 'read -P 0x55 0 64k' } }" \
+ 'return'
+_send_qemu_cmd $dest \
+ "{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk', 'command': 'write -P 0x66 1M 64k' } }" \
+ 'return'
echo
echo === Shut down and check image ===
echo
-_send_qemu_cmd $src 'quit' ""
-_send_qemu_cmd $dest 'quit' ""
+_send_qemu_cmd $src \
+ "{ 'execute': 'quit' }" \
+ 'return'
+_send_qemu_cmd $dest \
+ "{ 'execute': 'quit' }" \
+ 'return'
wait=1 _cleanup_qemu
_check_test_img
diff --git a/tests/qemu-iotests/181.out b/tests/qemu-iotests/181.out
index d58c6a9dabb0..43dc83bc9cae 100644
--- a/tests/qemu-iotests/181.out
+++ b/tests/qemu-iotests/181.out
@@ -6,32 +6,32 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
=== Write something on the source ===
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io disk "write -P 0x55 0 64k"
-wrote 65536/65536 bytes at offset 0
-64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu)
-(qemu) qemu-io disk "read -P 0x55 0 64k"
-read 65536/65536 bytes at offset 0
-64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk', 'command': 'write -P 0x55 0 64k' } }
+{"return": {"human-readable-text": "wrote 65536/65536 bytes at offset 0n64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)n"}}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk', 'command': 'read -P 0x55 0 64k' } }
+{"return": {"human-readable-text": "read 65536/65536 bytes at offset 0n64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)n"}}
=== Do postcopy migration to destination ===
=== Do some I/O on the destination ===
-(qemu) qemu-io disk "read -P 0x55 0 64k"
-read 65536/65536 bytes at offset 0
-64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu)
-(qemu) qemu-io disk "write -P 0x66 1M 64k"
-wrote 65536/65536 bytes at offset 1048576
-64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk', 'command': 'read -P 0x55 0 64k' } }
+{"return": {"human-readable-text": "read 65536/65536 bytes at offset 0n64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)n"}}
+{ 'execute': 'x-qemu-io',
+ 'arguments': { 'device': 'disk', 'command': 'write -P 0x66 1M 64k' } }
+{"return": {"human-readable-text": "wrote 65536/65536 bytes at offset 1048576n64 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)n"}}
=== Shut down and check image ===
-(qemu) quit
-(qemu)
-(qemu) quit
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
No errors were found on the image.
*** done
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 78/88] qemu-iotests/182: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (76 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 77/88] qemu-iotests/181: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 79/88] qemu-iotests/186: " Marc-André Lureau
` (11 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Replace -monitor stdio with -qmp stdio for the second QEMU instance
that tests file locking.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/182 | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/tests/qemu-iotests/182 b/tests/qemu-iotests/182
index af5eeb599c18..f0b8bd1ad2b2 100755
--- a/tests/qemu-iotests/182
+++ b/tests/qemu-iotests/182
@@ -55,10 +55,11 @@ _launch_qemu -drive file=$TEST_IMG,if=none,id=drive0,file.locking=on \
echo
echo "Starting a second QEMU using the same image should fail"
-echo 'quit' | $QEMU -nographic -monitor stdio \
+echo '{"execute":"qmp_capabilities"}
+{"execute":"quit"}' | $QEMU -nographic -qmp stdio \
-drive file=$TEST_IMG,if=none,id=drive0,file.locking=on \
-device virtio-blk,drive=drive0 2>&1 | _filter_testdir 2>&1 |
- _filter_qemu |
+ _filter_qemu | grep -v '^{' |
sed -e '/falling back to POSIX file/d' \
-e '/locks can be lost unexpectedly/d'
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 79/88] qemu-iotests/186: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (77 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 78/88] qemu-iotests/182: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 80/88] qemu-iotests/192: " Marc-André Lureau
` (10 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Replace pipe-based HMP info block with QMP query-block.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/186 | 12 +-
tests/qemu-iotests/186.out | 590 +++++++++++++++++++--------------------------
2 files changed, 256 insertions(+), 346 deletions(-)
diff --git a/tests/qemu-iotests/186 b/tests/qemu-iotests/186
index 9a4215d28e92..56952356b24f 100755
--- a/tests/qemu-iotests/186
+++ b/tests/qemu-iotests/186
@@ -41,7 +41,6 @@ _supported_fmt qcow2
_supported_proto file fuse
_require_drivers null-co
_require_devices virtio-scsi-pci
-_require_hmp
if [ "$QEMU_DEFAULT_MACHINE" != "pc" ]; then
_notrun "Requires a PC machine"
@@ -52,20 +51,21 @@ do_run_qemu()
echo Testing: "$@"
(
+ echo '{ "execute": "qmp_capabilities" }'
if ! test -t 0; then
while read cmd; do
- echo $cmd
+ echo "$cmd"
done
fi
- echo quit
- ) | $QEMU -S -display none -device virtio-scsi-pci -monitor stdio "$@" 2>&1
+ echo '{ "execute": "quit" }'
+ ) | $QEMU -S -display none -device virtio-scsi-pci -qmp stdio "$@" 2>&1
echo
}
check_info_block()
{
- echo "info block" |
- do_run_qemu "$@" | _filter_win32 | _filter_hmp | _filter_qemu |
+ echo '{ "execute": "query-block" }' |
+ do_run_qemu "$@" | _filter_win32 | _filter_qmp | _filter_qemu |
_filter_generated_node_ids | _filter_qom_path
}
diff --git a/tests/qemu-iotests/186.out b/tests/qemu-iotests/186.out
index 01530040e5f4..4f966a70219e 100644
--- a/tests/qemu-iotests/186.out
+++ b/tests/qemu-iotests/186.out
@@ -4,458 +4,368 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
=== Empty drives ===
Testing: -device floppy
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-/machine/peripheral-anon/device[1]: [not inserted]
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"device": "", "locked": false, "removable": true, "qdev": "/machine/peripheral-anon/device[1]", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -device floppy,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-qdev_id: [not inserted]
- Attached to: qdev_id
- Removable device: not locked, tray closed
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"device": "", "locked": false, "removable": true, "qdev": "qdev_id", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -device ide-cd
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-/machine/peripheral-anon/device[1]: [not inserted]
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "", "locked": false, "removable": true, "qdev": "/machine/peripheral-anon/device[1]", "tray_open": false, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -device ide-cd,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-qdev_id: [not inserted]
- Attached to: qdev_id
- Removable device: not locked, tray closed
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "", "locked": false, "removable": true, "qdev": "qdev_id", "tray_open": false, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -device scsi-cd
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-/machine/peripheral-anon/device[1]: [not inserted]
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "", "locked": false, "removable": true, "qdev": "/machine/peripheral-anon/device[1]", "tray_open": false, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -device scsi-cd,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-qdev_id: [not inserted]
- Attached to: qdev_id
- Removable device: not locked, tray closed
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "", "locked": false, "removable": true, "qdev": "qdev_id", "tray_open": false, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
=== -blockdev/-device=<node-name> ===
Testing: -blockdev driver=null-co,read-zeroes=on,node-name=null -device ide-hd,drive=null
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-null: json:{"read-zeroes": true, "driver": "null-co"} (null-co)
- Attached to: /machine/peripheral-anon/device[N]
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "", "locked": false, "removable": false, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}"}, "qdev": "/machine/peripheral-anon/device[1]", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -blockdev driver=null-co,read-zeroes=on,node-name=null -device ide-hd,drive=null,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-null: json:{"read-zeroes": true, "driver": "null-co"} (null-co)
- Attached to: qdev_id
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "", "locked": false, "removable": false, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}"}, "qdev": "qdev_id", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -blockdev driver=null-co,read-zeroes=on,node-name=null -device scsi-hd,drive=null
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-null: json:{"read-zeroes": true, "driver": "null-co"} (null-co)
- Attached to: /machine/peripheral-anon/device[N]
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "", "locked": false, "removable": false, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}"}, "qdev": "/machine/peripheral-anon/device[1]", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -blockdev driver=null-co,read-zeroes=on,node-name=null -device scsi-hd,drive=null,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-null: json:{"read-zeroes": true, "driver": "null-co"} (null-co)
- Attached to: qdev_id
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "", "locked": false, "removable": false, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}"}, "qdev": "qdev_id", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -blockdev driver=null-co,read-zeroes=on,node-name=null -device virtio-blk-pci,drive=null
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-null: json:{"read-zeroes": true, "driver": "null-co"} (null-co)
- Attached to: /machine/peripheral-anon/device[N]/virtio-backend
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "", "locked": false, "removable": false, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}"}, "qdev": "/machine/peripheral-anon/device[1]/virtio-backend", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -blockdev driver=null-co,read-zeroes=on,node-name=null -device virtio-blk-pci,drive=null,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-null: json:{"read-zeroes": true, "driver": "null-co"} (null-co)
- Attached to: /machine/peripheral/qdev_id/virtio-backend
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "", "locked": false, "removable": false, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}"}, "qdev": "/machine/peripheral/qdev_id/virtio-backend", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -blockdev driver=null-co,read-zeroes=on,node-name=null -device floppy,drive=null
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-null: json:{"read-zeroes": true, "driver": "null-co"} (null-co)
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"device": "", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}"}, "qdev": "/machine/peripheral-anon/device[1]", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -blockdev driver=null-co,read-zeroes=on,node-name=null -device floppy,drive=null,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-null: json:{"read-zeroes": true, "driver": "null-co"} (null-co)
- Attached to: qdev_id
- Removable device: not locked, tray closed
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"device": "", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}"}, "qdev": "qdev_id", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -blockdev driver=null-co,read-zeroes=on,node-name=null -device ide-cd,drive=null
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-null: json:{"read-zeroes": true, "driver": "null-co"} (null-co)
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}"}, "qdev": "/machine/peripheral-anon/device[1]", "tray_open": false, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -blockdev driver=null-co,read-zeroes=on,node-name=null -device ide-cd,drive=null,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-null: json:{"read-zeroes": true, "driver": "null-co"} (null-co)
- Attached to: qdev_id
- Removable device: not locked, tray closed
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}"}, "qdev": "qdev_id", "tray_open": false, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -blockdev driver=null-co,read-zeroes=on,node-name=null -device scsi-cd,drive=null
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-null: json:{"read-zeroes": true, "driver": "null-co"} (null-co)
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}"}, "qdev": "/machine/peripheral-anon/device[1]", "tray_open": false, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -blockdev driver=null-co,read-zeroes=on,node-name=null -device scsi-cd,drive=null,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-null: json:{"read-zeroes": true, "driver": "null-co"} (null-co)
- Attached to: qdev_id
- Removable device: not locked, tray closed
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": true, \"driver\": \"null-co\"}"}, "qdev": "qdev_id", "tray_open": false, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
=== -drive if=none/-device=<node-name> ===
Testing: -drive if=none,driver=null-co,read-zeroes=on,node-name=null -device ide-hd,drive=null,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0 (null): json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-null: json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Attached to: qdev_id
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "type": "unknown"}, {"io-status": "ok", "device": "", "locked": false, "removable": false, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "vi
rtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "qdev": "qdev_id", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=none,driver=null-co,read-zeroes=on,node-name=null -device scsi-hd,drive=null,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0 (null): json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-null: json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Attached to: qdev_id
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "type": "unknown"}, {"io-status": "ok", "device": "", "locked": false, "removable": false, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "vi
rtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "qdev": "qdev_id", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=none,driver=null-co,read-zeroes=on,node-name=null -device virtio-blk-pci,drive=null,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0 (null): json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-null: json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Attached to: /machine/peripheral/qdev_id/virtio-backend
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "type": "unknown"}, {"io-status": "ok", "device": "", "locked": false, "removable": false, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "vi
rtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "qdev": "/machine/peripheral/qdev_id/virtio-backend", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=none,driver=null-co,read-zeroes=on,node-name=null -device floppy,drive=null,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0 (null): json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-null: json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Attached to: qdev_id
- Removable device: not locked, tray closed
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "type": "unknown"}, {"device": "", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741
824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "qdev": "qdev_id", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=none,driver=null-co,read-zeroes=on,node-name=null -device ide-cd,drive=null,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0 (null): json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-null: json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Attached to: qdev_id
- Removable device: not locked, tray closed
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "type": "unknown"}, {"io-status": "ok", "device": "", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "vir
tual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "qdev": "qdev_id", "tray_open": false, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=none,driver=null-co,read-zeroes=on,node-name=null -device scsi-cd,drive=null,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0 (null): json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-null: json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Attached to: qdev_id
- Removable device: not locked, tray closed
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "type": "unknown"}, {"io-status": "ok", "device": "", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "vir
tual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "qdev": "qdev_id", "tray_open": false, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
=== -drive if=none/-device=<bb-name> (with medium) ===
Testing: -drive if=none,driver=null-co,read-zeroes=on,node-name=null -device ide-hd,drive=none0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0 (null): json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Attached to: /machine/peripheral-anon/device[N]
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "none0", "locked": false, "removable": false, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "qdev": "/machine/peripheral-anon/device[1]", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=none,driver=null-co,read-zeroes=on,node-name=null -device ide-hd,drive=none0,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0 (null): json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Attached to: qdev_id
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "none0", "locked": false, "removable": false, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "qdev": "qdev_id", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=none,driver=null-co,read-zeroes=on,node-name=null -device scsi-hd,drive=none0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0 (null): json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Attached to: /machine/peripheral-anon/device[N]
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "none0", "locked": false, "removable": false, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "qdev": "/machine/peripheral-anon/device[1]", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=none,driver=null-co,read-zeroes=on,node-name=null -device scsi-hd,drive=none0,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0 (null): json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Attached to: qdev_id
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "none0", "locked": false, "removable": false, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "qdev": "qdev_id", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=none,driver=null-co,read-zeroes=on,node-name=null -device virtio-blk-pci,drive=none0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0 (null): json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Attached to: /machine/peripheral-anon/device[N]/virtio-backend
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "none0", "locked": false, "removable": false, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "qdev": "/machine/peripheral-anon/device[1]/virtio-backend", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=none,driver=null-co,read-zeroes=on,node-name=null -device virtio-blk-pci,drive=none0,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0 (null): json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Attached to: /machine/peripheral/qdev_id/virtio-backend
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "none0", "locked": false, "removable": false, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "qdev": "/machine/peripheral/qdev_id/virtio-backend", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=none,driver=null-co,read-zeroes=on,node-name=null -device floppy,drive=none0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0 (null): json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "qdev": "/machine/peripheral-anon/device[1]", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=none,driver=null-co,read-zeroes=on,node-name=null -device floppy,drive=none0,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0 (null): json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Attached to: qdev_id
- Removable device: not locked, tray closed
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "qdev": "qdev_id", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=none,driver=null-co,read-zeroes=on,node-name=null -device ide-cd,drive=none0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0 (null): json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "qdev": "/machine/peripheral-anon/device[1]", "tray_open": false, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=none,driver=null-co,read-zeroes=on,node-name=null -device ide-cd,drive=none0,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0 (null): json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Attached to: qdev_id
- Removable device: not locked, tray closed
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "qdev": "qdev_id", "tray_open": false, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=none,driver=null-co,read-zeroes=on,node-name=null -device scsi-cd,drive=none0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0 (null): json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "qdev": "/machine/peripheral-anon/device[1]", "tray_open": false, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=none,driver=null-co,read-zeroes=on,node-name=null -device scsi-cd,drive=none0,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0 (null): json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Attached to: qdev_id
- Removable device: not locked, tray closed
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "null", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "qdev": "qdev_id", "tray_open": false, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
=== -drive if=none/-device=<bb-name> (without medium) ===
Testing: -drive if=none
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0: [not inserted]
- Removable device: not locked, tray closed
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"device": "none0", "locked": false, "removable": true, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=none -device floppy,drive=none0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0: [not inserted]
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"device": "none0", "locked": false, "removable": true, "qdev": "/machine/peripheral-anon/device[1]", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=none -device floppy,drive=none0,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0: [not inserted]
- Attached to: qdev_id
- Removable device: not locked, tray closed
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"device": "none0", "locked": false, "removable": true, "qdev": "qdev_id", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=none -device ide-cd,drive=none0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0: [not inserted]
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "none0", "locked": false, "removable": true, "qdev": "/machine/peripheral-anon/device[1]", "tray_open": false, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=none -device ide-cd,drive=none0,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0: [not inserted]
- Attached to: qdev_id
- Removable device: not locked, tray closed
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "none0", "locked": false, "removable": true, "qdev": "qdev_id", "tray_open": false, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=none -device scsi-cd,drive=none0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0: [not inserted]
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "none0", "locked": false, "removable": true, "qdev": "/machine/peripheral-anon/device[1]", "tray_open": false, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=none -device scsi-cd,drive=none0,id=qdev_id
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-none0: [not inserted]
- Attached to: qdev_id
- Removable device: not locked, tray closed
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "none0", "locked": false, "removable": true, "qdev": "qdev_id", "tray_open": false, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
=== -drive if=... ===
Testing: -drive if=floppy
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-floppy0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"device": "floppy0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[10]", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=floppy,driver=null-co,read-zeroes=on
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-floppy0 (NODE_NAME): json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"device": "floppy0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "qdev": "/machine/unattached/device[10]", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=ide,driver=null-co,read-zeroes=on
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-ide0-hd0 (NODE_NAME): json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Attached to: /machine/unattached/device[N]
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "ide0-hd0", "locked": false, "removable": false, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "qdev": "/machine/unattached/device[4]", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=ide,media=cdrom
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-ide0-cd0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "ide0-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[4]", "tray_open": false, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=ide,driver=null-co,read-zeroes=on,media=cdrom
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-ide0-cd0 (NODE_NAME): json:{"read-zeroes": "on", "driver": "null-co"} (null-co, read-only)
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "ide0-cd0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": true, "children": [], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "qdev": "/machine/unattached/device[4]", "tray_open": false, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=virtio,driver=null-co,read-zeroes=on
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-virtio0 (NODE_NAME): json:{"read-zeroes": "on", "driver": "null-co"} (null-co)
- Attached to: /machine/peripheral-anon/device[N]/virtio-backend
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"io-status": "ok", "device": "virtio0", "locked": false, "removable": false, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1073741824, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\"}"}, "qdev": "/machine/peripheral-anon/device[1]/virtio-backend", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
Testing: -drive if=pflash,driver=null-co,read-zeroes=on,size=1M
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-pflash0 (NODE_NAME): json:{"read-zeroes": "on", "driver": "null-co", "size": "1M"} (null-co)
- Attached to: /machine/system.flash0
- Cache mode: writeback
-(qemu) quit
+QMP_VERSION
+{"return": {}}
+{"return": [{"device": "pflash0", "locked": false, "removable": false, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 512, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 1048576, "filename": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\", \"size\": \"1M\"}", "format": "null-co", "actual-size": 0}, "iops_wr": 0, "ro": false, "children": [], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "null-co", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"read-zeroes\": \"on\", \"driver\": \"null-co\", \"size\": \"1M\"}"}, "qdev": "/machine/system.flash0", "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
*** done
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 80/88] qemu-iotests/192: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (78 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 79/88] qemu-iotests/186: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 81/88] qemu-iotests/201: " Marc-André Lureau
` (9 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Replace HMP nbd_server_start/nbd_server_add with QMP
nbd-server-start/nbd-server-add.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/192 | 25 ++++++++++++++++++++-----
tests/qemu-iotests/192.out | 17 +++++++++++++----
2 files changed, 33 insertions(+), 9 deletions(-)
diff --git a/tests/qemu-iotests/192 b/tests/qemu-iotests/192
index 6869bd171537..080aff368815 100755
--- a/tests/qemu-iotests/192
+++ b/tests/qemu-iotests/192
@@ -43,7 +43,6 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
_supported_fmt generic
_supported_proto file
-_require_hmp
if [ "$QEMU_DEFAULT_MACHINE" != "pc" ]; then
_notrun "Requires a PC machine"
@@ -59,7 +58,6 @@ else
DRIVE_ARG=if=ide,id=drive0,format=$IMGFMT,file=$TEST_IMG
fi
-qemu_comm_method="monitor"
_launch_qemu -drive $DRIVE_ARG -incoming defer
h=$QEMU_HANDLE
if [ "${VALGRIND_QEMU}" == "y" ]; then
@@ -68,9 +66,26 @@ else
QEMU_COMM_TIMEOUT=1
fi
-_send_qemu_cmd $h "nbd_server_start unix:$SOCK_DIR/nbd" "(qemu)"
-_send_qemu_cmd $h "nbd_server_add -w drive0" "(qemu)"
-_send_qemu_cmd $h "q" "(qemu)"
+_send_qemu_cmd $h \
+ "{ 'execute': 'qmp_capabilities' }" \
+ 'return'
+
+_send_qemu_cmd $h \
+ "{ 'execute': 'nbd-server-start',
+ 'arguments': { 'addr': { 'type': 'unix',
+ 'data': { 'path': '$SOCK_DIR/nbd' } } } }" \
+ 'return'
+
+_send_qemu_cmd $h \
+ "{ 'execute': 'nbd-server-add',
+ 'arguments': { 'device': 'drive0', 'writable': true } }" \
+ 'return'
+
+_send_qemu_cmd $h \
+ "{ 'execute': 'quit' }" \
+ 'return'
+
+wait=1 _cleanup_qemu
# success, all done
echo "*** done"
diff --git a/tests/qemu-iotests/192.out b/tests/qemu-iotests/192.out
index b9429dbe3679..88185a2e8ff4 100644
--- a/tests/qemu-iotests/192.out
+++ b/tests/qemu-iotests/192.out
@@ -1,7 +1,16 @@
QA output created by 192
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) nbd_server_start unix:SOCK_DIR/nbd
-(qemu) nbd_server_add -w drive0
-(qemu) q
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'nbd-server-start',
+ 'arguments': { 'addr': { 'type': 'unix',
+ 'data': { 'path': 'SOCK_DIR/nbd' } } } }
+{"return": {}}
+{ 'execute': 'nbd-server-add',
+ 'arguments': { 'device': 'drive0', 'writable': true } }
+{"return": {}}
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "BLOCK_EXPORT_DELETED", "data": {"id": "drive0"}}
+{"return": {}}
*** done
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 81/88] qemu-iotests/201: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (79 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 80/88] qemu-iotests/192: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 82/88] qemu-iotests/232: " Marc-André Lureau
` (8 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Replace HMP migration and savevm/loadvm commands with QMP equivalents.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/201 | 75 +++++++++++++++++++++++++++++-----------------
tests/qemu-iotests/201.out | 10 ++++---
2 files changed, 53 insertions(+), 32 deletions(-)
diff --git a/tests/qemu-iotests/201 b/tests/qemu-iotests/201
index a5c750c38a83..302ad983d83d 100755
--- a/tests/qemu-iotests/201
+++ b/tests/qemu-iotests/201
@@ -47,7 +47,6 @@ _supported_os Linux
# Internal snapshots are (currently) impossible with refcount_bits=1,
# and generally impossible with external data files
_unsupported_imgopts 'refcount_bits=1[^0-9]' data_file
-_require_hmp
size=64M
_make_test_img $size
@@ -56,76 +55,96 @@ echo
echo === Starting VMs ===
echo
-qemu_comm_method="monitor"
-
if [ "$IMGOPTSSYNTAX" = "true" ]; then
_launch_qemu \
- -drive "${TEST_IMG}",cache=${CACHEMODE},aio=$AIOMODE,id=disk
+ -drive "${TEST_IMG}",cache=${CACHEMODE},aio=$AIOMODE,id=disk,node-name=disk0
else
_launch_qemu \
- -drive file="${TEST_IMG}",cache=${CACHEMODE},aio=$AIOMODE,driver=$IMGFMT,id=disk
+ -drive file="${TEST_IMG}",cache=${CACHEMODE},aio=$AIOMODE,driver=$IMGFMT,id=disk,node-name=disk0
fi
src=$QEMU_HANDLE
+silent=yes _send_qemu_cmd $src "{ 'execute': 'qmp_capabilities' }" 'return'
if [ "$IMGOPTSSYNTAX" = "true" ]; then
_launch_qemu \
- -drive "${TEST_IMG}",cache=${CACHEMODE},aio=$AIOMODE,id=disk \
+ -drive "${TEST_IMG}",cache=${CACHEMODE},aio=$AIOMODE,id=disk,node-name=disk0 \
-incoming "unix:${MIG_SOCKET}"
else
_launch_qemu \
- -drive file="${TEST_IMG}",cache=${CACHEMODE},aio=$AIOMODE,driver=$IMGFMT,id=disk \
+ -drive file="${TEST_IMG}",cache=${CACHEMODE},aio=$AIOMODE,driver=$IMGFMT,id=disk,node-name=disk0 \
-incoming "unix:${MIG_SOCKET}"
fi
dest=$QEMU_HANDLE
+silent=yes _send_qemu_cmd $dest "{ 'execute': 'qmp_capabilities' }" 'return'
echo
echo === Set \'migrate_set_capability postcopy-ram on\' and migrate ===
echo
-silent=yes
-_send_qemu_cmd $dest 'migrate_set_capability postcopy-ram on' "(qemu)"
-
-qemu_error_no_exit=yes success_or_failure=yes \
- _send_qemu_cmd $dest '' "(qemu)" "Postcopy is not supported"
+silent=yes qemu_error_no_exit=yes success_or_failure=yes \
+ _send_qemu_cmd $dest \
+ "{ 'execute': 'migrate-set-capabilities',
+ 'arguments': { 'capabilities': [
+ { 'capability': 'postcopy-ram', 'state': true }
+ ] } }" \
+ 'return' "Postcopy is not supported"
if [ ${QEMU_STATUS[$dest]} -lt 0 ]; then
- _send_qemu_cmd $dest '' "(qemu)"
-
- _send_qemu_cmd $src 'quit' ""
- _send_qemu_cmd $dest 'quit' ""
+ _send_qemu_cmd $src "{ 'execute': 'quit' }" 'return'
+ _send_qemu_cmd $dest "{ 'execute': 'quit' }" 'return'
wait=1 _cleanup_qemu
-
_notrun 'Postcopy is not supported'
fi
-_send_qemu_cmd $src 'migrate_set_capability postcopy-ram on' "(qemu)"
-_send_qemu_cmd $src "migrate -d unix:${MIG_SOCKET}" "(qemu)"
+silent=yes _send_qemu_cmd $src \
+ "{ 'execute': 'migrate-set-capabilities',
+ 'arguments': { 'capabilities': [
+ { 'capability': 'postcopy-ram', 'state': true }
+ ] } }" \
+ 'return'
+
+silent=yes _send_qemu_cmd $src \
+ "{ 'execute': 'migrate',
+ 'arguments': { 'uri': 'unix:${MIG_SOCKET}' } }" \
+ 'return'
QEMU_COMM_TIMEOUT=1 qemu_cmd_repeat=10 silent=yes \
- _send_qemu_cmd $src "info migrate" "completed\|failed"
-silent=yes _send_qemu_cmd $src "" "(qemu)"
+ _send_qemu_cmd $src \
+ "{ 'execute': 'query-migrate' }" \
+ '"completed"\|"failed"'
echo
echo === Check if migration was successful ===
echo
QEMU_COMM_TIMEOUT=1 silent=yes \
- _send_qemu_cmd $src "info migrate" "completed"
-silent=yes _send_qemu_cmd $src "" "(qemu)"
+ _send_qemu_cmd $src \
+ "{ 'execute': 'query-migrate' }" \
+ '"completed"'
echo
echo === On destination, execute savevm and loadvm ===
echo
-silent=
-_send_qemu_cmd $dest 'savevm state1' "(qemu)"
-_send_qemu_cmd $dest 'loadvm state1' "(qemu)"
+silent=yes _run_qmp_job $dest 'save0' \
+ "{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save0',
+ 'tag': 'state1',
+ 'vmstate': 'disk0',
+ 'devices': ['disk0'] } }"
+
+silent=yes _run_qmp_job $dest 'load0' \
+ "{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': 'load0',
+ 'tag': 'state1',
+ 'vmstate': 'disk0',
+ 'devices': ['disk0'] } }"
echo
echo === Shut down and check image ===
echo
-_send_qemu_cmd $src 'quit' ""
-_send_qemu_cmd $dest 'quit' ""
+_send_qemu_cmd $src "{ 'execute': 'quit' }" 'return'
+_send_qemu_cmd $dest "{ 'execute': 'quit' }" 'return'
wait=1 _cleanup_qemu
_check_test_img
diff --git a/tests/qemu-iotests/201.out b/tests/qemu-iotests/201.out
index 9faf06f996a0..8c75a3441255 100644
--- a/tests/qemu-iotests/201.out
+++ b/tests/qemu-iotests/201.out
@@ -12,12 +12,14 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=67108864
=== On destination, execute savevm and loadvm ===
-(qemu) savevm state1
-(qemu) loadvm state1
=== Shut down and check image ===
-(qemu) quit
-(qemu) quit
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
No errors were found on the image.
*** done
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 82/88] qemu-iotests/232: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (80 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 81/88] qemu-iotests/201: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 83/88] qemu-iotests/267: " Marc-André Lureau
` (7 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Replace pipe-based HMP info block -n with QMP query-named-block-nodes.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/232 | 32 +++----
tests/qemu-iotests/232.out | 216 ++++++++++++++++++++++++++++++++++++++-------
2 files changed, 196 insertions(+), 52 deletions(-)
diff --git a/tests/qemu-iotests/232 b/tests/qemu-iotests/232
index 1ee0aae481d4..05eb4688772b 100755
--- a/tests/qemu-iotests/232
+++ b/tests/qemu-iotests/232
@@ -43,31 +43,19 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
_supported_fmt generic
_supported_proto file
_supported_os Linux
-_require_hmp
-
-do_run_qemu()
-{
- echo Testing: "$@"
- (
- if ! test -t 0; then
- while read cmd; do
- echo $cmd
- done
- fi
- echo quit
- ) | $QEMU -nographic -monitor stdio -nodefaults "$@"
- echo
-}
-
-run_qemu()
-{
- do_run_qemu "$@" 2>&1 | _filter_testdir | _filter_qemu | _filter_hmp |
- _filter_generated_node_ids | _filter_imgfmt
-}
run_qemu_info_block()
{
- echo "info block -n" | run_qemu "$@" | grep -e "(file" -e "QEMU_PROG"
+ (
+ printf '%s\n' '{"execute":"qmp_capabilities"}' \
+ '{"execute":"query-named-block-nodes"}' \
+ '{"execute":"quit"}'
+ ) | $QEMU -nographic -qmp stdio -nodefaults "$@" 2>&1 |
+ _filter_testdir | _filter_qemu | _filter_qmp |
+ _filter_generated_node_ids | _filter_imgfmt |
+ _filter_actual_image_size |
+ gsed -e 's/\("virtual-size":\s*\)[0-9]\+/\1VSIZE/g'
+ echo
}
size=128M
diff --git a/tests/qemu-iotests/232.out b/tests/qemu-iotests/232.out
index 3bd1a920afc9..3c7716914e84 100644
--- a/tests/qemu-iotests/232.out
+++ b/tests/qemu-iotests/232.out
@@ -3,57 +3,213 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
=== -drive with read-write image: read-only/auto-read-only combinations ===
-NODE_NAME: TEST_DIR/t.IMGFMT (file, read-only)
-NODE_NAME: TEST_DIR/t.IMGFMT (file, read-only)
-NODE_NAME: TEST_DIR/t.IMGFMT (file, read-only)
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
-NODE_NAME: TEST_DIR/t.IMGFMT (file)
-NODE_NAME: TEST_DIR/t.IMGFMT (file)
-NODE_NAME: TEST_DIR/t.IMGFMT (file)
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
-NODE_NAME: TEST_DIR/t.IMGFMT (file)
-NODE_NAME: TEST_DIR/t.IMGFMT (file)
-NODE_NAME: TEST_DIR/t.IMGFMT (file)
=== -drive with read-only image: read-only/auto-read-only combinations ===
-NODE_NAME: TEST_DIR/t.IMGFMT (file, read-only)
-NODE_NAME: TEST_DIR/t.IMGFMT (file, read-only)
-NODE_NAME: TEST_DIR/t.IMGFMT (file, read-only)
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
QEMU_PROG: -drive driver=file,file=TEST_DIR/t.IMGFMT,if=none,read-only=off,auto-read-only=off: Could not open 'TEST_DIR/t.IMGFMT': Permission denied
-NODE_NAME: TEST_DIR/t.IMGFMT (file)
-NODE_NAME: TEST_DIR/t.IMGFMT (file)
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
QEMU_PROG: -drive driver=file,file=TEST_DIR/t.IMGFMT,if=none,auto-read-only=off: Could not open 'TEST_DIR/t.IMGFMT': Permission denied
-NODE_NAME: TEST_DIR/t.IMGFMT (file)
-NODE_NAME: TEST_DIR/t.IMGFMT (file)
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
=== -blockdev with read-write image: read-only/auto-read-only combinations ===
-node0: TEST_DIR/t.IMGFMT (file, read-only)
-node0: TEST_DIR/t.IMGFMT (file, read-only)
-node0: TEST_DIR/t.IMGFMT (file, read-only)
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [], "node-name": "node0", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
-node0: TEST_DIR/t.IMGFMT (file)
-node0: TEST_DIR/t.IMGFMT (file)
-node0: TEST_DIR/t.IMGFMT (file)
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [], "node-name": "node0", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [], "node-name": "node0", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "node0", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "node0", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "node0", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "node0", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "node0", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "node0", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
-node0: TEST_DIR/t.IMGFMT (file)
-node0: TEST_DIR/t.IMGFMT (file)
-node0: TEST_DIR/t.IMGFMT (file)
=== -blockdev with read-only image: read-only/auto-read-only combinations ===
-node0: TEST_DIR/t.IMGFMT (file, read-only)
-node0: TEST_DIR/t.IMGFMT (file, read-only)
-node0: TEST_DIR/t.IMGFMT (file, read-only)
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [], "node-name": "node0", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [], "node-name": "node0", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [], "node-name": "node0", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
QEMU_PROG: -blockdev driver=file,filename=TEST_DIR/t.IMGFMT,node-name=node0,read-only=off,auto-read-only=off: Could not open 'TEST_DIR/t.IMGFMT': Permission denied
-node0: TEST_DIR/t.IMGFMT (file)
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "node0", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
QEMU_PROG: -blockdev driver=file,filename=TEST_DIR/t.IMGFMT,node-name=node0,read-only=off: Could not open 'TEST_DIR/t.IMGFMT': Permission denied
+
QEMU_PROG: -blockdev driver=file,filename=TEST_DIR/t.IMGFMT,node-name=node0,auto-read-only=off: Could not open 'TEST_DIR/t.IMGFMT': Permission denied
-node0: TEST_DIR/t.IMGFMT (file)
+
+QMP_VERSION
+{"return": {}}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": VSIZE, "filename": "TEST_DIR/t.IMGFMT", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "node0", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.IMGFMT"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"return": {}}
+
QEMU_PROG: -blockdev driver=file,filename=TEST_DIR/t.IMGFMT,node-name=node0: Could not open 'TEST_DIR/t.IMGFMT': Permission denied
+
*** done
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 83/88] qemu-iotests/267: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (81 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 82/88] qemu-iotests/232: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 84/88] qemu-iotests/051: " Marc-André Lureau
` (6 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Replace pipe-based HMP savevm/loadvm, nbd_server_start/add, and
info snapshots with QMP equivalents.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/267 | 139 +++++++++-----
tests/qemu-iotests/267.out | 447 ++++++++++++++++++++++++++++++++++-----------
2 files changed, 435 insertions(+), 151 deletions(-)
diff --git a/tests/qemu-iotests/267 b/tests/qemu-iotests/267
index e14aeb1f18d0..68c2f2cbebb1 100755
--- a/tests/qemu-iotests/267
+++ b/tests/qemu-iotests/267
@@ -29,6 +29,7 @@ status=1 # failure is the default!
_cleanup()
{
+ _cleanup_qemu
_cleanup_test_img
rm -f "$SOCK_DIR/nbd"
}
@@ -37,6 +38,7 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
# get standard environment, filters and checks
. ./common.rc
. ./common.filter
+. ./common.qemu
_supported_fmt qcow2
_supported_proto file
@@ -48,38 +50,53 @@ _require_drivers copy-on-read
_unsupported_imgopts 'refcount_bits=1[^0-9]' data_file
_require_devices virtio-blk
-_require_hmp
-
-do_run_qemu()
-{
- echo Testing: "$@"
- (
- if ! test -t 0; then
- while read cmd; do
- echo $cmd
- done
- fi
- echo quit
- ) | $QEMU -nographic -monitor stdio -nodefaults "$@"
- echo
-}
-
-run_qemu()
-{
- do_run_qemu "$@" 2>&1 | _filter_testdir | _filter_qemu | _filter_hmp |
- _filter_generated_node_ids | _filter_imgfmt | _filter_vmstate_size
-}
size=128M
+# snapshot-save/snapshot-load are job-based QMP commands; wait for
+# "concluded" (auto-dismiss to "null" only fires on the next command).
run_test()
{
+ local snapshot_node="$1"
+ shift
+
if [ -n "$BACKING_FILE" ]; then
_make_test_img -b "$BACKING_FILE" -F $IMGFMT $size
else
_make_test_img $size
fi
- printf "savevm snap0\ninfo snapshots\nloadvm snap0\n" | run_qemu "$@" | _filter_date
+
+ echo Testing: "$@" | _filter_testdir | _filter_imgfmt
+ _launch_qemu -nodefaults "$@"
+ _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'qmp_capabilities' }" \
+ 'return'
+
+ # snapshot-save
+ _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save0', 'tag': 'snap0',
+ 'vmstate': '$snapshot_node',
+ 'devices': [\"$snapshot_node\"] } }" \
+ 'return'
+ silent=yes _send_qemu_cmd $QEMU_HANDLE '' '"concluded"'
+
+ # snapshot-load
+ _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': 'load0', 'tag': 'snap0',
+ 'vmstate': '$snapshot_node',
+ 'devices': [\"$snapshot_node\"] } }" \
+ 'return'
+ silent=yes _send_qemu_cmd $QEMU_HANDLE '' '"concluded"'
+
+ _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'quit' }" \
+ 'return'
+ wait=1 _cleanup_qemu
+
+ $QEMU_IMG snapshot -l "$TEST_IMG" | _filter_date | _filter_vmstate_size
+ echo
}
@@ -87,31 +104,31 @@ echo
echo "=== No block devices at all ==="
echo
-run_test
+run_test nonexistent
echo
echo "=== -drive if=none ==="
echo
-run_test -drive driver=file,file="$TEST_IMG",if=none
-run_test -drive driver=$IMGFMT,file="$TEST_IMG",if=none
-run_test -drive driver=$IMGFMT,file="$TEST_IMG",if=none -device virtio-blk,drive=none0
+run_test drv0 -drive driver=file,file="$TEST_IMG",if=none,node-name=drv0
+run_test drv0 -drive driver=$IMGFMT,file="$TEST_IMG",if=none,node-name=drv0
+run_test drv0 -drive driver=$IMGFMT,file="$TEST_IMG",if=none,node-name=drv0 -device virtio-blk,drive=none0
echo
echo "=== -drive if=virtio ==="
echo
-run_test -drive driver=file,file="$TEST_IMG",if=virtio
-run_test -drive driver=$IMGFMT,file="$TEST_IMG",if=virtio
+run_test drv0 -drive driver=file,file="$TEST_IMG",if=virtio,node-name=drv0
+run_test drv0 -drive driver=$IMGFMT,file="$TEST_IMG",if=virtio,node-name=drv0
echo
echo "=== Simple -blockdev ==="
echo
-run_test -blockdev driver=file,filename="$TEST_IMG",node-name=file
-run_test -blockdev driver=file,filename="$TEST_IMG",node-name=file \
+run_test file -blockdev driver=file,filename="$TEST_IMG",node-name=file
+run_test fmt -blockdev driver=file,filename="$TEST_IMG",node-name=file \
-blockdev driver=$IMGFMT,file=file,node-name=fmt
-run_test -blockdev driver=file,filename="$TEST_IMG",node-name=file \
+run_test fmt -blockdev driver=file,filename="$TEST_IMG",node-name=file \
-blockdev driver=raw,file=file,node-name=raw \
-blockdev driver=$IMGFMT,file=raw,node-name=fmt
@@ -119,7 +136,7 @@ echo
echo "=== -blockdev with a filter on top ==="
echo
-run_test -blockdev driver=file,filename="$TEST_IMG",node-name=file \
+run_test fmt -blockdev driver=file,filename="$TEST_IMG",node-name=file \
-blockdev driver=$IMGFMT,file=file,node-name=fmt \
-blockdev driver=copy-on-read,file=fmt,node-name=filter
@@ -130,12 +147,12 @@ echo
TEST_IMG="$TEST_IMG.base" _make_test_img $size
BACKING_FILE="$TEST_IMG.base" \
-run_test -blockdev driver=file,filename="$TEST_IMG.base",node-name=backing-file \
+run_test fmt -blockdev driver=file,filename="$TEST_IMG.base",node-name=backing-file \
-blockdev driver=file,filename="$TEST_IMG",node-name=file \
-blockdev driver=$IMGFMT,file=file,backing=backing-file,node-name=fmt
BACKING_FILE="$TEST_IMG.base" \
-run_test -blockdev driver=file,filename="$TEST_IMG.base",node-name=backing-file \
+run_test fmt -blockdev driver=file,filename="$TEST_IMG.base",node-name=backing-file \
-blockdev driver=$IMGFMT,file=backing-file,node-name=backing-fmt \
-blockdev driver=file,filename="$TEST_IMG",node-name=file \
-blockdev driver=$IMGFMT,file=file,backing=backing-fmt,node-name=fmt
@@ -152,18 +169,48 @@ echo "=== -blockdev with NBD server on the backing file ==="
echo
_make_test_img -b "$TEST_IMG.base" -F $IMGFMT $size
-cat <<EOF |
-nbd_server_start unix:$SOCK_DIR/nbd
-nbd_server_add -w backing-fmt
-savevm snap0
-info snapshots
-loadvm snap0
-EOF
-run_qemu -blockdev driver=file,filename="$TEST_IMG.base",node-name=backing-file \
- -blockdev driver=$IMGFMT,file=backing-file,node-name=backing-fmt \
- -blockdev driver=file,filename="$TEST_IMG",node-name=file \
- -blockdev driver=$IMGFMT,file=file,backing=backing-fmt,node-name=fmt |
- _filter_date
+
+_launch_qemu -nodefaults \
+ -blockdev driver=file,filename="$TEST_IMG.base",node-name=backing-file \
+ -blockdev driver=$IMGFMT,file=backing-file,node-name=backing-fmt \
+ -blockdev driver=file,filename="$TEST_IMG",node-name=file \
+ -blockdev driver=$IMGFMT,file=file,backing=backing-fmt,node-name=fmt
+
+_send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'qmp_capabilities' }" \
+ 'return'
+
+_send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'nbd-server-start',
+ 'arguments': { 'addr': { 'type': 'unix',
+ 'data': { 'path': '$SOCK_DIR/nbd' } } } }" \
+ 'return'
+
+_send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'nbd-server-add',
+ 'arguments': { 'device': 'backing-fmt', 'writable': true } }" \
+ 'return'
+
+_send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save0', 'tag': 'snap0',
+ 'vmstate': 'fmt',
+ 'devices': [\"fmt\", \"backing-fmt\"] } }" \
+ 'return'
+silent=yes _send_qemu_cmd $QEMU_HANDLE '' '"concluded"'
+
+_send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': 'load0', 'tag': 'snap0',
+ 'vmstate': 'fmt',
+ 'devices': [\"fmt\", \"backing-fmt\"] } }" \
+ 'return'
+silent=yes _send_qemu_cmd $QEMU_HANDLE '' '"concluded"'
+
+_send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'quit' }" \
+ 'return'
+wait=1 _cleanup_qemu
# This time, a snapshot should be created on both files
echo Internal snapshots on overlay:
diff --git a/tests/qemu-iotests/267.out b/tests/qemu-iotests/267.out
index 37b7ebd28049..30e094f8b98f 100644
--- a/tests/qemu-iotests/267.out
+++ b/tests/qemu-iotests/267.out
@@ -4,125 +4,301 @@ QA output created by 267
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
Testing:
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) savevm snap0
-Error: no block device can store vmstate for snapshot
-(qemu) info snapshots
-Error: no block device can store vmstate for snapshot
-(qemu) loadvm snap0
-Error: no block device can store vmstate for snapshot
-(qemu) quit
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save0', 'tag': 'snap0',
+ 'vmstate': 'nonexistent',
+ 'devices': ["nonexistent"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "save0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "save0"}}
+{"return": {}}
+{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': 'load0', 'tag': 'snap0',
+ 'vmstate': 'nonexistent',
+ 'devices': ["nonexistent"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "STOP"}
+{"return": {}}
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "save0"}}
+{"return": {}}
=== -drive if=none ===
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
-Testing: -drive driver=file,file=TEST_DIR/t.IMGFMT,if=none
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) savevm snap0
-Error: Device 'none0' is writable but does not support snapshots
-(qemu) info snapshots
-Error: no block device can store vmstate for snapshot
-(qemu) loadvm snap0
-Error: Device 'none0' is writable but does not support snapshots
-(qemu) quit
+Testing: -drive driver=file,file=TEST_DIR/t.IMGFMT,if=none,node-name=drv0
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save0', 'tag': 'snap0',
+ 'vmstate': 'drv0',
+ 'devices': ["drv0"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "save0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "save0"}}
+{"return": {}}
+{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': 'load0', 'tag': 'snap0',
+ 'vmstate': 'drv0',
+ 'devices': ["drv0"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "STOP"}
+{"return": {}}
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "save0"}}
+{"return": {}}
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
-Testing: -drive driver=IMGFMT,file=TEST_DIR/t.IMGFMT,if=none
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) savevm snap0
-(qemu) info snapshots
-List of snapshots present on all disks:
+Testing: -drive driver=IMGFMT,file=TEST_DIR/t.IMGFMT,if=none,node-name=drv0
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save0', 'tag': 'snap0',
+ 'vmstate': 'drv0',
+ 'devices': ["drv0"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "save0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "save0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "STOP"}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "RESUME"}
+{"return": {}}
+{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': 'load0', 'tag': 'snap0',
+ 'vmstate': 'drv0',
+ 'devices': ["drv0"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "STOP"}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "RESUME"}
+{"return": {}}
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "save0"}}
+{"return": {}}
+Snapshot list:
ID TAG VM_SIZE DATE VM_CLOCK ICOUNT
--- snap0 SIZE yyyy-mm-dd hh:mm:ss 0000:00:00.000 --
-(qemu) loadvm snap0
-(qemu) quit
+1 snap0 SIZE yyyy-mm-dd hh:mm:ss 0000:00:00.000 --
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
-Testing: -drive driver=IMGFMT,file=TEST_DIR/t.IMGFMT,if=none -device virtio-blk,drive=none0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) savevm snap0
-(qemu) info snapshots
-List of snapshots present on all disks:
+Testing: -drive driver=IMGFMT,file=TEST_DIR/t.IMGFMT,if=none,node-name=drv0 -device virtio-blk,drive=none0
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save0', 'tag': 'snap0',
+ 'vmstate': 'drv0',
+ 'devices': ["drv0"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "save0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "save0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "STOP"}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "RESUME"}
+{"return": {}}
+{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': 'load0', 'tag': 'snap0',
+ 'vmstate': 'drv0',
+ 'devices': ["drv0"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "STOP"}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "RESUME"}
+{"return": {}}
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "save0"}}
+{"return": {}}
+Snapshot list:
ID TAG VM_SIZE DATE VM_CLOCK ICOUNT
--- snap0 SIZE yyyy-mm-dd hh:mm:ss 0000:00:00.000 --
-(qemu) loadvm snap0
-(qemu) quit
+1 snap0 SIZE yyyy-mm-dd hh:mm:ss 0000:00:00.000 --
=== -drive if=virtio ===
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
-Testing: -drive driver=file,file=TEST_DIR/t.IMGFMT,if=virtio
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) savevm snap0
-Error: Device 'virtio0' is writable but does not support snapshots
-(qemu) info snapshots
-Error: no block device can store vmstate for snapshot
-(qemu) loadvm snap0
-Error: Device 'virtio0' is writable but does not support snapshots
-(qemu) quit
+Testing: -drive driver=file,file=TEST_DIR/t.IMGFMT,if=virtio,node-name=drv0
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save0', 'tag': 'snap0',
+ 'vmstate': 'drv0',
+ 'devices': ["drv0"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "save0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "save0"}}
+{"return": {}}
+{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': 'load0', 'tag': 'snap0',
+ 'vmstate': 'drv0',
+ 'devices': ["drv0"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "STOP"}
+{"return": {}}
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "save0"}}
+{"return": {}}
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
-Testing: -drive driver=IMGFMT,file=TEST_DIR/t.IMGFMT,if=virtio
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) savevm snap0
-(qemu) info snapshots
-List of snapshots present on all disks:
+Testing: -drive driver=IMGFMT,file=TEST_DIR/t.IMGFMT,if=virtio,node-name=drv0
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save0', 'tag': 'snap0',
+ 'vmstate': 'drv0',
+ 'devices': ["drv0"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "save0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "save0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "STOP"}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "RESUME"}
+{"return": {}}
+{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': 'load0', 'tag': 'snap0',
+ 'vmstate': 'drv0',
+ 'devices': ["drv0"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "STOP"}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "RESUME"}
+{"return": {}}
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "save0"}}
+{"return": {}}
+Snapshot list:
ID TAG VM_SIZE DATE VM_CLOCK ICOUNT
--- snap0 SIZE yyyy-mm-dd hh:mm:ss 0000:00:00.000 --
-(qemu) loadvm snap0
-(qemu) quit
+1 snap0 SIZE yyyy-mm-dd hh:mm:ss 0000:00:00.000 --
=== Simple -blockdev ===
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
Testing: -blockdev driver=file,filename=TEST_DIR/t.IMGFMT,node-name=file
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) savevm snap0
-Error: Device 'file' is writable but does not support snapshots
-(qemu) info snapshots
-Error: no block device can store vmstate for snapshot
-(qemu) loadvm snap0
-Error: Device 'file' is writable but does not support snapshots
-(qemu) quit
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save0', 'tag': 'snap0',
+ 'vmstate': 'file',
+ 'devices': ["file"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "save0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "save0"}}
+{"return": {}}
+{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': 'load0', 'tag': 'snap0',
+ 'vmstate': 'file',
+ 'devices': ["file"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "STOP"}
+{"return": {}}
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "save0"}}
+{"return": {}}
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
Testing: -blockdev driver=file,filename=TEST_DIR/t.IMGFMT,node-name=file -blockdev driver=IMGFMT,file=file,node-name=fmt
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) savevm snap0
-(qemu) info snapshots
-List of snapshots present on all disks:
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save0', 'tag': 'snap0',
+ 'vmstate': 'fmt',
+ 'devices': ["fmt"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "save0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "save0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "STOP"}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "RESUME"}
+{"return": {}}
+{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': 'load0', 'tag': 'snap0',
+ 'vmstate': 'fmt',
+ 'devices': ["fmt"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "STOP"}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "RESUME"}
+{"return": {}}
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "save0"}}
+{"return": {}}
+Snapshot list:
ID TAG VM_SIZE DATE VM_CLOCK ICOUNT
--- snap0 SIZE yyyy-mm-dd hh:mm:ss 0000:00:00.000 --
-(qemu) loadvm snap0
-(qemu) quit
+1 snap0 SIZE yyyy-mm-dd hh:mm:ss 0000:00:00.000 --
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
Testing: -blockdev driver=file,filename=TEST_DIR/t.IMGFMT,node-name=file -blockdev driver=raw,file=file,node-name=raw -blockdev driver=IMGFMT,file=raw,node-name=fmt
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) savevm snap0
-(qemu) info snapshots
-List of snapshots present on all disks:
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save0', 'tag': 'snap0',
+ 'vmstate': 'fmt',
+ 'devices': ["fmt"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "save0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "save0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "STOP"}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "RESUME"}
+{"return": {}}
+{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': 'load0', 'tag': 'snap0',
+ 'vmstate': 'fmt',
+ 'devices': ["fmt"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "STOP"}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "RESUME"}
+{"return": {}}
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "save0"}}
+{"return": {}}
+Snapshot list:
ID TAG VM_SIZE DATE VM_CLOCK ICOUNT
--- snap0 SIZE yyyy-mm-dd hh:mm:ss 0000:00:00.000 --
-(qemu) loadvm snap0
-(qemu) quit
+1 snap0 SIZE yyyy-mm-dd hh:mm:ss 0000:00:00.000 --
=== -blockdev with a filter on top ===
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
Testing: -blockdev driver=file,filename=TEST_DIR/t.IMGFMT,node-name=file -blockdev driver=IMGFMT,file=file,node-name=fmt -blockdev driver=copy-on-read,file=fmt,node-name=filter
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) savevm snap0
-(qemu) info snapshots
-List of snapshots present on all disks:
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save0', 'tag': 'snap0',
+ 'vmstate': 'fmt',
+ 'devices': ["fmt"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "save0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "save0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "STOP"}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "RESUME"}
+{"return": {}}
+{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': 'load0', 'tag': 'snap0',
+ 'vmstate': 'fmt',
+ 'devices': ["fmt"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "STOP"}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "RESUME"}
+{"return": {}}
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "save0"}}
+{"return": {}}
+Snapshot list:
ID TAG VM_SIZE DATE VM_CLOCK ICOUNT
--- snap0 SIZE yyyy-mm-dd hh:mm:ss 0000:00:00.000 --
-(qemu) loadvm snap0
-(qemu) quit
+1 snap0 SIZE yyyy-mm-dd hh:mm:ss 0000:00:00.000 --
=== -blockdev with a backing file ===
@@ -130,25 +306,65 @@ ID TAG VM_SIZE DATE VM_CLOCK ICOUNT
Formatting 'TEST_DIR/t.IMGFMT.base', fmt=IMGFMT size=134217728
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728 backing_file=TEST_DIR/t.IMGFMT.base backing_fmt=IMGFMT
Testing: -blockdev driver=file,filename=TEST_DIR/t.IMGFMT.base,node-name=backing-file -blockdev driver=file,filename=TEST_DIR/t.IMGFMT,node-name=file -blockdev driver=IMGFMT,file=file,backing=backing-file,node-name=fmt
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) savevm snap0
-(qemu) info snapshots
-List of snapshots present on all disks:
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save0', 'tag': 'snap0',
+ 'vmstate': 'fmt',
+ 'devices': ["fmt"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "save0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "save0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "STOP"}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "RESUME"}
+{"return": {}}
+{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': 'load0', 'tag': 'snap0',
+ 'vmstate': 'fmt',
+ 'devices': ["fmt"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "STOP"}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "RESUME"}
+{"return": {}}
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "save0"}}
+{"return": {}}
+Snapshot list:
ID TAG VM_SIZE DATE VM_CLOCK ICOUNT
--- snap0 SIZE yyyy-mm-dd hh:mm:ss 0000:00:00.000 --
-(qemu) loadvm snap0
-(qemu) quit
+1 snap0 SIZE yyyy-mm-dd hh:mm:ss 0000:00:00.000 --
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728 backing_file=TEST_DIR/t.IMGFMT.base backing_fmt=IMGFMT
Testing: -blockdev driver=file,filename=TEST_DIR/t.IMGFMT.base,node-name=backing-file -blockdev driver=IMGFMT,file=backing-file,node-name=backing-fmt -blockdev driver=file,filename=TEST_DIR/t.IMGFMT,node-name=file -blockdev driver=IMGFMT,file=file,backing=backing-fmt,node-name=fmt
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) savevm snap0
-(qemu) info snapshots
-List of snapshots present on all disks:
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save0', 'tag': 'snap0',
+ 'vmstate': 'fmt',
+ 'devices': ["fmt"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "save0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "save0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "STOP"}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "RESUME"}
+{"return": {}}
+{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': 'load0', 'tag': 'snap0',
+ 'vmstate': 'fmt',
+ 'devices': ["fmt"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "STOP"}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "RESUME"}
+{"return": {}}
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "save0"}}
+{"return": {}}
+Snapshot list:
ID TAG VM_SIZE DATE VM_CLOCK ICOUNT
--- snap0 SIZE yyyy-mm-dd hh:mm:ss 0000:00:00.000 --
-(qemu) loadvm snap0
-(qemu) quit
+1 snap0 SIZE yyyy-mm-dd hh:mm:ss 0000:00:00.000 --
Internal snapshots on overlay:
Snapshot list:
@@ -159,18 +375,39 @@ Internal snapshots on backing file:
=== -blockdev with NBD server on the backing file ===
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728 backing_file=TEST_DIR/t.IMGFMT.base backing_fmt=IMGFMT
-Testing: -blockdev driver=file,filename=TEST_DIR/t.IMGFMT.base,node-name=backing-file -blockdev driver=IMGFMT,file=backing-file,node-name=backing-fmt -blockdev driver=file,filename=TEST_DIR/t.IMGFMT,node-name=file -blockdev driver=IMGFMT,file=file,backing=backing-fmt,node-name=fmt
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) nbd_server_start unix:SOCK_DIR/nbd
-(qemu) nbd_server_add -w backing-fmt
-(qemu) savevm snap0
-(qemu) info snapshots
-List of snapshots present on all disks:
-ID TAG VM_SIZE DATE VM_CLOCK ICOUNT
--- snap0 SIZE yyyy-mm-dd hh:mm:ss 0000:00:00.000 --
-(qemu) loadvm snap0
-(qemu) quit
-
+{ 'execute': 'qmp_capabilities' }
+{"return": {}}
+{ 'execute': 'nbd-server-start',
+ 'arguments': { 'addr': { 'type': 'unix',
+ 'data': { 'path': 'SOCK_DIR/nbd' } } } }
+{"return": {}}
+{ 'execute': 'nbd-server-add',
+ 'arguments': { 'device': 'backing-fmt', 'writable': true } }
+{"return": {}}
+{ 'execute': 'snapshot-save',
+ 'arguments': { 'job-id': 'save0', 'tag': 'snap0',
+ 'vmstate': 'fmt',
+ 'devices': ["fmt", "backing-fmt"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "save0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "save0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "STOP"}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "RESUME"}
+{"return": {}}
+{ 'execute': 'snapshot-load',
+ 'arguments': { 'job-id': 'load0', 'tag': 'snap0',
+ 'vmstate': 'fmt',
+ 'devices': ["fmt", "backing-fmt"] } }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "created", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "running", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "STOP"}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "RESUME"}
+{"return": {}}
+{ 'execute': 'quit' }
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "BLOCK_EXPORT_DELETED", "data": {"id": "backing-fmt"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "load0"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "JOB_STATUS_CHANGE", "data": {"status": "null", "id": "save0"}}
+{"return": {}}
Internal snapshots on overlay:
Snapshot list:
ID TAG VM_SIZE DATE VM_CLOCK ICOUNT
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 84/88] qemu-iotests/051: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (82 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 83/88] qemu-iotests/267: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 85/88] qdev: add x-query-qtree QMP command Marc-André Lureau
` (5 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Replace pipe-based HMP monitor with QMP. Convert info block, qemu-io,
and commit commands to their QMP equivalents. Use existing filter
helpers (_filter_qmp, _filter_qmp_empty_return, _filter_actual_image_size)
instead of custom Python filters.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/051 | 75 ++++++----
tests/qemu-iotests/051.out | 241 ++++++++++++--------------------
tests/qemu-iotests/051.pc.out | 311 ++++++++++++++++--------------------------
3 files changed, 258 insertions(+), 369 deletions(-)
diff --git a/tests/qemu-iotests/051 b/tests/qemu-iotests/051
index a722c0c1bc8f..fd9074f978bc 100755
--- a/tests/qemu-iotests/051
+++ b/tests/qemu-iotests/051
@@ -29,6 +29,7 @@ status=1 # failure is the default!
_cleanup()
{
+ _cleanup_qemu
_cleanup_test_img
}
trap "_cleanup; exit \$status" 0 1 2 3 15
@@ -36,6 +37,7 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
# get standard environment, filters and checks
. ./common.rc
. ./common.filter
+. ./common.qemu
_supported_fmt qcow2
_supported_proto file
@@ -45,7 +47,6 @@ _supported_proto file
_unsupported_imgopts 'refcount_bits=\([^1]\|.\([^6]\|$\)\)' data_file \
compression_type
_require_drivers nbd
-_require_hmp
if [ "$QEMU_DEFAULT_MACHINE" = "pc" ]; then
_require_devices lsi53c895a
@@ -55,20 +56,22 @@ do_run_qemu()
{
echo Testing: "$@"
(
+ echo '{"execute":"qmp_capabilities"}'
if ! test -t 0; then
while read cmd; do
- echo $cmd
+ echo "$cmd"
done
fi
- echo quit
- ) | $QEMU -nographic -monitor stdio -serial none "$@"
+ echo '{"execute":"quit"}'
+ ) | $QEMU -nographic -qmp stdio -serial none "$@"
echo
}
run_qemu()
{
- do_run_qemu "$@" 2>&1 | _filter_testdir | _filter_qemu |
- _filter_generated_node_ids | _filter_hmp
+ do_run_qemu "$@" 2>&1 | _filter_testdir | _filter_qemu \
+ | _filter_generated_node_ids | _filter_qmp | _filter_qmp_empty_return \
+ | _filter_actual_image_size
}
size=128M
@@ -131,8 +134,8 @@ echo
echo === Overriding backing file ===
echo
-echo "info block" | run_qemu -drive file="$TEST_IMG",driver=qcow2,backing.file.filename="$TEST_IMG.orig",if=none,id=$device_id -nodefaults\
- | _filter_generated_node_ids
+echo "{ 'execute': 'query-block' }" | \
+ run_qemu -drive file="$TEST_IMG",driver=qcow2,backing.file.filename="$TEST_IMG.orig",if=none,id=$device_id -nodefaults
# Drivers that don't support backing files
run_qemu -drive file="$TEST_IMG",driver=raw,backing.file.filename="$TEST_IMG.orig"
@@ -257,7 +260,7 @@ run_qemu -drive driver=null-co,cache=invalid_value
# Test 142 checks the direct=on cases
for cache in writeback writethrough unsafe invalid_value; do
- printf "info block %s\n" '' file backing backing-file | \
+ printf '%s\n' "{ 'execute': 'query-block' }" "{ 'execute': 'query-named-block-nodes' }" | \
run_qemu -drive file="$TEST_IMG",cache=$cache,backing.file.filename="$TEST_IMG.base",backing.cache.no-flush=on,backing.node-name=backing,backing.file.node-name=backing-file,file.node-name=file,if=none,id=$device_id -nodefaults
done
@@ -343,31 +346,56 @@ echo
$QEMU_IO -c "write -P 0x11 0 4k" "$TEST_IMG" | _filter_qemu_io
+qmp_write_22="{ 'execute': 'x-qemu-io', 'arguments': { 'device': '$device_id', 'command': 'write -P 0x22 0 4k' } }"
-echo "qemu-io $device_id \"write -P 0x22 0 4k\"" | run_qemu -drive file="$TEST_IMG",if=none,id=$device_id -snapshot | _filter_qemu_io
-echo "qemu-io $device_id \"write -P 0x22 0 4k\"" | run_qemu -drive file="$TEST_IMG",snapshot=on,if=none,id=$device_id | _filter_qemu_io
-echo "qemu-io $device_id \"write -P 0x22 0 4k\"" | run_qemu -drive file.filename="$TEST_IMG",driver=qcow2,snapshot=on,if=none,id=$device_id\
+echo "$qmp_write_22" | run_qemu -drive file="$TEST_IMG",if=none,id=$device_id -snapshot | _filter_qemu_io
+echo "$qmp_write_22" | run_qemu -drive file="$TEST_IMG",snapshot=on,if=none,id=$device_id | _filter_qemu_io
+echo "$qmp_write_22" | run_qemu -drive file.filename="$TEST_IMG",driver=qcow2,snapshot=on,if=none,id=$device_id\
| _filter_qemu_io
-echo "qemu-io $device_id \"write -P 0x22 0 4k\"" | run_qemu -drive file.filename="$TEST_IMG",driver=qcow2,if=none,id=$device_id -snapshot\
+echo "$qmp_write_22" | run_qemu -drive file.filename="$TEST_IMG",driver=qcow2,if=none,id=$device_id -snapshot\
| _filter_qemu_io
-echo "qemu-io $device_id \"write -P 0x22 0 4k\"" | run_qemu -drive file="file:$TEST_IMG",if=none,id=$device_id -snapshot | _filter_qemu_io
-echo "qemu-io $device_id \"write -P 0x22 0 4k\"" | run_qemu -drive file="file:$TEST_IMG",snapshot=on,if=none,id=$device_id | _filter_qemu_io
+echo "$qmp_write_22" | run_qemu -drive file="file:$TEST_IMG",if=none,id=$device_id -snapshot | _filter_qemu_io
+echo "$qmp_write_22" | run_qemu -drive file="file:$TEST_IMG",snapshot=on,if=none,id=$device_id | _filter_qemu_io
# Opening a read-only file r/w with snapshot=on
chmod u-w "$TEST_IMG"
-echo "qemu-io $device_id \"write -P 0x22 0 4k\"" | run_qemu -drive file="$TEST_IMG",if=none,id=$device_id -snapshot | _filter_qemu_io
-echo "qemu-io $device_id \"write -P 0x22 0 4k\"" | run_qemu -drive file="$TEST_IMG",snapshot=on,if=none,id=$device_id | _filter_qemu_io
+echo "$qmp_write_22" | run_qemu -drive file="$TEST_IMG",if=none,id=$device_id -snapshot | _filter_qemu_io
+echo "$qmp_write_22" | run_qemu -drive file="$TEST_IMG",snapshot=on,if=none,id=$device_id | _filter_qemu_io
chmod u+w "$TEST_IMG"
$QEMU_IO -c "read -P 0x11 0 4k" "$TEST_IMG" | _filter_qemu_io
-echo "qemu-io $device_id \"write -P 0x22 0 4k\"" | run_qemu -drive file="$TEST_IMG",snapshot=off,if=none,id=$device_id | _filter_qemu_io
+echo "$qmp_write_22" | run_qemu -drive file="$TEST_IMG",snapshot=off,if=none,id=$device_id | _filter_qemu_io
$QEMU_IO -c "read -P 0x22 0 4k" "$TEST_IMG" | _filter_qemu_io
-printf %b "qemu-io $device_id \"write -P 0x33 0 4k\"\ncommit $device_id\n" |
- run_qemu -drive file="$TEST_IMG",snapshot=on,if=none,id=$device_id |
- _filter_qemu_io
+echo "Testing: -drive file=$TEST_IMG,snapshot=on,if=none,id=$device_id" |
+ _filter_testdir
+_launch_qemu -drive file="$TEST_IMG",snapshot=on,if=none,id=$device_id
+silent=yes _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'qmp_capabilities' }" \
+ 'return'
+_send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'x-qemu-io', 'arguments': { 'device': '$device_id', 'command': 'write -P 0x33 0 4k' } }" \
+ 'return'
+qmp_commit="{ 'execute': 'block-commit', 'arguments': { 'device': '$device_id', 'job-id': 'job0' } }"
+echo "$qmp_commit"
+silent=yes _send_qemu_cmd $QEMU_HANDLE \
+ "$qmp_commit" \
+ 'return'
+silent=yes _timed_wait_for $QEMU_HANDLE '"ready"'
+qmp_complete="{ 'execute': 'block-job-complete', 'arguments': { 'device': 'job0' } }"
+echo "$qmp_complete"
+silent=yes _send_qemu_cmd $QEMU_HANDLE \
+ "$qmp_complete" \
+ 'return'
+silent=yes _timed_wait_for $QEMU_HANDLE '"null"'
+echo "block job completed"
+silent=yes _send_qemu_cmd $QEMU_HANDLE \
+ "{ 'execute': 'quit' }" \
+ 'return'
+wait=1 _cleanup_qemu
+echo
$QEMU_IO -c "read -P 0x33 0 4k" "$TEST_IMG" | _filter_qemu_io
@@ -380,10 +408,9 @@ TMPDIR=/nonexistent run_qemu -drive driver=null-co,snapshot=on |
sed -e "s#'[^']*/vl\.[A-Za-z0-9]\{6\}'#SNAPSHOT_PATH#g"
# Using snapshot=on together with read-only=on
-echo "info block" |
+echo "{ 'execute': 'query-block' }" |
run_qemu -drive file="$TEST_IMG",snapshot=on,read-only=on,if=none,id=$device_id |
- _filter_qemu_io |
- sed -e 's#"[^"]*/vl\.[A-Za-z0-9]\{6\}"#SNAPSHOT_PATH#g'
+ sed -e 's|/[^"[:space:]]*/vl\.[A-Za-z0-9]\{6\}|SNAPSHOT_PATH|g'
# success, all done
diff --git a/tests/qemu-iotests/051.out b/tests/qemu-iotests/051.out
index d46215640506..30972e390e75 100644
--- a/tests/qemu-iotests/051.out
+++ b/tests/qemu-iotests/051.out
@@ -50,15 +50,15 @@ QEMU_PROG: -drive file=TEST_DIR/t.qcow2,driver=qcow2,format=qcow2: Cannot specif
=== Node names ===
Testing: -drive file=TEST_DIR/t.qcow2,node-name=x123456789012345678901234567890
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,node-name=x1234567890123456789012345678901
QEMU_PROG: -drive file=TEST_DIR/t.qcow2,node-name=x1234567890123456789012345678901: Node name too long
Testing: -drive file=TEST_DIR/t.qcow2,node-name=All-Types.of_all0wed_chars
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,node-name=123foo
QEMU_PROG: -drive file=TEST_DIR/t.qcow2,node-name=123foo: Invalid node-name: '123foo'
@@ -73,20 +73,16 @@ QEMU_PROG: -drive file=TEST_DIR/t.qcow2,node-name=foo#12: Invalid node-name: 'fo
=== Device without drive ===
Testing: -device virtio-scsi -device scsi-hd
-QEMU X.Y.Z monitor - type 'help' for more information
+QMP_VERSION
QEMU_PROG: -device scsi-hd: drive property not set
=== Overriding backing file ===
Testing: -drive file=TEST_DIR/t.qcow2,driver=qcow2,backing.file.filename=TEST_DIR/t.qcow2.orig,if=none,id=drive0 -nodefaults
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-drive0 (NODE_NAME): json:{"backing": {"driver": "qcow2", "file": {"driver": "file", "filename": "TEST_DIR/t.qcow2.orig"}}, "driver": "qcow2", "file": {"driver": "file", "filename": "TEST_DIR/t.qcow2"}} (qcow2)
- Removable device: not locked, tray closed
- Cache mode: writeback
- Backing file: TEST_DIR/t.qcow2.orig (chain depth: 1)
-(qemu) quit
+QMP_VERSION
+{"return": [{"device": "drive0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"backing-image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2.orig", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "backing-filename-format": "qcow2", "virtual-size": 134217728, "filename": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DI
R/t.qcow2.orig\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "full-backing-filename": "TEST_DIR/t.qcow2.base", "backing-filename": "TEST_DIR/t.qcow2.base", "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "backing"}, {"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 1, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "backing_file": "TEST_DIR/t.qcow2.orig", "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.orig\"}}
, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}"}, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,driver=raw,backing.file.filename=TEST_DIR/t.qcow2.orig
QEMU_PROG: -drive file=TEST_DIR/t.qcow2,driver=raw,backing.file.filename=TEST_DIR/t.qcow2.orig: Driver doesn't support backing files
@@ -102,12 +98,12 @@ QEMU_PROG: -drive file=TEST_DIR/t.qcow2,file.backing.driver=qcow2,file.backing.f
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
Testing: -drive file=TEST_DIR/t.qcow2,format=qcow2,lazy-refcounts=on
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,format=qcow2,lazy-refcounts=off
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,format=qcow2,lazy-refcounts=
QEMU_PROG: -drive file=TEST_DIR/t.qcow2,format=qcow2,lazy-refcounts=: Parameter 'lazy-refcounts' expects 'on' or 'off'
@@ -126,14 +122,14 @@ Testing: -drive file=TEST_DIR/t.qcow2,format=qcow2,lazy-refcounts=on
QEMU_PROG: -drive file=TEST_DIR/t.qcow2,format=qcow2,lazy-refcounts=on: Lazy refcounts require a qcow2 image with at least qemu 1.1 compatibility level
Testing: -drive file=TEST_DIR/t.qcow2,format=qcow2,lazy-refcounts=off
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
=== No medium ===
Testing: -drive if=virtio
-QEMU X.Y.Z monitor - type 'help' for more information
+QMP_VERSION
QEMU_PROG: -drive if=virtio: Device needs media, but drive is empty
@@ -143,94 +139,52 @@ QEMU_PROG: -drive if=virtio: Device needs media, but drive is empty
=== Read-only ===
Testing: -drive file=TEST_DIR/t.qcow2,if=virtio,readonly=on
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
=== Cache modes ===
Testing: -drive driver=null-co,read-zeroes=on,cache=none
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive driver=null-co,read-zeroes=on,cache=directsync
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive driver=null-co,read-zeroes=on,cache=writeback
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive driver=null-co,read-zeroes=on,cache=writethrough
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive driver=null-co,read-zeroes=on,cache=unsafe
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive driver=null-co,cache=invalid_value
QEMU_PROG: -drive driver=null-co,cache=invalid_value: invalid cache option
Testing: -drive file=TEST_DIR/t.qcow2,cache=writeback,backing.file.filename=TEST_DIR/t.qcow2.base,backing.cache.no-flush=on,backing.node-name=backing,backing.file.node-name=backing-file,file.node-name=file,if=none,id=drive0 -nodefaults
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-drive0 (NODE_NAME): json:{"backing": {"driver": "qcow2", "file": {"driver": "file", "filename": "TEST_DIR/t.qcow2.base"}}, "driver": "qcow2", "file": {"driver": "file", "filename": "TEST_DIR/t.qcow2"}} (qcow2)
- Removable device: not locked, tray closed
- Cache mode: writeback
- Backing file: TEST_DIR/t.qcow2.base (chain depth: 1)
-(qemu) info block file
-
-file: TEST_DIR/t.qcow2 (file)
- Cache mode: writeback
-(qemu) info block backing
-backing: TEST_DIR/t.qcow2.base (qcow2, read-only)
- Cache mode: writeback, ignore flushes
-(qemu) info block backing-file
-
-backing-file: TEST_DIR/t.qcow2.base (file, read-only)
- Cache mode: writeback, ignore flushes
-(qemu) quit
+QMP_VERSION
+{"return": [{"device": "drive0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"backing-image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2.base", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qc
ow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "0.10", "compression-type": "zlib", "refcount-bits": 16}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "backing", "child": "backing"}, {"node-name": "file", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 1, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "backing_file": "TEST_DIR/t.qcow2.base", "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}"}, "type": "unknown"}]}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2.base", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [{"node-name": "backing-file", "child": "file"}], "node-name": "backing", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": true, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2.base"}, {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-a
lignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 197120, "filename": "TEST_DIR/t.qcow2.base", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [], "node-name": "backing-file", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": true, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2.base"}, {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"backing-image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2.base", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compr
ession-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "0.10", "compression-type": "zlib", "refcount-bits": 16}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "backing", "child": "backing"}, {"node-name": "file", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 1, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "backi
ng_file": "TEST_DIR/t.qcow2.base", "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}"}, {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 197120, "filename": "TEST_DIR/t.qcow2", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "file", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,cache=writethrough,backing.file.filename=TEST_DIR/t.qcow2.base,backing.cache.no-flush=on,backing.node-name=backing,backing.file.node-name=backing-file,file.node-name=file,if=none,id=drive0 -nodefaults
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-drive0 (NODE_NAME): json:{"backing": {"driver": "qcow2", "file": {"driver": "file", "filename": "TEST_DIR/t.qcow2.base"}}, "driver": "qcow2", "file": {"driver": "file", "filename": "TEST_DIR/t.qcow2"}} (qcow2)
- Removable device: not locked, tray closed
- Cache mode: writethrough
- Backing file: TEST_DIR/t.qcow2.base (chain depth: 1)
-(qemu) info block file
-
-file: TEST_DIR/t.qcow2 (file)
- Cache mode: writeback
-(qemu) info block backing
-backing: TEST_DIR/t.qcow2.base (qcow2, read-only)
- Cache mode: writeback, ignore flushes
-(qemu) info block backing-file
-
-backing-file: TEST_DIR/t.qcow2.base (file, read-only)
- Cache mode: writeback, ignore flushes
-(qemu) quit
+QMP_VERSION
+{"return": [{"device": "drive0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"backing-image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2.base", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qc
ow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "0.10", "compression-type": "zlib", "refcount-bits": 16}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "backing", "child": "backing"}, {"node-name": "file", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 1, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "backing_file": "TEST_DIR/t.qcow2.base", "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": false}, "file": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}"}, "type": "unknown"}]}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2.base", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [{"node-name": "backing-file", "child": "file"}], "node-name": "backing", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": true, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2.base"}, {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-a
lignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 197120, "filename": "TEST_DIR/t.qcow2.base", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [], "node-name": "backing-file", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": true, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2.base"}, {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"backing-image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2.base", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compr
ession-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "0.10", "compression-type": "zlib", "refcount-bits": 16}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "backing", "child": "backing"}, {"node-name": "file", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 1, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "backi
ng_file": "TEST_DIR/t.qcow2.base", "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}"}, {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 197120, "filename": "TEST_DIR/t.qcow2", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "file", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,cache=unsafe,backing.file.filename=TEST_DIR/t.qcow2.base,backing.cache.no-flush=on,backing.node-name=backing,backing.file.node-name=backing-file,file.node-name=file,if=none,id=drive0 -nodefaults
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-drive0 (NODE_NAME): json:{"backing": {"driver": "qcow2", "file": {"driver": "file", "filename": "TEST_DIR/t.qcow2.base"}}, "driver": "qcow2", "file": {"driver": "file", "filename": "TEST_DIR/t.qcow2"}} (qcow2)
- Removable device: not locked, tray closed
- Cache mode: writeback, ignore flushes
- Backing file: TEST_DIR/t.qcow2.base (chain depth: 1)
-(qemu) info block file
-
-file: TEST_DIR/t.qcow2 (file)
- Cache mode: writeback, ignore flushes
-(qemu) info block backing
-backing: TEST_DIR/t.qcow2.base (qcow2, read-only)
- Cache mode: writeback, ignore flushes
-(qemu) info block backing-file
-
-backing-file: TEST_DIR/t.qcow2.base (file, read-only)
- Cache mode: writeback, ignore flushes
-(qemu) quit
+QMP_VERSION
+{"return": [{"device": "drive0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"backing-image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2.base", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qc
ow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "0.10", "compression-type": "zlib", "refcount-bits": 16}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "backing", "child": "backing"}, {"node-name": "file", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 1, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "backing_file": "TEST_DIR/t.qcow2.base", "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": true, "direct": false, "writeback": true}, "file": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}"}, "type": "unknown"}]}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2.base", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [{"node-name": "backing-file", "child": "file"}], "node-name": "backing", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": true, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2.base"}, {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-a
lignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 197120, "filename": "TEST_DIR/t.qcow2.base", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [], "node-name": "backing-file", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": true, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2.base"}, {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"backing-image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2.base", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compr
ession-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "0.10", "compression-type": "zlib", "refcount-bits": 16}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "backing", "child": "backing"}, {"node-name": "file", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 1, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "backi
ng_file": "TEST_DIR/t.qcow2.base", "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": true, "direct": false, "writeback": true}, "file": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}"}, {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 197120, "filename": "TEST_DIR/t.qcow2", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "file", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": true, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,cache=invalid_value,backing.file.filename=TEST_DIR/t.qcow2.base,backing.cache.no-flush=on,backing.node-name=backing,backing.file.node-name=backing-file,file.node-name=file,if=none,id=drive0 -nodefaults
QEMU_PROG: -drive file=TEST_DIR/t.qcow2,cache=invalid_value,backing.file.filename=TEST_DIR/t.qcow2.base,backing.cache.no-flush=on,backing.node-name=backing,backing.file.node-name=backing-file,file.node-name=file,if=none,id=drive0: invalid cache option
@@ -239,8 +193,8 @@ QEMU_PROG: -drive file=TEST_DIR/t.qcow2,cache=invalid_value,backing.file.filenam
=== Specifying the protocol layer ===
Testing: -drive file=TEST_DIR/t.qcow2,file.driver=file
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
=== Leaving out required options ===
@@ -336,16 +290,16 @@ Testing: -drive file=TEST_DIR/t.qcow2,throttling.bps-total=-5
QEMU_PROG: -drive file=TEST_DIR/t.qcow2,throttling.bps-total=-5: bps/iops/max values must be within [0, 1000000000000000]
Testing: -drive file=TEST_DIR/t.qcow2,bps=0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,bps=1
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,bps=1000000000000000
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,bps=1000000000000001
QEMU_PROG: -drive file=TEST_DIR/t.qcow2,bps=1000000000000001: bps/iops/max values must be within [0, 1000000000000000]
@@ -366,12 +320,12 @@ Testing: -drive file.filename=foo:bar
QEMU_PROG: -drive file.filename=foo:bar: Could not open 'foo:bar': No such file or directory
Testing: -hda file:TEST_DIR/t.qcow2
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=file:TEST_DIR/t.qcow2
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file.filename=file:TEST_DIR/t.qcow2
QEMU_PROG: -drive file.filename=file:TEST_DIR/t.qcow2: Could not open 'file:TEST_DIR/t.qcow2': No such file or directory
@@ -382,79 +336,60 @@ QEMU_PROG: -drive file.filename=file:TEST_DIR/t.qcow2: Could not open 'file:TEST
wrote 4096/4096 bytes at offset 0
4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
Testing: -drive file=TEST_DIR/t.qcow2,if=none,id=drive0 -snapshot
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io drive0 "write -P 0x22 0 4k"
-wrote 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,snapshot=on,if=none,id=drive0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io drive0 "write -P 0x22 0 4k"
-wrote 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file.filename=TEST_DIR/t.qcow2,driver=qcow2,snapshot=on,if=none,id=drive0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io drive0 "write -P 0x22 0 4k"
-wrote 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file.filename=TEST_DIR/t.qcow2,driver=qcow2,if=none,id=drive0 -snapshot
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io drive0 "write -P 0x22 0 4k"
-wrote 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=file:TEST_DIR/t.qcow2,if=none,id=drive0 -snapshot
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io drive0 "write -P 0x22 0 4k"
-wrote 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=file:TEST_DIR/t.qcow2,snapshot=on,if=none,id=drive0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io drive0 "write -P 0x22 0 4k"
-wrote 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,if=none,id=drive0 -snapshot
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io drive0 "write -P 0x22 0 4k"
-wrote 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,snapshot=on,if=none,id=drive0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io drive0 "write -P 0x22 0 4k"
-wrote 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
read 4096/4096 bytes at offset 0
4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
Testing: -drive file=TEST_DIR/t.qcow2,snapshot=off,if=none,id=drive0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io drive0 "write -P 0x22 0 4k"
-wrote 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
read 4096/4096 bytes at offset 0
4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
Testing: -drive file=TEST_DIR/t.qcow2,snapshot=on,if=none,id=drive0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io drive0 "write -P 0x33 0 4k"
-wrote 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) commit drive0
-(qemu) quit
+{ 'execute': 'x-qemu-io', 'arguments': { 'device': 'drive0', 'command': 'write -P 0x33 0 4k' } }
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{ 'execute': 'block-commit', 'arguments': { 'device': 'drive0', 'job-id': 'job0' } }
+{ 'execute': 'block-job-complete', 'arguments': { 'device': 'job0' } }
+block job completed
read 4096/4096 bytes at offset 0
4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
@@ -462,12 +397,8 @@ Testing: -drive driver=null-co,snapshot=on
QEMU_PROG: -drive driver=null-co,snapshot=on: Could not open temporary file SNAPSHOT_PATH: No such file or directory
Testing: -drive file=TEST_DIR/t.qcow2,snapshot=on,read-only=on,if=none,id=drive0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-drive0 (NODE_NAME): json:{"backing": {"driver": "qcow2", "file": {"driver": "file", "filename": "TEST_DIR/t.qcow2"}}, "driver": "qcow2", "file": {"driver": "file", "filename": SNAPSHOT_PATH}} (qcow2, read-only)
- Removable device: not locked, tray closed
- Cache mode: writeback, ignore flushes
- Backing file: TEST_DIR/t.qcow2 (chain depth: 1)
-(qemu) quit
+QMP_VERSION
+{"return": [{"device": "drive0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"backing-image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "0.10", "compression-type": "zlib", "refcount-bits": 16}}, "dirty-flag": false}, "limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"SNAPSHOT_PATH\"}}"
, "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [{"node-name": "NODE_NAME", "child": "backing"}, {"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 1, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "backing_file": "TEST_DIR/t.qcow2", "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": true, "direct": false, "writeback": true}, "file": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"SNAPSHOT_PATH\"}}"}, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
*** done
diff --git a/tests/qemu-iotests/051.pc.out b/tests/qemu-iotests/051.pc.out
index f19b532eb9b6..7348aad4d464 100644
--- a/tests/qemu-iotests/051.pc.out
+++ b/tests/qemu-iotests/051.pc.out
@@ -50,15 +50,15 @@ QEMU_PROG: -drive file=TEST_DIR/t.qcow2,driver=qcow2,format=qcow2: Cannot specif
=== Node names ===
Testing: -drive file=TEST_DIR/t.qcow2,node-name=x123456789012345678901234567890
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,node-name=x1234567890123456789012345678901
QEMU_PROG: -drive file=TEST_DIR/t.qcow2,node-name=x1234567890123456789012345678901: Node name too long
Testing: -drive file=TEST_DIR/t.qcow2,node-name=All-Types.of_all0wed_chars
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,node-name=123foo
QEMU_PROG: -drive file=TEST_DIR/t.qcow2,node-name=123foo: Invalid node-name: '123foo'
@@ -73,20 +73,16 @@ QEMU_PROG: -drive file=TEST_DIR/t.qcow2,node-name=foo#12: Invalid node-name: 'fo
=== Device without drive ===
Testing: -device virtio-scsi -device scsi-hd
-QEMU X.Y.Z monitor - type 'help' for more information
+QMP_VERSION
QEMU_PROG: -device scsi-hd: drive property not set
=== Overriding backing file ===
Testing: -drive file=TEST_DIR/t.qcow2,driver=qcow2,backing.file.filename=TEST_DIR/t.qcow2.orig,if=none,id=drive0 -nodefaults
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-drive0 (NODE_NAME): json:{"backing": {"driver": "qcow2", "file": {"driver": "file", "filename": "TEST_DIR/t.qcow2.orig"}}, "driver": "qcow2", "file": {"driver": "file", "filename": "TEST_DIR/t.qcow2"}} (qcow2)
- Removable device: not locked, tray closed
- Cache mode: writeback
- Backing file: TEST_DIR/t.qcow2.orig (chain depth: 1)
-(qemu) quit
+QMP_VERSION
+{"return": [{"device": "drive0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"backing-image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2.orig", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "backing-filename-format": "qcow2", "virtual-size": 134217728, "filename": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DI
R/t.qcow2.orig\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "full-backing-filename": "TEST_DIR/t.qcow2.base", "backing-filename": "TEST_DIR/t.qcow2.base", "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "backing"}, {"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 1, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "backing_file": "TEST_DIR/t.qcow2.orig", "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.orig\"}}
, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}"}, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,driver=raw,backing.file.filename=TEST_DIR/t.qcow2.orig
QEMU_PROG: -drive file=TEST_DIR/t.qcow2,driver=raw,backing.file.filename=TEST_DIR/t.qcow2.orig: Driver doesn't support backing files
@@ -102,12 +98,12 @@ QEMU_PROG: -drive file=TEST_DIR/t.qcow2,file.backing.driver=qcow2,file.backing.f
Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
Testing: -drive file=TEST_DIR/t.qcow2,format=qcow2,lazy-refcounts=on
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,format=qcow2,lazy-refcounts=off
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,format=qcow2,lazy-refcounts=
QEMU_PROG: -drive file=TEST_DIR/t.qcow2,format=qcow2,lazy-refcounts=: Parameter 'lazy-refcounts' expects 'on' or 'off'
@@ -126,191 +122,149 @@ Testing: -drive file=TEST_DIR/t.qcow2,format=qcow2,lazy-refcounts=on
QEMU_PROG: -drive file=TEST_DIR/t.qcow2,format=qcow2,lazy-refcounts=on: Lazy refcounts require a qcow2 image with at least qemu 1.1 compatibility level
Testing: -drive file=TEST_DIR/t.qcow2,format=qcow2,lazy-refcounts=off
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
=== No medium ===
Testing: -drive if=floppy
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive if=ide,media=cdrom
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive if=ide
-QEMU X.Y.Z monitor - type 'help' for more information
+QMP_VERSION
QEMU_PROG: Device needs media, but drive is empty
Testing: -drive if=virtio
-QEMU X.Y.Z monitor - type 'help' for more information
+QMP_VERSION
QEMU_PROG: -drive if=virtio: Device needs media, but drive is empty
Testing: -drive if=none,id=disk -device ide-cd,drive=disk
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive if=none,id=disk -device lsi53c895a -device scsi-cd,drive=disk
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive if=none,id=disk -device ide-hd,drive=disk
-QEMU X.Y.Z monitor - type 'help' for more information
+QMP_VERSION
QEMU_PROG: -device ide-hd,drive=disk: Device needs media, but drive is empty
Testing: -drive if=none,id=disk -device lsi53c895a -device scsi-hd,drive=disk
-QEMU X.Y.Z monitor - type 'help' for more information
+QMP_VERSION
QEMU_PROG: -device scsi-hd,drive=disk: Device needs media, but drive is empty
=== Attach to node in non-default iothread ===
Testing: -drive file=TEST_DIR/t.qcow2,if=none,node-name=disk -object iothread,id=thread0 -device virtio-scsi,iothread=thread0,id=virtio-scsi0 -device scsi-hd,bus=virtio-scsi0.0,drive=disk,share-rw=on -device ide-hd,drive=disk,share-rw=on
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) QEMU_PROG: -device ide-hd,drive=disk,share-rw=on: Cannot change iothread of active block backend
+QMP_VERSION
+QEMU_PROG: -device ide-hd,drive=disk,share-rw=on: Cannot change iothread of active block backend
Testing: -drive file=TEST_DIR/t.qcow2,if=none,node-name=disk -object iothread,id=thread0 -device virtio-scsi,iothread=thread0,id=virtio-scsi0 -device scsi-hd,bus=virtio-scsi0.0,drive=disk,share-rw=on -device virtio-blk-pci,drive=disk,share-rw=on
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) QEMU_PROG: -device virtio-blk-pci,drive=disk,share-rw=on: Cannot change iothread of active block backend
+QMP_VERSION
+QEMU_PROG: -device virtio-blk-pci,drive=disk,share-rw=on: Cannot change iothread of active block backend
Testing: -drive file=TEST_DIR/t.qcow2,if=none,node-name=disk -object iothread,id=thread0 -device virtio-scsi,iothread=thread0,id=virtio-scsi0 -device scsi-hd,bus=virtio-scsi0.0,drive=disk,share-rw=on -device lsi53c895a,id=lsi0 -device scsi-hd,bus=lsi0.0,drive=disk,share-rw=on
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) QEMU_PROG: -device scsi-hd,bus=lsi0.0,drive=disk,share-rw=on: HBA does not support iothreads
+QMP_VERSION
+QEMU_PROG: -device scsi-hd,bus=lsi0.0,drive=disk,share-rw=on: HBA does not support iothreads
Testing: -drive file=TEST_DIR/t.qcow2,if=none,node-name=disk -object iothread,id=thread0 -device virtio-scsi,iothread=thread0,id=virtio-scsi0 -device scsi-hd,bus=virtio-scsi0.0,drive=disk,share-rw=on -device virtio-scsi,id=virtio-scsi1 -device scsi-hd,bus=virtio-scsi1.0,drive=disk,share-rw=on
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,if=none,node-name=disk -object iothread,id=thread0 -device virtio-scsi,iothread=thread0,id=virtio-scsi0 -device scsi-hd,bus=virtio-scsi0.0,drive=disk,share-rw=on -device virtio-blk-pci,drive=disk,iothread=thread0,share-rw=on
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) QEMU_PROG: -device virtio-blk-pci,drive=disk,iothread=thread0,share-rw=on: Cannot change iothread of active block backend
+QMP_VERSION
+QEMU_PROG: -device virtio-blk-pci,drive=disk,iothread=thread0,share-rw=on: Cannot change iothread of active block backend
Testing: -drive file=TEST_DIR/t.qcow2,if=none,node-name=disk -object iothread,id=thread0 -device virtio-scsi,iothread=thread0,id=virtio-scsi0 -device scsi-hd,bus=virtio-scsi0.0,drive=disk,share-rw=on -device virtio-scsi,id=virtio-scsi1,iothread=thread0 -device scsi-hd,bus=virtio-scsi1.0,drive=disk,share-rw=on
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
=== Read-only ===
Testing: -drive file=TEST_DIR/t.qcow2,if=floppy,readonly=on
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,if=ide,media=cdrom,readonly=on
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,if=ide,readonly=on
-QEMU X.Y.Z monitor - type 'help' for more information
+QMP_VERSION
QEMU_PROG: Block node is read-only
Testing: -drive file=TEST_DIR/t.qcow2,if=virtio,readonly=on
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,if=none,id=disk,readonly=on -device ide-cd,drive=disk
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,if=none,id=disk,readonly=on -device lsi53c895a -device scsi-cd,drive=disk
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,if=none,id=disk,readonly=on -device ide-hd,drive=disk
-QEMU X.Y.Z monitor - type 'help' for more information
+QMP_VERSION
QEMU_PROG: -device ide-hd,drive=disk: Block node is read-only
Testing: -drive file=TEST_DIR/t.qcow2,if=none,id=disk,readonly=on -device lsi53c895a -device scsi-hd,drive=disk
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
=== Cache modes ===
Testing: -drive driver=null-co,read-zeroes=on,cache=none
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive driver=null-co,read-zeroes=on,cache=directsync
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive driver=null-co,read-zeroes=on,cache=writeback
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive driver=null-co,read-zeroes=on,cache=writethrough
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive driver=null-co,read-zeroes=on,cache=unsafe
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive driver=null-co,cache=invalid_value
QEMU_PROG: -drive driver=null-co,cache=invalid_value: invalid cache option
Testing: -drive file=TEST_DIR/t.qcow2,cache=writeback,backing.file.filename=TEST_DIR/t.qcow2.base,backing.cache.no-flush=on,backing.node-name=backing,backing.file.node-name=backing-file,file.node-name=file,if=none,id=drive0 -nodefaults
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-drive0 (NODE_NAME): json:{"backing": {"driver": "qcow2", "file": {"driver": "file", "filename": "TEST_DIR/t.qcow2.base"}}, "driver": "qcow2", "file": {"driver": "file", "filename": "TEST_DIR/t.qcow2"}} (qcow2)
- Removable device: not locked, tray closed
- Cache mode: writeback
- Backing file: TEST_DIR/t.qcow2.base (chain depth: 1)
-(qemu) info block file
-
-file: TEST_DIR/t.qcow2 (file)
- Cache mode: writeback
-(qemu) info block backing
-backing: TEST_DIR/t.qcow2.base (qcow2, read-only)
- Cache mode: writeback, ignore flushes
-(qemu) info block backing-file
-
-backing-file: TEST_DIR/t.qcow2.base (file, read-only)
- Cache mode: writeback, ignore flushes
-(qemu) quit
+QMP_VERSION
+{"return": [{"device": "drive0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"backing-image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2.base", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qc
ow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "0.10", "compression-type": "zlib", "refcount-bits": 16}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "backing", "child": "backing"}, {"node-name": "file", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 1, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "backing_file": "TEST_DIR/t.qcow2.base", "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}"}, "type": "unknown"}]}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2.base", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [{"node-name": "backing-file", "child": "file"}], "node-name": "backing", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": true, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2.base"}, {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-a
lignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 197120, "filename": "TEST_DIR/t.qcow2.base", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [], "node-name": "backing-file", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": true, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2.base"}, {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"backing-image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2.base", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compr
ession-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "0.10", "compression-type": "zlib", "refcount-bits": 16}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "backing", "child": "backing"}, {"node-name": "file", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 1, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "backi
ng_file": "TEST_DIR/t.qcow2.base", "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}"}, {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 197120, "filename": "TEST_DIR/t.qcow2", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "file", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,cache=writethrough,backing.file.filename=TEST_DIR/t.qcow2.base,backing.cache.no-flush=on,backing.node-name=backing,backing.file.node-name=backing-file,file.node-name=file,if=none,id=drive0 -nodefaults
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-drive0 (NODE_NAME): json:{"backing": {"driver": "qcow2", "file": {"driver": "file", "filename": "TEST_DIR/t.qcow2.base"}}, "driver": "qcow2", "file": {"driver": "file", "filename": "TEST_DIR/t.qcow2"}} (qcow2)
- Removable device: not locked, tray closed
- Cache mode: writethrough
- Backing file: TEST_DIR/t.qcow2.base (chain depth: 1)
-(qemu) info block file
-
-file: TEST_DIR/t.qcow2 (file)
- Cache mode: writeback
-(qemu) info block backing
-backing: TEST_DIR/t.qcow2.base (qcow2, read-only)
- Cache mode: writeback, ignore flushes
-(qemu) info block backing-file
-
-backing-file: TEST_DIR/t.qcow2.base (file, read-only)
- Cache mode: writeback, ignore flushes
-(qemu) quit
+QMP_VERSION
+{"return": [{"device": "drive0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"backing-image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2.base", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qc
ow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "0.10", "compression-type": "zlib", "refcount-bits": 16}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "backing", "child": "backing"}, {"node-name": "file", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 1, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "backing_file": "TEST_DIR/t.qcow2.base", "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": false}, "file": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}"}, "type": "unknown"}]}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2.base", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [{"node-name": "backing-file", "child": "file"}], "node-name": "backing", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": true, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2.base"}, {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-a
lignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 197120, "filename": "TEST_DIR/t.qcow2.base", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [], "node-name": "backing-file", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": true, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2.base"}, {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"backing-image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2.base", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compr
ession-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "0.10", "compression-type": "zlib", "refcount-bits": 16}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "backing", "child": "backing"}, {"node-name": "file", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 1, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "backi
ng_file": "TEST_DIR/t.qcow2.base", "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}"}, {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 197120, "filename": "TEST_DIR/t.qcow2", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "file", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,cache=unsafe,backing.file.filename=TEST_DIR/t.qcow2.base,backing.cache.no-flush=on,backing.node-name=backing,backing.file.node-name=backing-file,file.node-name=file,if=none,id=drive0 -nodefaults
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-drive0 (NODE_NAME): json:{"backing": {"driver": "qcow2", "file": {"driver": "file", "filename": "TEST_DIR/t.qcow2.base"}}, "driver": "qcow2", "file": {"driver": "file", "filename": "TEST_DIR/t.qcow2"}} (qcow2)
- Removable device: not locked, tray closed
- Cache mode: writeback, ignore flushes
- Backing file: TEST_DIR/t.qcow2.base (chain depth: 1)
-(qemu) info block file
-
-file: TEST_DIR/t.qcow2 (file)
- Cache mode: writeback, ignore flushes
-(qemu) info block backing
-backing: TEST_DIR/t.qcow2.base (qcow2, read-only)
- Cache mode: writeback, ignore flushes
-(qemu) info block backing-file
-
-backing-file: TEST_DIR/t.qcow2.base (file, read-only)
- Cache mode: writeback, ignore flushes
-(qemu) quit
+QMP_VERSION
+{"return": [{"device": "drive0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"backing-image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2.base", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qc
ow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "0.10", "compression-type": "zlib", "refcount-bits": 16}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "backing", "child": "backing"}, {"node-name": "file", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 1, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "backing_file": "TEST_DIR/t.qcow2.base", "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": true, "direct": false, "writeback": true}, "file": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}"}, "type": "unknown"}]}
+{"return": [{"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2.base", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [{"node-name": "backing-file", "child": "file"}], "node-name": "backing", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": true, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2.base"}, {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-a
lignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 197120, "filename": "TEST_DIR/t.qcow2.base", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [], "node-name": "backing-file", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": true, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2.base"}, {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"backing-image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2.base", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compr
ession-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "0.10", "compression-type": "zlib", "refcount-bits": 16}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "backing", "child": "backing"}, {"node-name": "file", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 1, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "backi
ng_file": "TEST_DIR/t.qcow2.base", "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": true, "direct": false, "writeback": true}, "file": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2.base\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}"}, {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"request-alignment": 1, "min-mem-alignment": 1, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 197120, "filename": "TEST_DIR/t.qcow2", "format": "file", "actual-size": SIZE, "format-specific": {"type": "file", "data": {}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [], "node-name": "file", "backing_file_depth": 0, "drv": "file", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": true, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,cache=invalid_value,backing.file.filename=TEST_DIR/t.qcow2.base,backing.cache.no-flush=on,backing.node-name=backing,backing.file.node-name=backing-file,file.node-name=file,if=none,id=drive0 -nodefaults
QEMU_PROG: -drive file=TEST_DIR/t.qcow2,cache=invalid_value,backing.file.filename=TEST_DIR/t.qcow2.base,backing.cache.no-flush=on,backing.node-name=backing,backing.file.node-name=backing-file,file.node-name=file,if=none,id=drive0: invalid cache option
@@ -319,8 +273,8 @@ QEMU_PROG: -drive file=TEST_DIR/t.qcow2,cache=invalid_value,backing.file.filenam
=== Specifying the protocol layer ===
Testing: -drive file=TEST_DIR/t.qcow2,file.driver=file
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
=== Leaving out required options ===
@@ -416,16 +370,16 @@ Testing: -drive file=TEST_DIR/t.qcow2,throttling.bps-total=-5
QEMU_PROG: -drive file=TEST_DIR/t.qcow2,throttling.bps-total=-5: bps/iops/max values must be within [0, 1000000000000000]
Testing: -drive file=TEST_DIR/t.qcow2,bps=0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,bps=1
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,bps=1000000000000000
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,bps=1000000000000001
QEMU_PROG: -drive file=TEST_DIR/t.qcow2,bps=1000000000000001: bps/iops/max values must be within [0, 1000000000000000]
@@ -446,12 +400,12 @@ Testing: -drive file.filename=foo:bar
QEMU_PROG: -drive file.filename=foo:bar: Could not open 'foo:bar': No such file or directory
Testing: -hda file:TEST_DIR/t.qcow2
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=file:TEST_DIR/t.qcow2
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) quit
+QMP_VERSION
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file.filename=file:TEST_DIR/t.qcow2
QEMU_PROG: -drive file.filename=file:TEST_DIR/t.qcow2: Could not open 'file:TEST_DIR/t.qcow2': No such file or directory
@@ -462,79 +416,60 @@ QEMU_PROG: -drive file.filename=file:TEST_DIR/t.qcow2: Could not open 'file:TEST
wrote 4096/4096 bytes at offset 0
4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
Testing: -drive file=TEST_DIR/t.qcow2,if=none,id=drive0 -snapshot
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io drive0 "write -P 0x22 0 4k"
-wrote 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,snapshot=on,if=none,id=drive0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io drive0 "write -P 0x22 0 4k"
-wrote 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file.filename=TEST_DIR/t.qcow2,driver=qcow2,snapshot=on,if=none,id=drive0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io drive0 "write -P 0x22 0 4k"
-wrote 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file.filename=TEST_DIR/t.qcow2,driver=qcow2,if=none,id=drive0 -snapshot
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io drive0 "write -P 0x22 0 4k"
-wrote 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=file:TEST_DIR/t.qcow2,if=none,id=drive0 -snapshot
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io drive0 "write -P 0x22 0 4k"
-wrote 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=file:TEST_DIR/t.qcow2,snapshot=on,if=none,id=drive0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io drive0 "write -P 0x22 0 4k"
-wrote 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,if=none,id=drive0 -snapshot
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io drive0 "write -P 0x22 0 4k"
-wrote 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
Testing: -drive file=TEST_DIR/t.qcow2,snapshot=on,if=none,id=drive0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io drive0 "write -P 0x22 0 4k"
-wrote 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
read 4096/4096 bytes at offset 0
4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
Testing: -drive file=TEST_DIR/t.qcow2,snapshot=off,if=none,id=drive0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io drive0 "write -P 0x22 0 4k"
-wrote 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) quit
+QMP_VERSION
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
read 4096/4096 bytes at offset 0
4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
Testing: -drive file=TEST_DIR/t.qcow2,snapshot=on,if=none,id=drive0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) qemu-io drive0 "write -P 0x33 0 4k"
-wrote 4096/4096 bytes at offset 0
-4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
-(qemu) commit drive0
-(qemu) quit
+{ 'execute': 'x-qemu-io', 'arguments': { 'device': 'drive0', 'command': 'write -P 0x33 0 4k' } }
+{"return": {"human-readable-text": "wrote 4096/4096 bytes at offset 0\n4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)\n"}}
+{ 'execute': 'block-commit', 'arguments': { 'device': 'drive0', 'job-id': 'job0' } }
+{ 'execute': 'block-job-complete', 'arguments': { 'device': 'job0' } }
+block job completed
read 4096/4096 bytes at offset 0
4 KiB, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
@@ -542,12 +477,8 @@ Testing: -drive driver=null-co,snapshot=on
QEMU_PROG: -drive driver=null-co,snapshot=on: Could not open temporary file SNAPSHOT_PATH: No such file or directory
Testing: -drive file=TEST_DIR/t.qcow2,snapshot=on,read-only=on,if=none,id=drive0
-QEMU X.Y.Z monitor - type 'help' for more information
-(qemu) info block
-drive0 (NODE_NAME): json:{"backing": {"driver": "qcow2", "file": {"driver": "file", "filename": "TEST_DIR/t.qcow2"}}, "driver": "qcow2", "file": {"driver": "file", "filename": SNAPSHOT_PATH}} (qcow2, read-only)
- Removable device: not locked, tray closed
- Cache mode: writeback, ignore flushes
- Backing file: TEST_DIR/t.qcow2 (chain depth: 1)
-(qemu) quit
+QMP_VERSION
+{"return": [{"device": "drive0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"backing-image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "0.10", "compression-type": "zlib", "refcount-bits": 16}}, "dirty-flag": false}, "limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 134217728, "filename": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"SNAPSHOT_PATH\"}}"
, "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": true, "children": [{"node-name": "NODE_NAME", "child": "backing"}, {"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 1, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "backing_file": "TEST_DIR/t.qcow2", "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": true, "direct": false, "writeback": true}, "file": "json:{\"backing\": {\"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"TEST_DIR/t.qcow2\"}}, \"driver\": \"qcow2\", \"file\": {\"driver\": \"file\", \"filename\": \"SNAPSHOT_PATH\"}}"}, "type": "unknown"}]}
+{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN", "data": {"guest": false, "reason": "host-qmp-quit"}}
*** done
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 85/88] qdev: add x-query-qtree QMP command
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (83 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 84/88] qemu-iotests/051: " Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 86/88] qemu-iotests/172: migrate away from HMP Marc-André Lureau
` (4 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel
Cc: Kevin Wolf, Marc-André Lureau, Michael S. Tsirkin,
Laurent Vivier, Amit Shah, Paolo Bonzini, Daniel P. Berrangé,
Stefano Stabellini, Anthony PERARD, Edgar E. Iglesias, Eric Blake,
Markus Armbruster, xen-devel, qemu-rust
Add x-query-qtree QMP command returning HumanReadableText with the
device tree. Supports an optional "brief" parameter to omit device
properties, matching the -b flag of "info qtree".
Refactor the BusClass print_dev callback and qbus_print/qdev_print
functions to write to a GString buffer instead of requiring a Monitor,
so the QMP command can collect the output directly without needing
monitor internals.
Rewire hmp_info_qtree to use the new QMP command.
Eventually, qom-list and properties retrieval should be enhanced to
do tree traversal and make this pretty-printing method obsolete and
return structured data instead.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
hw/char/virtio-serial-bus.c | 23 ++++++++--------------
hw/core/sysbus.c | 17 +++++------------
hw/misc/auxbus.c | 22 ++++++++-------------
hw/pci/pci-hmp-cmds.c | 38 -------------------------------------
hw/pci/pci-internal.h | 2 +-
hw/pci/pci.c | 40 +++++++++++++++++++++++++++++++++++++--
hw/usb/bus.c | 23 ++++++++--------------
hw/xen/xen-bus.c | 12 +++---------
include/hw/core/qdev.h | 4 +---
qapi/qdev.json | 31 ++++++++++++++++++++++++++++++
rust/bindings/hwcore-sys/lib.rs | 2 +-
system/qdev-monitor.c | 42 +++++++++++++++++++++++++++--------------
12 files changed, 132 insertions(+), 124 deletions(-)
diff --git a/hw/char/virtio-serial-bus.c b/hw/char/virtio-serial-bus.c
index c36e18a4cfb5..af438316f1a4 100644
--- a/hw/char/virtio-serial-bus.c
+++ b/hw/char/virtio-serial-bus.c
@@ -24,8 +24,6 @@
#include "qemu/main-loop.h"
#include "qemu/module.h"
#include "migration/qemu-file-types.h"
-#include "monitor/monitor.h"
-#include "monitor/hmp.h"
#include "qemu/error-report.h"
#include "qemu/queue.h"
#include "hw/core/qdev-properties.h"
@@ -818,9 +816,7 @@ static int virtio_serial_load_device(VirtIODevice *vdev, QEMUFile *f,
return 0;
}
-#ifdef CONFIG_HMP
-static void virtser_bus_dev_print(MonitorHMP *hmp, DeviceState *qdev, int indent);
-#endif
+static void virtser_bus_dev_print(GString *buf, DeviceState *qdev, int indent);
static const Property virtser_props[] = {
DEFINE_PROP_UINT32("nr", VirtIOSerialPort, id, VIRTIO_CONSOLE_BAD_ID),
@@ -829,10 +825,8 @@ static const Property virtser_props[] = {
static void virtser_bus_class_init(ObjectClass *klass, const void *data)
{
-#ifdef CONFIG_HMP
BusClass *k = BUS_CLASS(klass);
k->print_dev = virtser_bus_dev_print;
-#endif
}
static const TypeInfo virtser_bus_info = {
@@ -842,18 +836,17 @@ static const TypeInfo virtser_bus_info = {
.class_init = virtser_bus_class_init,
};
-#ifdef CONFIG_HMP
-static void virtser_bus_dev_print(MonitorHMP *hmp, DeviceState *qdev, int indent)
+static void virtser_bus_dev_print(GString *buf, DeviceState *qdev, int indent)
{
VirtIOSerialPort *port = VIRTIO_SERIAL_PORT(qdev);
- monitor_hmp_printf(hmp, "%*sport %d, guest %s, host %s, throttle %s\n",
- indent, "", port->id,
- port->guest_connected ? "on" : "off",
- port->host_connected ? "on" : "off",
- port->throttled ? "on" : "off");
+ g_string_append_printf(buf,
+ "%*sport %d, guest %s, host %s, throttle %s\n",
+ indent, "", port->id,
+ port->guest_connected ? "on" : "off",
+ port->host_connected ? "on" : "off",
+ port->throttled ? "on" : "off");
}
-#endif
/* This function is only used if a port id is not provided by the user */
static uint32_t find_free_port_id(VirtIOSerial *vser)
diff --git a/hw/core/sysbus.c b/hw/core/sysbus.c
index fe8f867a8d9c..3a5fd52192d8 100644
--- a/hw/core/sysbus.c
+++ b/hw/core/sysbus.c
@@ -20,13 +20,9 @@
#include "qemu/osdep.h"
#include "qapi/error.h"
#include "hw/core/sysbus.h"
-#include "monitor/monitor.h"
-#include "monitor/hmp.h"
#include "system/address-spaces.h"
-#ifdef CONFIG_HMP
-static void sysbus_dev_print(MonitorHMP *hmp, DeviceState *dev, int indent);
-#endif
+static void sysbus_dev_print(GString *buf, DeviceState *dev, int indent);
static char *sysbus_get_fw_dev_path(DeviceState *dev);
typedef struct SysBusFind {
@@ -78,9 +74,7 @@ static void system_bus_class_init(ObjectClass *klass, const void *data)
{
BusClass *k = BUS_CLASS(klass);
-#ifdef CONFIG_HMP
k->print_dev = sysbus_dev_print;
-#endif
k->get_fw_dev_path = sysbus_get_fw_dev_path;
}
@@ -253,8 +247,7 @@ bool sysbus_realize_and_unref(SysBusDevice *dev, Error **errp)
return qdev_realize_and_unref(DEVICE(dev), sysbus_get_default(), errp);
}
-#ifdef CONFIG_HMP
-static void sysbus_dev_print(MonitorHMP *hmp, DeviceState *dev, int indent)
+static void sysbus_dev_print(GString *buf, DeviceState *dev, int indent)
{
SysBusDevice *s = SYS_BUS_DEVICE(dev);
hwaddr size;
@@ -262,11 +255,11 @@ static void sysbus_dev_print(MonitorHMP *hmp, DeviceState *dev, int indent)
for (i = 0; i < s->num_mmio; i++) {
size = memory_region_size(s->mmio[i].memory);
- monitor_hmp_printf(hmp, "%*smmio " HWADDR_FMT_plx "/" HWADDR_FMT_plx "\n",
- indent, "", s->mmio[i].addr, size);
+ g_string_append_printf(buf, "%*smmio "
+ HWADDR_FMT_plx "/" HWADDR_FMT_plx "\n",
+ indent, "", s->mmio[i].addr, size);
}
}
-#endif
static char *sysbus_get_fw_dev_path(DeviceState *dev)
{
diff --git a/hw/misc/auxbus.c b/hw/misc/auxbus.c
index 3f17784d9b8a..17033433147a 100644
--- a/hw/misc/auxbus.c
+++ b/hw/misc/auxbus.c
@@ -32,8 +32,6 @@
#include "qemu/module.h"
#include "hw/misc/auxbus.h"
#include "hw/i2c/i2c.h"
-#include "monitor/monitor.h"
-#include "monitor/hmp.h"
#include "qapi/error.h"
#ifndef DEBUG_AUX
@@ -47,22 +45,18 @@
} while (0)
-#ifdef CONFIG_HMP
-static void aux_slave_dev_print(MonitorHMP *hmp, DeviceState *dev, int indent);
-#endif
+static void aux_slave_dev_print(GString *buf, DeviceState *dev, int indent);
static inline I2CBus *aux_bridge_get_i2c_bus(AUXTOI2CState *bridge);
/* aux-bus implementation (internal not public) */
static void aux_bus_class_init(ObjectClass *klass, const void *data)
{
-#ifdef CONFIG_HMP
BusClass *k = BUS_CLASS(klass);
/* AUXSlave has an MMIO so we need to change the way we print information
* in monitor.
*/
k->print_dev = aux_slave_dev_print;
-#endif
}
AUXBus *aux_bus_init(DeviceState *parent, const char *name)
@@ -287,13 +281,12 @@ static const TypeInfo aux_to_i2c_type_info = {
};
/* aux-slave implementation */
-#ifdef CONFIG_HMP
static bool aux_bus_is_bridge(AUXBus *bus, DeviceState *dev)
{
return (dev == DEVICE(bus->bridge));
}
-static void aux_slave_dev_print(MonitorHMP *hmp, DeviceState *dev, int indent)
+static void aux_slave_dev_print(GString *buf, DeviceState *dev, int indent)
{
AUXBus *bus = AUX_BUS(qdev_get_parent_bus(dev));
AUXSlave *s;
@@ -305,12 +298,13 @@ static void aux_slave_dev_print(MonitorHMP *hmp, DeviceState *dev, int indent)
s = AUX_SLAVE(dev);
- monitor_hmp_printf(hmp, "%*smemory " HWADDR_FMT_plx "/" HWADDR_FMT_plx "\n",
- indent, "",
- object_property_get_uint(OBJECT(s->mmio), "addr", NULL),
- memory_region_size(s->mmio));
+ g_string_append_printf(buf,
+ "%*smemory " HWADDR_FMT_plx "/" HWADDR_FMT_plx "\n",
+ indent, "",
+ object_property_get_uint(OBJECT(s->mmio),
+ "addr", NULL),
+ memory_region_size(s->mmio));
}
-#endif
void aux_init_mmio(AUXSlave *aux_slave, MemoryRegion *mmio)
{
diff --git a/hw/pci/pci-hmp-cmds.c b/hw/pci/pci-hmp-cmds.c
index 879011da1384..776762f18fa5 100644
--- a/hw/pci/pci-hmp-cmds.c
+++ b/hw/pci/pci-hmp-cmds.c
@@ -135,44 +135,6 @@ void hmp_info_pci(MonitorHMP *hmp, const QDict *qdict)
qapi_free_PciInfoList(info_list);
}
-#ifdef CONFIG_HMP
-void pcibus_dev_print(MonitorHMP *hmp, DeviceState *dev, int indent)
-{
- PCIDevice *d = (PCIDevice *)dev;
- int class = pci_get_word(d->config + PCI_CLASS_DEVICE);
- const pci_class_desc *desc = get_class_desc(class);
- char ctxt[64];
- PCIIORegion *r;
- int i;
-
- if (desc->desc) {
- snprintf(ctxt, sizeof(ctxt), "%s", desc->desc);
- } else {
- snprintf(ctxt, sizeof(ctxt), "Class %04x", class);
- }
-
- monitor_hmp_printf(hmp, "%*sclass %s, addr %02x:%02x.%x, "
- "pci id %04x:%04x (sub %04x:%04x)\n",
- indent, "", ctxt, pci_dev_bus_num(d),
- PCI_SLOT(d->devfn), PCI_FUNC(d->devfn),
- pci_get_word(d->config + PCI_VENDOR_ID),
- pci_get_word(d->config + PCI_DEVICE_ID),
- pci_get_word(d->config + PCI_SUBSYSTEM_VENDOR_ID),
- pci_get_word(d->config + PCI_SUBSYSTEM_ID));
- for (i = 0; i < PCI_NUM_REGIONS; i++) {
- r = &d->io_regions[i];
- if (!r->size) {
- continue;
- }
- monitor_hmp_printf(hmp, "%*sbar %d: %s at 0x%"FMT_PCIBUS
- " [0x%"FMT_PCIBUS"]\n",
- indent, "",
- i, r->type & PCI_BASE_ADDRESS_SPACE_IO ? "i/o" : "mem",
- r->addr, r->addr + r->size - 1);
- }
-}
-#endif
-
void hmp_pcie_aer_inject_error(MonitorHMP *hmp, const QDict *qdict)
{
Error *err = NULL;
diff --git a/hw/pci/pci-internal.h b/hw/pci/pci-internal.h
index b7231fab5dc9..68a169488d09 100644
--- a/hw/pci/pci-internal.h
+++ b/hw/pci/pci-internal.h
@@ -16,7 +16,7 @@ extern PCIHostStateList pci_host_bridges;
const pci_class_desc *get_class_desc(int class);
PCIBus *pci_find_bus_nr(PCIBus *bus, int bus_num);
-void pcibus_dev_print(MonitorHMP *mon, DeviceState *dev, int indent);
+void pcibus_dev_print(GString *buf, DeviceState *dev, int indent);
int pcie_aer_parse_error_string(const char *error_name,
uint32_t *status, bool *correctable);
diff --git a/hw/pci/pci.c b/hw/pci/pci.c
index 0efb4eb4bb03..433568440853 100644
--- a/hw/pci/pci.c
+++ b/hw/pci/pci.c
@@ -293,9 +293,7 @@ static void pci_bus_class_init(ObjectClass *klass, const void *data)
ResettableClass *rc = RESETTABLE_CLASS(klass);
FWCfgDataGeneratorClass *fwgc = FW_CFG_DATA_GENERATOR_CLASS(klass);
-#ifdef CONFIG_HMP
k->print_dev = pcibus_dev_print;
-#endif
k->get_dev_path = pcibus_get_dev_path;
k->get_fw_dev_path = pcibus_get_fw_dev_path;
k->realize = pci_bus_realize;
@@ -2094,6 +2092,44 @@ const pci_class_desc *get_class_desc(int class)
return desc;
}
+void pcibus_dev_print(GString *buf, DeviceState *dev, int indent)
+{
+ PCIDevice *d = (PCIDevice *)dev;
+ int class = pci_get_word(d->config + PCI_CLASS_DEVICE);
+ const pci_class_desc *desc = get_class_desc(class);
+ char ctxt[64];
+ PCIIORegion *r;
+ int i;
+
+ if (desc->desc) {
+ snprintf(ctxt, sizeof(ctxt), "%s", desc->desc);
+ } else {
+ snprintf(ctxt, sizeof(ctxt), "Class %04x", class);
+ }
+
+ g_string_append_printf(buf, "%*sclass %s, addr %02x:%02x.%x, "
+ "pci id %04x:%04x (sub %04x:%04x)\n",
+ indent, "", ctxt, pci_dev_bus_num(d),
+ PCI_SLOT(d->devfn), PCI_FUNC(d->devfn),
+ pci_get_word(d->config + PCI_VENDOR_ID),
+ pci_get_word(d->config + PCI_DEVICE_ID),
+ pci_get_word(d->config + PCI_SUBSYSTEM_VENDOR_ID),
+ pci_get_word(d->config + PCI_SUBSYSTEM_ID));
+ for (i = 0; i < PCI_NUM_REGIONS; i++) {
+ r = &d->io_regions[i];
+ if (!r->size) {
+ continue;
+ }
+ g_string_append_printf(buf, "%*sbar %d: %s at 0x%"FMT_PCIBUS
+ " [0x%"FMT_PCIBUS"]\n",
+ indent, "",
+ i,
+ r->type & PCI_BASE_ADDRESS_SPACE_IO
+ ? "i/o" : "mem",
+ r->addr, r->addr + r->size - 1);
+ }
+}
+
void pci_init_nic_devices(PCIBus *bus, const char *default_model)
{
qemu_create_nic_bus_devices(&bus->qbus, TYPE_PCI_DEVICE, default_model,
diff --git a/hw/usb/bus.c b/hw/usb/bus.c
index 5cc5ffec33a1..c6d65274771f 100644
--- a/hw/usb/bus.c
+++ b/hw/usb/bus.c
@@ -8,14 +8,10 @@
#include "qemu/module.h"
#include "system/system.h"
#include "migration/vmstate.h"
-#include "monitor/monitor.h"
-#include "monitor/hmp.h"
#include "trace.h"
#include "qemu/cutils.h"
-#ifdef CONFIG_HMP
-static void usb_bus_dev_print(MonitorHMP *hmp, DeviceState *qdev, int indent);
-#endif
+static void usb_bus_dev_print(GString *buf, DeviceState *qdev, int indent);
static char *usb_get_dev_path(DeviceState *dev);
static char *usb_get_fw_dev_path(DeviceState *qdev);
@@ -34,9 +30,7 @@ static void usb_bus_class_init(ObjectClass *klass, const void *data)
BusClass *k = BUS_CLASS(klass);
HotplugHandlerClass *hc = HOTPLUG_HANDLER_CLASS(klass);
-#ifdef CONFIG_HMP
k->print_dev = usb_bus_dev_print;
-#endif
k->get_dev_path = usb_get_dev_path;
k->get_fw_dev_path = usb_get_fw_dev_path;
hc->unplug = qdev_simple_device_unplug_cb;
@@ -548,19 +542,18 @@ static const char *usb_speed(unsigned int speed)
return txt[speed];
}
-#ifdef CONFIG_HMP
-static void usb_bus_dev_print(MonitorHMP *hmp, DeviceState *qdev, int indent)
+static void usb_bus_dev_print(GString *buf, DeviceState *qdev, int indent)
{
USBDevice *dev = USB_DEVICE(qdev);
USBBus *bus = usb_bus_from_device(dev);
- monitor_hmp_printf(hmp, "%*saddr %d.%d, port %s, speed %s, name %s%s\n",
- indent, "", bus->busnr, dev->addr,
- dev->port ? dev->port->path : "-",
- usb_speed(dev->speed), dev->product_desc,
- dev->attached ? ", attached" : "");
+ g_string_append_printf(buf,
+ "%*saddr %d.%d, port %s, speed %s, name %s%s\n",
+ indent, "", bus->busnr, dev->addr,
+ dev->port ? dev->port->path : "-",
+ usb_speed(dev->speed), dev->product_desc,
+ dev->attached ? ", attached" : "");
}
-#endif
static char *usb_get_dev_path(DeviceState *qdev)
{
diff --git a/hw/xen/xen-bus.c b/hw/xen/xen-bus.c
index 8def3bb68bc6..cc98034230e8 100644
--- a/hw/xen/xen-bus.c
+++ b/hw/xen/xen-bus.c
@@ -16,8 +16,6 @@
#include "hw/xen/xen-legacy-backend.h" /* xen_be_init() */
#include "hw/xen/xen-bus.h"
#include "hw/xen/xen-bus-helper.h"
-#include "monitor/monitor.h"
-#include "monitor/hmp.h"
#include "qapi/error.h"
#include "qobject/qdict.h"
#include "system/system.h"
@@ -101,15 +99,13 @@ abort:
qemu_xen_xs_transaction_end(xenbus->xsh, tid, true);
}
-#ifdef CONFIG_HMP
-static void xen_bus_print_dev(MonitorHMP *hmp, DeviceState *dev, int indent)
+static void xen_bus_print_dev(GString *buf, DeviceState *dev, int indent)
{
XenDevice *xendev = XEN_DEVICE(dev);
- monitor_hmp_printf(hmp, "%*sname = '%s' frontend_id = %u\n",
- indent, "", xendev->name, xendev->frontend_id);
+ g_string_append_printf(buf, "%*sname = '%s' frontend_id = %u\n",
+ indent, "", xendev->name, xendev->frontend_id);
}
-#endif
static char *xen_bus_get_dev_path(DeviceState *dev)
{
@@ -388,9 +384,7 @@ static void xen_bus_class_init(ObjectClass *class, const void *data)
BusClass *bus_class = BUS_CLASS(class);
HotplugHandlerClass *hotplug_class = HOTPLUG_HANDLER_CLASS(class);
-#ifdef CONFIG_HMP
bus_class->print_dev = xen_bus_print_dev;
-#endif
bus_class->get_dev_path = xen_bus_get_dev_path;
bus_class->realize = xen_bus_realize;
bus_class->unrealize = xen_bus_unrealize;
diff --git a/include/hw/core/qdev.h b/include/hw/core/qdev.h
index 1f6bf3fc1abf..e8399d8541fb 100644
--- a/include/hw/core/qdev.h
+++ b/include/hw/core/qdev.h
@@ -323,10 +323,8 @@ DECLARE_OBJ_CHECKERS(BusState, BusClass,
struct BusClass {
ObjectClass parent_class;
-#ifdef CONFIG_HMP
/* FIXME first arg should be BusState */
- void (*print_dev)(MonitorHMP *mon, DeviceState *dev, int indent);
-#endif
+ void (*print_dev)(GString *buf, DeviceState *dev, int indent);
/*
* Return a newly allocated string containing the path of the
* device on this bus.
diff --git a/qapi/qdev.json b/qapi/qdev.json
index 974cf9c5830e..4b5ccfb37687 100644
--- a/qapi/qdev.json
+++ b/qapi/qdev.json
@@ -165,6 +165,37 @@
{ 'event': 'DEVICE_UNPLUG_GUEST_ERROR',
'data': { '*device': 'str', 'path': 'str' } }
+##
+# @x-query-qtree:
+#
+# Query device tree
+#
+# @brief: if true, omit device properties. (default: false)
+#
+# Features:
+#
+# @unstable: This command is meant for debugging.
+#
+# Returns: device tree
+#
+# Since: 11.2
+#
+# .. qmp-example::
+#
+# -> { "execute": "x-query-qtree" }
+# <- { "return": { "human-readable-text": "..." } }
+#
+# .. qmp-example::
+#
+# -> { "execute": "x-query-qtree",
+# "arguments": { "brief": true } }
+# <- { "return": { "human-readable-text": "..." } }
+##
+{ 'command': 'x-query-qtree',
+ 'data': { '*brief': 'bool' },
+ 'returns': 'HumanReadableText',
+ 'features': [ 'unstable' ] }
+
##
# @device-sync-config:
#
diff --git a/rust/bindings/hwcore-sys/lib.rs b/rust/bindings/hwcore-sys/lib.rs
index cecbf808dd09..a28f5ab90f69 100644
--- a/rust/bindings/hwcore-sys/lib.rs
+++ b/rust/bindings/hwcore-sys/lib.rs
@@ -21,7 +21,7 @@
use chardev_sys::Chardev;
use common::Zeroable;
-use glib_sys::GSList;
+use glib_sys::{GSList, GString};
use migration_sys::VMStateDescription;
use qom_sys::{
InterfaceClass, Object, ObjectClass, ObjectProperty, ObjectPropertyAccessor,
diff --git a/system/qdev-monitor.c b/system/qdev-monitor.c
index 8185822daa71..1a4af35f9db1 100644
--- a/system/qdev-monitor.c
+++ b/system/qdev-monitor.c
@@ -27,6 +27,7 @@
#include "system/runstate.h"
#include "qapi/error.h"
#include "qapi/qapi-commands-qdev.h"
+#include "qapi/type-helpers.h"
#include "qapi/qmp-registry.h"
#include "qobject/qdict.h"
#include "qapi/qmp/qerror.h"
@@ -770,11 +771,10 @@ DeviceState *qdev_device_add(QemuOpts *opts, Error **errp)
return ret;
}
-#ifdef CONFIG_HMP
#define qdev_printf(fmt, ...) \
- monitor_hmp_printf(hmp, "%*s" fmt, indent, "", ## __VA_ARGS__)
+ g_string_append_printf(buf, "%*s" fmt, indent, "", ## __VA_ARGS__)
-static void qdev_print_props(MonitorHMP *hmp, DeviceState *dev, DeviceClass *dc,
+static void qdev_print_props(GString *buf, DeviceState *dev, DeviceClass *dc,
int indent)
{
for (int i = 0, n = dc->props_count_; i < n; ++i) {
@@ -798,16 +798,17 @@ static void qdev_print_props(MonitorHMP *hmp, DeviceState *dev, DeviceClass *dc,
}
}
-static void bus_print_dev(BusState *bus, MonitorHMP *hmp, DeviceState *dev, int indent)
+static void bus_print_dev(BusState *bus, GString *buf, DeviceState *dev,
+ int indent)
{
BusClass *bc = BUS_GET_CLASS(bus);
if (bc->print_dev) {
- bc->print_dev(hmp, dev, indent);
+ bc->print_dev(buf, dev, indent);
}
}
-static void qdev_print(MonitorHMP *hmp, DeviceState *dev, int indent)
+static void qdev_print(GString *buf, DeviceState *dev, int indent)
{
ObjectClass *class;
NamedGPIOList *ngl;
@@ -832,13 +833,13 @@ static void qdev_print(MonitorHMP *hmp, DeviceState *dev, int indent)
}
class = object_get_class(OBJECT(dev));
do {
- qdev_print_props(hmp, dev, DEVICE_CLASS(class), indent);
+ qdev_print_props(buf, dev, DEVICE_CLASS(class), indent);
class = object_class_get_parent(class);
} while (class != object_class_by_name(TYPE_DEVICE));
- bus_print_dev(dev->parent_bus, hmp, dev, indent);
+ bus_print_dev(dev->parent_bus, buf, dev, indent);
}
-static void qbus_print(MonitorHMP *hmp, BusState *bus, int indent, bool details)
+static void qbus_print(GString *buf, BusState *bus, int indent, bool details)
{
BusChild *kid;
@@ -851,22 +852,35 @@ static void qbus_print(MonitorHMP *hmp, BusState *bus, int indent, bool details)
qdev_printf("dev: %s, id \"%s\"\n", object_get_typename(OBJECT(dev)),
dev->id ? dev->id : "");
if (details) {
- qdev_print(hmp, dev, indent + 2);
+ qdev_print(buf, dev, indent + 2);
}
QLIST_FOREACH(child_bus, &dev->child_bus, sibling) {
- qbus_print(hmp, child_bus, indent + 2, details);
+ qbus_print(buf, child_bus, indent + 2, details);
}
}
}
#undef qdev_printf
-void hmp_info_qtree(MonitorHMP *hmp, const QDict *qdict)
+HumanReadableText *qmp_x_query_qtree(bool has_brief, bool brief, Error **errp)
{
- bool details = !qdict_get_try_bool(qdict, "brief", false);
+ g_autoptr(GString) buf = g_string_new("");
+ bool details = !(has_brief && brief);
if (sysbus_get_default()) {
- qbus_print(hmp, sysbus_get_default(), 0, details);
+ qbus_print(buf, sysbus_get_default(), 0, details);
}
+
+ return human_readable_text_from_str(buf);
+}
+
+#ifdef CONFIG_HMP
+void hmp_info_qtree(MonitorHMP *hmp, const QDict *qdict)
+{
+ bool brief = qdict_get_try_bool(qdict, "brief", false);
+ g_autoptr(HumanReadableText) info =
+ qmp_x_query_qtree(true, brief, &error_abort);
+
+ monitor_hmp_printf(hmp, "%s", info->human_readable_text);
}
void hmp_info_qdm(MonitorHMP *hmp, const QDict *qdict)
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 86/88] qemu-iotests/172: migrate away from HMP
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (84 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 85/88] qdev: add x-query-qtree QMP command Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 87/88] qemu-iotests: remove HMP framework support Marc-André Lureau
` (3 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Replace HMP with QMP, using x-query-qtree for the device tree and
query-block for block device info.
The query-block output now includes all block devices, including those
without media inserted (e.g. ide1-cd0, empty floppy drives).
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/172 | 76 +++++++++--
tests/qemu-iotests/172.out | 305 ++++-----------------------------------------
2 files changed, 89 insertions(+), 292 deletions(-)
diff --git a/tests/qemu-iotests/172 b/tests/qemu-iotests/172
index a78e42ff0adf..b2b06f404772 100755
--- a/tests/qemu-iotests/172
+++ b/tests/qemu-iotests/172
@@ -42,7 +42,6 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
_supported_fmt qcow2
_supported_proto file
_supported_os Linux
-_require_hmp
if [ "$QEMU_DEFAULT_MACHINE" != "pc" ]; then
_notrun "Requires a PC machine"
@@ -51,16 +50,70 @@ fi
do_run_qemu()
{
(
+ echo '{"execute":"qmp_capabilities"}'
if ! test -t 0; then
while read cmd; do
- echo $cmd
+ echo "$cmd"
done
fi
- echo quit
- ) | $QEMU -accel qtest -nographic -monitor stdio -serial none -vga none -nic none "$@"
+ echo '{"execute":"quit"}'
+ ) | $QEMU -accel qtest -nographic -qmp stdio -serial none -vga none -nic none "$@"
echo
}
+_filter_qmp_responses()
+{
+ $PYTHON -c '
+import sys, json, re
+for line in sys.stdin:
+ try:
+ j = json.loads(line)
+ except Exception:
+ continue
+ if "error" in j:
+ print(json.dumps(j["error"]))
+ continue
+ r = j.get("return")
+ if r is None:
+ continue
+ if isinstance(r, dict) and "human-readable-text" in r:
+ p = False
+ for l in r["human-readable-text"].split("\n"):
+ if "dev: isa-fdc" in l:
+ p = True
+ elif p and l.startswith(" dev:"):
+ p = False
+ if p:
+ print(l)
+ elif isinstance(r, list):
+ if r:
+ s = json.dumps(r)
+ s = re.sub(r"device\[\d+\]", "device[N]", s)
+ print(s)
+'
+}
+
+_filter_block_cache()
+{
+ $PYTHON -c '
+import sys, json
+for line in sys.stdin:
+ try:
+ r = json.loads(line).get("return")
+ except Exception:
+ continue
+ if not isinstance(r, list):
+ continue
+ for entry in r:
+ if entry.get("device") == "none0" and "inserted" in entry:
+ cache = entry["inserted"]["cache"]
+ if cache["writeback"]:
+ print(" Cache mode: writeback")
+ else:
+ print(" Cache mode: writethrough")
+'
+}
+
check_floppy_qtree()
{
echo
@@ -68,21 +121,18 @@ check_floppy_qtree()
# QEMU_OPTIONS contains -nodefaults, we don't want that here because the
# defaults are part of what should be checked here.
- #
- # Apply the sed filter to stdout only, but keep the stderr output and
- # filter the qemu program name in it.
- printf "info qtree\ninfo block\n" |
+ printf '{"execute":"x-query-qtree"}\n{"execute":"query-block"}\n' |
(QEMU_OPTIONS="" do_run_qemu "$@" |
- _filter_testdir |_filter_generated_node_ids | _filter_hmp |
- sed -ne '/^ dev: isa-fdc/,/^ dev:/{x;p};/^[a-z][^ ]* (NODE_NAME):* /,/^(qemu)$/{p}') 2>&1 |
- _filter_win32 | _filter_qemu | _filter_qom_path
+ _filter_testdir | _filter_generated_node_ids |
+ _filter_qmp_responses | _filter_actual_image_size) 2>&1 |
+ _filter_win32 | _filter_qemu
}
check_cache_mode()
{
- echo "info block none0" |
+ printf '{"execute":"query-block"}\n' |
QEMU_OPTIONS="" do_run_qemu -drive if=none,file="$TEST_IMG" "$@" |
- _filter_win32 | _filter_qemu | grep "Cache mode"
+ _filter_block_cache
}
diff --git a/tests/qemu-iotests/172.out b/tests/qemu-iotests/172.out
index a023cd407dee..e9310bd34f39 100644
--- a/tests/qemu-iotests/172.out
+++ b/tests/qemu-iotests/172.out
@@ -7,7 +7,6 @@ Formatting 'TEST_DIR/t.IMGFMT.3', fmt=IMGFMT size=737280
=== Default ===
Testing:
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -32,12 +31,12 @@ Testing:
account-failed = "auto"
stats-intervals = <null>
drive-type = "288"
+[{"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}, {"device": "floppy0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "type": "unknown"}]
=== Using -fda/-fdb options ===
Testing: -fda TEST_DIR/t.qcow2
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -62,19 +61,9 @@ Testing: -fda TEST_DIR/t.qcow2
account-failed = "auto"
stats-intervals = <null>
drive-type = "144"
-floppy0 (NODE_NAME): TEST_DIR/t.qcow2 (qcow2)
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-ide1-cd0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
-
+[{"device": "floppy0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}, "qdev": "/machine/unattached/device[N]"
, "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}]
Testing: -fdb TEST_DIR/t.qcow2
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -114,23 +103,9 @@ Testing: -fdb TEST_DIR/t.qcow2
account-failed = "auto"
stats-intervals = <null>
drive-type = "288"
-floppy1 (NODE_NAME): TEST_DIR/t.qcow2 (qcow2)
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-ide1-cd0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-
-floppy0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
-
+[{"device": "floppy1", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}, "qdev": "/machine/unattached/device[N]"
, "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}, {"device": "floppy0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "type": "unknown"}]
Testing: -fda TEST_DIR/t.qcow2 -fdb TEST_DIR/t.qcow2.2
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -170,24 +145,9 @@ Testing: -fda TEST_DIR/t.qcow2 -fdb TEST_DIR/t.qcow2.2
account-failed = "auto"
stats-intervals = <null>
drive-type = "144"
-floppy0 (NODE_NAME): TEST_DIR/t.qcow2 (qcow2)
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-floppy1 (NODE_NAME): TEST_DIR/t.qcow2.2 (qcow2)
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-ide1-cd0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
-
+[{"device": "floppy0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}, "qdev": "/machine/unattached/device[N]"
, "type": "unknown"}, {"device": "floppy1", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2.2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2.2"}, "qdev": "/mach
ine/unattached/device[N]", "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}]
Testing: -fdb
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -227,12 +187,12 @@ Testing: -fdb
account-failed = "auto"
stats-intervals = <null>
drive-type = "288"
+[{"device": "floppy1", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}, {"device": "floppy0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "type": "unknown"}]
=== Using -drive options ===
Testing: -drive if=floppy,file=TEST_DIR/t.qcow2
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -257,19 +217,9 @@ Testing: -drive if=floppy,file=TEST_DIR/t.qcow2
account-failed = "auto"
stats-intervals = <null>
drive-type = "144"
-floppy0 (NODE_NAME): TEST_DIR/t.qcow2 (qcow2)
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-ide1-cd0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
-
+[{"device": "floppy0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}, "qdev": "/machine/unattached/device[N]"
, "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}]
Testing: -drive if=floppy,file=TEST_DIR/t.qcow2,index=1
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -309,23 +259,9 @@ Testing: -drive if=floppy,file=TEST_DIR/t.qcow2,index=1
account-failed = "auto"
stats-intervals = <null>
drive-type = "288"
-floppy1 (NODE_NAME): TEST_DIR/t.qcow2 (qcow2)
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-ide1-cd0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-
-floppy0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
-
+[{"device": "floppy1", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}, "qdev": "/machine/unattached/device[N]"
, "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}, {"device": "floppy0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "type": "unknown"}]
Testing: -drive if=floppy,file=TEST_DIR/t.qcow2 -drive if=floppy,file=TEST_DIR/t.qcow2.2,index=1
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -365,27 +301,12 @@ Testing: -drive if=floppy,file=TEST_DIR/t.qcow2 -drive if=floppy,file=TEST_DIR/t
account-failed = "auto"
stats-intervals = <null>
drive-type = "144"
-floppy0 (NODE_NAME): TEST_DIR/t.qcow2 (qcow2)
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-floppy1 (NODE_NAME): TEST_DIR/t.qcow2.2 (qcow2)
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-ide1-cd0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
-
+[{"device": "floppy0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}, "qdev": "/machine/unattached/device[N]"
, "type": "unknown"}, {"device": "floppy1", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2.2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2.2"}, "qdev": "/mach
ine/unattached/device[N]", "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}]
=== Using -drive if=none and -device ===
Testing: -drive if=none,file=TEST_DIR/t.qcow2 -device floppy,drive=none0
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -410,19 +331,9 @@ Testing: -drive if=none,file=TEST_DIR/t.qcow2 -device floppy,drive=none0
account-failed = "auto"
stats-intervals = <null>
drive-type = "144"
-none0 (NODE_NAME): TEST_DIR/t.qcow2 (qcow2)
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-ide1-cd0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
-
+[{"device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}, "qdev": "/machine/peripheral-anon/device[
N]", "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}]
Testing: -drive if=none,file=TEST_DIR/t.qcow2 -device floppy,drive=none0,unit=1
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -447,19 +358,9 @@ Testing: -drive if=none,file=TEST_DIR/t.qcow2 -device floppy,drive=none0,unit=1
account-failed = "auto"
stats-intervals = <null>
drive-type = "144"
-none0 (NODE_NAME): TEST_DIR/t.qcow2 (qcow2)
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-ide1-cd0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
-
+[{"device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}, "qdev": "/machine/peripheral-anon/device[
N]", "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}]
Testing: -drive if=none,file=TEST_DIR/t.qcow2 -drive if=none,file=TEST_DIR/t.qcow2.2 -device floppy,drive=none0 -device floppy,drive=none1,unit=1
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -499,21 +400,7 @@ Testing: -drive if=none,file=TEST_DIR/t.qcow2 -drive if=none,file=TEST_DIR/t.qco
account-failed = "auto"
stats-intervals = <null>
drive-type = "144"
-none0 (NODE_NAME): TEST_DIR/t.qcow2 (qcow2)
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-none1 (NODE_NAME): TEST_DIR/t.qcow2.2 (qcow2)
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-ide1-cd0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
-
+[{"device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}, "qdev": "/machine/peripheral-anon/device[
N]", "type": "unknown"}, {"device": "none1", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2.2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2.2"}, "qdev": "/mac
hine/peripheral-anon/device[N]", "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}]
=== Mixing -fdX and -global ===
@@ -525,7 +412,6 @@ QEMU_PROG: -global floppy.drive=... conflicts with drive=floppy0
=== Mixing -fdX and -device ===
Testing: -fda TEST_DIR/t.qcow2 -drive if=none,file=TEST_DIR/t.qcow2.2 -device floppy,drive=none0
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -565,24 +451,9 @@ Testing: -fda TEST_DIR/t.qcow2 -drive if=none,file=TEST_DIR/t.qcow2.2 -device fl
account-failed = "auto"
stats-intervals = <null>
drive-type = "144"
-floppy0 (NODE_NAME): TEST_DIR/t.qcow2 (qcow2)
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-none0 (NODE_NAME): TEST_DIR/t.qcow2.2 (qcow2)
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-ide1-cd0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
-
+[{"device": "floppy0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}, "qdev": "/machine/unattached/device[N]"
, "type": "unknown"}, {"device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2.2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2.2"}, "qdev": "/machin
e/peripheral-anon/device[N]", "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}]
Testing: -fda TEST_DIR/t.qcow2 -drive if=none,file=TEST_DIR/t.qcow2.2 -device floppy,drive=none0,unit=1
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -622,24 +493,9 @@ Testing: -fda TEST_DIR/t.qcow2 -drive if=none,file=TEST_DIR/t.qcow2.2 -device fl
account-failed = "auto"
stats-intervals = <null>
drive-type = "144"
-floppy0 (NODE_NAME): TEST_DIR/t.qcow2 (qcow2)
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-none0 (NODE_NAME): TEST_DIR/t.qcow2.2 (qcow2)
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-ide1-cd0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
-
+[{"device": "floppy0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}, "qdev": "/machine/unattached/device[N]"
, "type": "unknown"}, {"device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2.2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2.2"}, "qdev": "/machin
e/peripheral-anon/device[N]", "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}]
Testing: -fdb TEST_DIR/t.qcow2 -drive if=none,file=TEST_DIR/t.qcow2.2 -device floppy,drive=none0
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -679,24 +535,9 @@ Testing: -fdb TEST_DIR/t.qcow2 -drive if=none,file=TEST_DIR/t.qcow2.2 -device fl
account-failed = "auto"
stats-intervals = <null>
drive-type = "144"
-floppy1 (NODE_NAME): TEST_DIR/t.qcow2 (qcow2)
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-none0 (NODE_NAME): TEST_DIR/t.qcow2.2 (qcow2)
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-ide1-cd0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
-
+[{"device": "floppy1", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}, "qdev": "/machine/unattached/device[N]"
, "type": "unknown"}, {"device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2.2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2.2"}, "qdev": "/machin
e/peripheral-anon/device[N]", "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}]
Testing: -fdb TEST_DIR/t.qcow2 -drive if=none,file=TEST_DIR/t.qcow2.2 -device floppy,drive=none0,unit=0
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -736,21 +577,7 @@ Testing: -fdb TEST_DIR/t.qcow2 -drive if=none,file=TEST_DIR/t.qcow2.2 -device fl
account-failed = "auto"
stats-intervals = <null>
drive-type = "144"
-floppy1 (NODE_NAME): TEST_DIR/t.qcow2 (qcow2)
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-none0 (NODE_NAME): TEST_DIR/t.qcow2.2 (qcow2)
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-ide1-cd0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
-
+[{"device": "floppy1", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}, "qdev": "/machine/unattached/device[N]"
, "type": "unknown"}, {"device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2.2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2.2"}, "qdev": "/machin
e/peripheral-anon/device[N]", "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}]
Testing: -fda TEST_DIR/t.qcow2 -drive if=none,file=TEST_DIR/t.qcow2.2 -device floppy,drive=none0,unit=0
QEMU_PROG: -device floppy,drive=none0,unit=0: Floppy unit 0 is in use
@@ -762,7 +589,6 @@ QEMU_PROG: -device floppy,drive=none0,unit=1: Floppy unit 1 is in use
=== Mixing -drive and -device ===
Testing: -drive if=floppy,file=TEST_DIR/t.qcow2 -drive if=none,file=TEST_DIR/t.qcow2.2 -device floppy,drive=none0
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -802,24 +628,9 @@ Testing: -drive if=floppy,file=TEST_DIR/t.qcow2 -drive if=none,file=TEST_DIR/t.q
account-failed = "auto"
stats-intervals = <null>
drive-type = "144"
-floppy0 (NODE_NAME): TEST_DIR/t.qcow2 (qcow2)
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-none0 (NODE_NAME): TEST_DIR/t.qcow2.2 (qcow2)
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-ide1-cd0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
-
+[{"device": "floppy0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}, "qdev": "/machine/unattached/device[N]"
, "type": "unknown"}, {"device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2.2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2.2"}, "qdev": "/machin
e/peripheral-anon/device[N]", "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}]
Testing: -drive if=floppy,file=TEST_DIR/t.qcow2 -drive if=none,file=TEST_DIR/t.qcow2.2 -device floppy,drive=none0,unit=1
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -859,21 +670,7 @@ Testing: -drive if=floppy,file=TEST_DIR/t.qcow2 -drive if=none,file=TEST_DIR/t.q
account-failed = "auto"
stats-intervals = <null>
drive-type = "144"
-floppy0 (NODE_NAME): TEST_DIR/t.qcow2 (qcow2)
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-none0 (NODE_NAME): TEST_DIR/t.qcow2.2 (qcow2)
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-ide1-cd0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
-
+[{"device": "floppy0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}, "qdev": "/machine/unattached/device[N]"
, "type": "unknown"}, {"device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2.2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2.2"}, "qdev": "/machin
e/peripheral-anon/device[N]", "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}]
Testing: -drive if=floppy,file=TEST_DIR/t.qcow2 -drive if=none,file=TEST_DIR/t.qcow2.2 -device floppy,drive=none0,unit=0
QEMU_PROG: -device floppy,drive=none0,unit=0: Floppy unit 0 is in use
@@ -882,7 +679,6 @@ QEMU_PROG: -device floppy,drive=none0,unit=0: Floppy unit 0 is in use
=== Mixing -global and -device ===
Testing: -drive if=none,file=TEST_DIR/t.qcow2 -global floppy.drive=none0 -device floppy,unit=0
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -907,16 +703,7 @@ Testing: -drive if=none,file=TEST_DIR/t.qcow2 -global floppy.drive=none0 -device
account-failed = "auto"
stats-intervals = <null>
drive-type = "144"
-none0 (NODE_NAME): TEST_DIR/t.qcow2 (qcow2)
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-ide1-cd0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
-
+[{"device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}, "qdev": "/machine/peripheral-anon/device[
N]", "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}]
Testing: -drive if=none,file=TEST_DIR/t.qcow2 -drive if=none,file=TEST_DIR/t.qcow2.2 -global floppy.drive=none0 -device floppy,drive=none1,unit=0
QEMU_PROG: -device floppy,drive=none1,unit=0: -global floppy.drive=... conflicts with drive=none1
@@ -949,7 +736,6 @@ QEMU_PROG: -device floppy,drive=none1: Can't create floppy unit 2, bus supports
=== Creating an empty drive with anonymous BB ===
Testing: -device floppy
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -974,9 +760,9 @@ Testing: -device floppy
account-failed = "auto"
stats-intervals = <null>
drive-type = "288"
+[{"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}, {"device": "", "locked": false, "removable": true, "qdev": "/machine/peripheral-anon/device[N]", "type": "unknown"}]
Testing: -device floppy,drive-type=120
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -1001,9 +787,9 @@ Testing: -device floppy,drive-type=120
account-failed = "auto"
stats-intervals = <null>
drive-type = "120"
+[{"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}, {"device": "", "locked": false, "removable": true, "qdev": "/machine/peripheral-anon/device[N]", "type": "unknown"}]
Testing: -device floppy,drive-type=144
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -1028,9 +814,9 @@ Testing: -device floppy,drive-type=144
account-failed = "auto"
stats-intervals = <null>
drive-type = "144"
+[{"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}, {"device": "", "locked": false, "removable": true, "qdev": "/machine/peripheral-anon/device[N]", "type": "unknown"}]
Testing: -device floppy,drive-type=288
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -1055,12 +841,12 @@ Testing: -device floppy,drive-type=288
account-failed = "auto"
stats-intervals = <null>
drive-type = "288"
+[{"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}, {"device": "", "locked": false, "removable": true, "qdev": "/machine/peripheral-anon/device[N]", "type": "unknown"}]
=== Try passing different drive size with image ===
Testing: -drive if=none,file=TEST_DIR/t.qcow2 -device floppy,drive=none0,drive-type=120
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -1085,19 +871,9 @@ Testing: -drive if=none,file=TEST_DIR/t.qcow2 -device floppy,drive=none0,drive-t
account-failed = "auto"
stats-intervals = <null>
drive-type = "120"
-none0 (NODE_NAME): TEST_DIR/t.qcow2 (qcow2)
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-ide1-cd0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
-
+[{"device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}, "qdev": "/machine/peripheral-anon/device[
N]", "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}]
Testing: -drive if=none,file=TEST_DIR/t.qcow2 -device floppy,drive=none0,drive-type=288
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -1122,22 +898,12 @@ Testing: -drive if=none,file=TEST_DIR/t.qcow2 -device floppy,drive=none0,drive-t
account-failed = "auto"
stats-intervals = <null>
drive-type = "288"
-none0 (NODE_NAME): TEST_DIR/t.qcow2 (qcow2)
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-ide1-cd0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
-
+[{"device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}, "qdev": "/machine/peripheral-anon/device[
N]", "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}]
=== Try passing different block sizes ===
Testing: -drive if=none,file=TEST_DIR/t.qcow2 -device floppy,drive=none0,logical_block_size=512
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -1162,19 +928,9 @@ Testing: -drive if=none,file=TEST_DIR/t.qcow2 -device floppy,drive=none0,logical
account-failed = "auto"
stats-intervals = <null>
drive-type = "144"
-none0 (NODE_NAME): TEST_DIR/t.qcow2 (qcow2)
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-ide1-cd0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
-
+[{"device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}, "qdev": "/machine/peripheral-anon/device[
N]", "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}]
Testing: -drive if=none,file=TEST_DIR/t.qcow2 -device floppy,drive=none0,physical_block_size=512
-
dev: isa-fdc, id ""
iobase = 1008 (0x3f0)
irq = 6 (0x6)
@@ -1199,16 +955,7 @@ Testing: -drive if=none,file=TEST_DIR/t.qcow2 -device floppy,drive=none0,physica
account-failed = "auto"
stats-intervals = <null>
drive-type = "144"
-none0 (NODE_NAME): TEST_DIR/t.qcow2 (qcow2)
- Attached to: /machine/peripheral-anon/device[N]
- Removable device: not locked, tray closed
- Cache mode: writeback
-
-ide1-cd0: [not inserted]
- Attached to: /machine/unattached/device[N]
- Removable device: not locked, tray closed
-(qemu) quit
-
+[{"device": "none0", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "active": true, "image": {"limits": {"write-zeroes-alignment": 65536, "request-alignment": 1, "min-mem-alignment": 1, "discard-alignment": 65536, "opt-mem-alignment": 4096, "max-iov": 1024}, "virtual-size": 737280, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "compression-type": "zlib", "lazy-refcounts": false, "refcount-bits": 16, "corrupt": false, "extended-l2": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "children": [{"node-name": "NODE_NAME", "child": "file"}], "node-name": "NODE_NAME", "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "write_threshold": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "cache": {"no-flush": false, "direct": false, "writeback": true}, "file": "TEST_DIR/t.qcow2"}, "qdev": "/machine/peripheral-anon/device[
N]", "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "qdev": "/machine/unattached/device[N]", "tray_open": false, "type": "unknown"}]
Testing: -drive if=none,file=TEST_DIR/t.qcow2 -device floppy,drive=none0,logical_block_size=4096
QEMU_PROG: -device floppy,drive=none0,logical_block_size=4096: logical_block_size > physical_block_size not supported
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 87/88] qemu-iotests: remove HMP framework support
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (85 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 86/88] qemu-iotests/172: migrate away from HMP Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-22 20:18 ` [PATCH 88/88] block/monitor: redirect HMP qemu-io to HMP stream Marc-André Lureau
` (2 subsequent siblings)
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
All tests have been migrated to QMP. Remove:
- _require_hmp() from common.rc
- _filter_hmp() from common.filter
- _filter_hmp from pipelines in common.qemu
- HMP monitor mode from _launch_qemu() in common.qemu
- hmp() method from iotests.py VM class
- _verify_hmp() and require_hmp parameter from iotests.py
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
tests/qemu-iotests/common.filter | 7 -------
tests/qemu-iotests/common.qemu | 34 +++++++++++-----------------------
tests/qemu-iotests/common.rc | 8 --------
tests/qemu-iotests/iotests.py | 28 +---------------------------
4 files changed, 12 insertions(+), 65 deletions(-)
diff --git a/tests/qemu-iotests/common.filter b/tests/qemu-iotests/common.filter
index f6d94f993691..1ed2004c494f 100644
--- a/tests/qemu-iotests/common.filter
+++ b/tests/qemu-iotests/common.filter
@@ -102,13 +102,6 @@ _filter_qmp()
-e ' QMP_VERSION'
}
-# readline makes HMP command strings so long that git complains
-_filter_hmp()
-{
- gsed -e $'s/^\\((qemu) \\)\\?.*\e\\[D/\\1/g' \
- -e $'s/\e\\[K//g'
-}
-
# replace block job offset
_filter_block_job_offset()
{
diff --git a/tests/qemu-iotests/common.qemu b/tests/qemu-iotests/common.qemu
index 458ea9566818..dbc286320b3d 100644
--- a/tests/qemu-iotests/common.qemu
+++ b/tests/qemu-iotests/common.qemu
@@ -119,7 +119,7 @@ _timed_wait_for()
if [ -z "${silent}" ] && [ -z "${mismatch_only}" ]; then
echo "${resp}" | _filter_testdir | _filter_qemu \
- | _filter_qemu_io | _filter_qmp | _filter_hmp
+ | _filter_qemu_io | _filter_qmp
fi
if [ -n "${failure_match}" ]; then
grep -q "${failure_match}" < <(echo "${resp}")
@@ -134,7 +134,7 @@ _timed_wait_for()
fi
if [ -z "${silent}" ] && [ -n "${mismatch_only}" ]; then
echo "${resp}" | _filter_testdir | _filter_qemu \
- | _filter_qemu_io | _filter_qmp | _filter_hmp
+ | _filter_qemu_io | _filter_qmp
fi
done
@@ -244,7 +244,7 @@ _check_cached_events()
grep -q "$match" < <(echo "${ev}")
if [ $? -eq 0 ] && [ $matched = 0 ]; then
echo "${ev}" | _filter_testdir | _filter_qemu \
- | _filter_qemu_io | _filter_qmp | _filter_hmp
+ | _filter_qemu_io | _filter_qmp
matched=1
else
QEMU_EVENTS="${QEMU_EVENTS:+${QEMU_EVENTS}%}${ev}"
@@ -312,9 +312,6 @@ _run_qmp_job()
# Launch a QEMU process.
#
# Input parameters:
-# $qemu_comm_method: set this variable to 'monitor' (case insensitive)
-# to use the QEMU HMP monitor for communication.
-# Otherwise, the default of QMP is used.
# $qmp_pretty: Set this variable to 'y' to enable QMP pretty printing.
# $keep_stderr: Set this variable to 'y' to keep QEMU's stderr output on stderr.
# If this variable is empty, stderr will be redirected to stdout.
@@ -327,16 +324,10 @@ _launch_qemu()
local fifo_out=
local fifo_in=
- if (shopt -s nocasematch; [[ "${qemu_comm_method}" == "monitor" ]])
- then
- comm="-monitor stdio"
+ if [ "$qmp_pretty" = "y" ]; then
+ comm="-monitor none -qmp-pretty stdio"
else
- local qemu_comm_method="qmp"
- if [ "$qmp_pretty" = "y" ]; then
- comm="-monitor none -qmp-pretty stdio"
- else
- comm="-monitor none -qmp stdio"
- fi
+ comm="-monitor none -qmp stdio"
fi
fifo_out=${QEMU_FIFO_OUT}_${_QEMU_HANDLE}
@@ -379,13 +370,10 @@ _launch_qemu()
QEMU_IN[${_QEMU_HANDLE}]=${_in_fd}
QEMU_STATUS[${_QEMU_HANDLE}]=0
- if [ "${qemu_comm_method}" == "qmp" ]
- then
- # Don't print response, since it has version information in it
- silent=yes _timed_wait_for ${_QEMU_HANDLE} "capabilities"
- if [ "$qmp_pretty" = "y" ]; then
- silent=yes _timed_wait_for ${_QEMU_HANDLE} "^}"
- fi
+ # Don't print response, since it has version information in it
+ silent=yes _timed_wait_for ${_QEMU_HANDLE} "capabilities"
+ if [ "$qmp_pretty" = "y" ]; then
+ silent=yes _timed_wait_for ${_QEMU_HANDLE} "^}"
fi
QEMU_HANDLE=${_QEMU_HANDLE}
let _QEMU_HANDLE++
@@ -416,7 +404,7 @@ _cleanup_qemu()
if [ -n "${wait}" ]; then
cat <&${QEMU_OUT[$i]} | _filter_testdir | _filter_qemu \
- | _filter_qemu_io | _filter_qmp | _filter_hmp
+ | _filter_qemu_io | _filter_qmp
fi
rm -f "${QEMU_FIFO_IN}_${i}" "${QEMU_FIFO_OUT}_${i}"
eval "exec ${QEMU_IN[$i]}<&-" # close file descriptors
diff --git a/tests/qemu-iotests/common.rc b/tests/qemu-iotests/common.rc
index 262fe63da820..bcb1ec50a93d 100644
--- a/tests/qemu-iotests/common.rc
+++ b/tests/qemu-iotests/common.rc
@@ -995,14 +995,6 @@ _notrun_on_fuse_error()
esac
}
-_require_hmp()
-{
- if echo quit | $QEMU -M none -display none -monitor stdio 2>&1 |
- grep -q "HMP monitor is not available"; then
- _notrun "HMP monitor not available"
- fi
-}
-
# Check that we have a file system that allows huge (but very sparse) files
#
_require_large_file()
diff --git a/tests/qemu-iotests/iotests.py b/tests/qemu-iotests/iotests.py
index 5d9b5ded64ac..b9c6878c3bce 100644
--- a/tests/qemu-iotests/iotests.py
+++ b/tests/qemu-iotests/iotests.py
@@ -934,14 +934,6 @@ def add_paused(self):
self._args.append('-S')
return self
- def hmp(self, command_line: str, use_log: bool = False) -> QMPMessage:
- cmd = 'human-monitor-command'
- kwargs: Dict[str, Any] = {'command-line': command_line}
- if use_log:
- return self.qmp_log(cmd, **kwargs)
- else:
- return self.qmp(cmd, **kwargs)
-
def pause_drive(self, drive: str, event: Optional[str] = None) -> None:
"""Pause drive r/w operations"""
if not event:
@@ -954,12 +946,6 @@ def resume_drive(self, drive: str) -> None:
"""Resume drive r/w operations"""
self.qmp_qemu_io(drive, f'remove_break bp_{drive}')
- def hmp_qemu_io(self, drive: str, cmd: str,
- use_log: bool = False, qdev: bool = False) -> QMPMessage:
- """Write to a given drive using an HMP command"""
- d = '-d ' if qdev else ''
- return self.hmp(f'qemu-io {d}{drive} "{cmd}"', use_log=use_log)
-
def qmp_qemu_io(self, drive: str, cmd: str,
use_log: bool = False, qdev: bool = False) -> str:
"""Write to a given drive using the x-qemu-io QMP command"""
@@ -1464,15 +1450,6 @@ def _verify_formats(required_formats: Sequence[str] = ()) -> None:
notrun(f'formats {usf_list} are not whitelisted')
-def _verify_hmp() -> None:
- args = [qemu_prog] + qemu_opts + ['-M', 'none', '-monitor', 'stdio']
- with subprocess.Popen(args, stdin=subprocess.PIPE,
- stdout=subprocess.PIPE, stderr=subprocess.STDOUT,
- universal_newlines=True) as subp:
- out, _ = subp.communicate('quit\n')
- if 'HMP monitor is not available' in out:
- notrun('HMP monitor not available')
-
def _verify_virtio_blk() -> None:
out = qemu_pipe('-M', 'none', '-device', 'help')
if 'virtio-blk' not in out:
@@ -1711,8 +1688,7 @@ def execute_setup_common(supported_fmts: Sequence[str] = (),
supported_protocols: Sequence[str] = (),
unsupported_protocols: Sequence[str] = (),
required_fmts: Sequence[str] = (),
- unsupported_imgopts: Sequence[str] = (),
- require_hmp: bool = False) -> bool:
+ unsupported_imgopts: Sequence[str] = ()) -> bool:
"""
Perform necessary setup for either script-style or unittest-style tests.
@@ -1733,8 +1709,6 @@ def execute_setup_common(supported_fmts: Sequence[str] = (),
_verify_formats(required_fmts)
_verify_virtio_blk()
_verify_imgopts(unsupported_imgopts)
- if require_hmp:
- _verify_hmp()
return debug
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* [PATCH 88/88] block/monitor: redirect HMP qemu-io to HMP stream
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (86 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 87/88] qemu-iotests: remove HMP framework support Marc-André Lureau
@ 2026-09-22 20:18 ` Marc-André Lureau
2026-09-23 9:36 ` [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Kevin Wolf
2026-09-23 9:40 ` Kevin Wolf
89 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-22 20:18 UTC (permalink / raw)
To: qemu-devel; +Cc: Kevin Wolf, Marc-André Lureau, Hanna Reitz, qemu-block
Now that all tests have been converted to rely on QMP stream result, we
can also redirect HMP output.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
---
block/monitor/block-hmp-cmds.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/block/monitor/block-hmp-cmds.c b/block/monitor/block-hmp-cmds.c
index ed071c0f4144..b1a1b4bae127 100644
--- a/block/monitor/block-hmp-cmds.c
+++ b/block/monitor/block-hmp-cmds.c
@@ -553,8 +553,7 @@ void hmp_qemu_io(MonitorHMP *hmp, const QDict *qdict)
return;
}
- /* use stdout and not monitor_puts() for compatiblity reasons */
- printf("%s", out->human_readable_text);
+ monitor_puts(MONITOR(hmp), out->human_readable_text);
}
static void print_block_info(MonitorHMP *hmp, BlockInfo *info,
--
2.56.0.rc0.29.g47ce80527c56
^ permalink raw reply related [flat|nested] 98+ messages in thread* Re: [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up)
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (87 preceding siblings ...)
2026-09-22 20:18 ` [PATCH 88/88] block/monitor: redirect HMP qemu-io to HMP stream Marc-André Lureau
@ 2026-09-23 9:36 ` Kevin Wolf
2026-09-23 10:07 ` Marc-André Lureau
2026-09-23 9:40 ` Kevin Wolf
89 siblings, 1 reply; 98+ messages in thread
From: Kevin Wolf @ 2026-09-23 9:36 UTC (permalink / raw)
To: Marc-André Lureau; +Cc: qemu-devel
Am 22.09.2026 um 22:17 hat Marc-André Lureau geschrieben:
> Hi,
>
> This series migrates all qemu-iotests away from HMP, so that the test
> framework no longer depends on it and can execute with --disable-hmp.
> This can simplify the tests, as they don't need to check/grep on stdout,
> HMP & QMP but can rely increasingly on QMP alone.
Hm... Doesn't this mean that HMP loses all of its test coverage? I don't
feel that's a good idea.
Most tests are based on diffing stdout anyway, so I don't expect this
removal simplifies them much. I'll have to look at the individual
patches, but I'd rather expect that their output becomes harder to read
instead.
What are the general plans with HMP? Are we expecting most builds to
have HMP disabled in the future? (Why? It's useful for human users.)
I think most tests probably combine testing the HMP interface with
testing the backend functionality. If we really expect missing HMP to be
a relevant case in the future, these parts need to be separated so that
the backend test can run with QMP only while the HMP interface tests run
only when HMP is available.
Not sure how this is best done without effectively running all tests
twice. Maybe there is a middle ground of converting some tests to QMP
and making other tests explicitgly depend on HMP (i.e. they are skipped
if HMP isn't available).
Kevin
^ permalink raw reply [flat|nested] 98+ messages in thread* Re: [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up)
2026-09-23 9:36 ` [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Kevin Wolf
@ 2026-09-23 10:07 ` Marc-André Lureau
0 siblings, 0 replies; 98+ messages in thread
From: Marc-André Lureau @ 2026-09-23 10:07 UTC (permalink / raw)
To: Kevin Wolf; +Cc: qemu-devel
Hi
On Wed, Sep 23, 2026 at 1:37 PM Kevin Wolf <kwolf@redhat.com> wrote:
>
> Am 22.09.2026 um 22:17 hat Marc-André Lureau geschrieben:
> > Hi,
> >
> > This series migrates all qemu-iotests away from HMP, so that the test
> > framework no longer depends on it and can execute with --disable-hmp.
> > This can simplify the tests, as they don't need to check/grep on stdout,
> > HMP & QMP but can rely increasingly on QMP alone.
>
> Hm... Doesn't this mean that HMP loses all of its test coverage? I don't
> feel that's a good idea.
You're right that we shouldn't lose HMP coverage, the question is
where it belongs?
HMP is supposed to be just a frontend to QMP. Imho, testing that
interface is not the scope of qemu-iotests. We should have dedicated
tests for this, and better coverage.
Also, most of what qemu-iotests exercice of HMP is simply qemu-io,
which is the same with QMP.
> Most tests are based on diffing stdout anyway, so I don't expect this
> removal simplifies them much. I'll have to look at the individual
> patches, but I'd rather expect that their output becomes harder to read
> instead.
Yes, if we want "human readable" dumps, it is a bit more verbose in
JSON. But it's often better to have structured output you can test,
instead of bare strings that do not have stability guarantee.
>
> What are the general plans with HMP? Are we expecting most builds to
> have HMP disabled in the future? (Why? It's useful for human users.)
I expect QEMU will keep offering a "human" monitor by default. But QMP
should be a superset, so other "human" interfaces and tools can be
developped with the same functionality it offers.
> I think most tests probably combine testing the HMP interface with
> testing the backend functionality. If we really expect missing HMP to be
> a relevant case in the future, these parts need to be separated so that
> the backend test can run with QMP only while the HMP interface tests run
> only when HMP is available.
>
> Not sure how this is best done without effectively running all tests
> twice. Maybe there is a middle ground of converting some tests to QMP
> and making other tests explicitgly depend on HMP (i.e. they are skipped
> if HMP isn't available).
That could work, but maintaining two variants (or conditional paths)
per test adds burden without improving HMP coverage. The current tests
exercise HMP incidentally, not deliberately. A cleaner split: migrate
qemu-iotests fully to QMP for backend correctness, and add dedicated
HMP tests that intentionally validate the monitor frontend. I will
work on it for the next iteration.
thanks
^ permalink raw reply [flat|nested] 98+ messages in thread
* Re: [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up)
2026-09-22 20:17 [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Marc-André Lureau
` (88 preceding siblings ...)
2026-09-23 9:36 ` [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up) Kevin Wolf
@ 2026-09-23 9:40 ` Kevin Wolf
2026-09-23 19:46 ` Stefan Hajnoczi
89 siblings, 1 reply; 98+ messages in thread
From: Kevin Wolf @ 2026-09-23 9:40 UTC (permalink / raw)
To: Marc-André Lureau; +Cc: qemu-devel, qemu-block, stefanha, hreitz
Am 22.09.2026 um 22:17 hat Marc-André Lureau geschrieben:
> Hi,
>
> This series migrates all qemu-iotests away from HMP, so that the test
> framework no longer depends on it and can execute with --disable-hmp.
> This can simplify the tests, as they don't need to check/grep on stdout,
> HMP & QMP but can rely increasingly on QMP alone.
>
> The series is organized as follows: preparatory patches, monitor
> infrastructure, test infrastructure, test migrations, cleanup.
>
> x-query-qtree (info qtree) is introduced to make test 172 migration
> easier, but arguably, qom-list could be extended instead.
>
> All migrated tests have been verified to pass.
>
> Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Argh, noticed only now that the Cc: list is a bit short. Everyone seeing
only this email, please check the series and my reply on qemu-devel (and
add the necessary CCs when replying).
Please don't forget to CC at least qemu-block for v2.
Kevin
^ permalink raw reply [flat|nested] 98+ messages in thread* Re: [PATCH 00/88] qemu-iotests: migrate away from HMP ("make HMP optional" follow-up)
2026-09-23 9:40 ` Kevin Wolf
@ 2026-09-23 19:46 ` Stefan Hajnoczi
0 siblings, 0 replies; 98+ messages in thread
From: Stefan Hajnoczi @ 2026-09-23 19:46 UTC (permalink / raw)
To: Kevin Wolf; +Cc: Marc-André Lureau, qemu-devel, qemu-block, hreitz
[-- Attachment #1: Type: text/plain, Size: 6450 bytes --]
On Wed, Sep 23, 2026 at 11:40:01AM +0200, Kevin Wolf wrote:
> Am 22.09.2026 um 22:17 hat Marc-André Lureau geschrieben:
> > Hi,
> >
> > This series migrates all qemu-iotests away from HMP, so that the test
> > framework no longer depends on it and can execute with --disable-hmp.
> > This can simplify the tests, as they don't need to check/grep on stdout,
> > HMP & QMP but can rely increasingly on QMP alone.
> >
> > The series is organized as follows: preparatory patches, monitor
> > infrastructure, test infrastructure, test migrations, cleanup.
> >
> > x-query-qtree (info qtree) is introduced to make test 172 migration
> > easier, but arguably, qom-list could be extended instead.
> >
> > All migrated tests have been verified to pass.
> >
> > Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
>
> Argh, noticed only now that the Cc: list is a bit short. Everyone seeing
> only this email, please check the series and my reply on qemu-devel (and
> add the necessary CCs when replying).
Here are the original authors of test cases. I will take a look at the
ones that I wrote but I can help with the leftovers too:
001 Christoph Hellwig
002 Christoph Hellwig
003 Christoph Hellwig
004 Christoph Hellwig
005 Christoph Hellwig
007 Christoph Hellwig
008 Christoph Hellwig
009 Christoph Hellwig
010 Christoph Hellwig
011 Christoph Hellwig
012 Christoph Hellwig
013 Christoph Hellwig
014 Christoph Hellwig
015 Kevin Wolf
017 Kevin Wolf
018 Kevin Wolf
019 Kevin Wolf
020 Kevin Wolf
021 Christoph Hellwig
022 Kevin Wolf
023 Kevin Wolf
024 Kevin Wolf
025 Stefan Hajnoczi
026 Kevin Wolf
027 Stefan Hajnoczi
028 Stefan Hajnoczi
029 Kevin Wolf
030 Stefan Hajnoczi
031 Kevin Wolf
032 Kevin Wolf
033 Paolo Bonzini
034 Kevin Wolf
035 Kevin Wolf
036 Stefan Hajnoczi
037 Kevin Wolf
038 Kevin Wolf
039 Stefan Hajnoczi
040 Jeff Cody
041 Paolo Bonzini
042 Kevin Wolf
043 Stefan Hajnoczi
044 Kevin Wolf
045 Corey Bryant
046 Kevin Wolf
047 Kevin Wolf
048 Miroslav Rezanina
049 Kevin Wolf
050 Paolo Bonzini
051 Kevin Wolf
052 Stefan Hajnoczi
053 Stefan Hajnoczi
054 Kevin Wolf
055 Stefan Hajnoczi
056 Ian Main
057 Wenchao Xia
058 Wenchao Xia
059 Fam Zheng
060 Max Reitz
061 Max Reitz
062 Max Reitz
063 Alexandre Derumier
064 Jeff Cody
065 Max Reitz
066 Max Reitz
068 Max Reitz
069 Max Reitz
070 Jeff Cody
071 Max Reitz
072 Max Reitz
073 Kevin Wolf
074 Fam Zheng
075 Stefan Hajnoczi
076 Kevin Wolf
077 Kevin Wolf
078 Kevin Wolf
079 Hu Tao
080 Kevin Wolf
081 Benoît Canet
082 Kevin Wolf
083 Stefan Hajnoczi
084 Jeff Cody
085 Jeff Cody
086 Kevin Wolf
087 Kevin Wolf
088 Kevin Wolf
089 Max Reitz
090 Max Reitz
091 Jeff Cody
092 Kevin Wolf
093 Fam Zheng
094 Max Reitz
095 Jeff Cody
096 Alberto Garcia
097 Max Reitz
098 Max Reitz
099 Max Reitz
101 Stefan Hajnoczi
102 Max Reitz
103 Max Reitz
104 Hu Tao
105 Fam Zheng
106 Max Reitz
107 Max Reitz
108 Max Reitz
109 Kevin Wolf
110 Max Reitz
111 Max Reitz
112 Max Reitz
113 Max Reitz
114 Kevin Wolf
115 Max Reitz
116 Stefan Hajnoczi
117 Max Reitz
118 Max Reitz
119 Max Reitz
120 Max Reitz
121 Max Reitz
122 Kevin Wolf
123 Max Reitz
124 John Snow
125 Max Reitz
126 Max Reitz
127 Max Reitz
128 Stefan Hajnoczi
129 Fam Zheng
130 Kevin Wolf
131 Denis V. Lunev
132 Fam Zheng
133 Kevin Wolf
134 Daniel P. Berrange
135 Jeff Cody
136 Alberto Garcia
137 Kevin Wolf
138 Max Reitz
139 Alberto Garcia
140 Max Reitz
141 Max Reitz
142 Kevin Wolf
143 Max Reitz
144 Jeff Cody
145 Kevin Wolf
146 Jeff Cody
147 Max Reitz
148 Alberto Garcia
149 Daniel P. Berrange
150 Max Reitz
151 Max Reitz
152 Fam Zheng
153 Fam Zheng
154 Kevin Wolf
155 Max Reitz
156 Max Reitz
157 Kevin Wolf
158 Daniel P. Berrange
159 Reda Sallahi
160 Reda Sallahi
161 Alberto Garcia
162 Max Reitz
163 Pavel Butsykin
165 Vladimir Sementsov-Ogievskiy
170 Reda Sallahi
171 Tomáš Golembiovský
172 Kevin Wolf
173 Jeff Cody
174 Nir Soffer
175 Nir Soffer
176 Daniel P. Berrange
177 Eric Blake
178 Stefan Hajnoczi
179 Eric Blake
181 Kevin Wolf
182 Fam Zheng
184 Manos Pitsidianakis
185 Kevin Wolf
186 Kevin Wolf
187 Kevin Wolf
188 Daniel P. Berrange
189 Daniel P. Berrange
190 Eric Blake
191 Kevin Wolf
192 Fam Zheng
194 Stefan Hajnoczi
195 Kevin Wolf
196 Vladimir Sementsov-Ogievskiy
197 Eric Blake
198 Daniel P. Berrange
200 Jeff Cody
201 Daniel Henrique Barboza
202 Stefan Hajnoczi
203 Stefan Hajnoczi
204 Eric Blake
205 Vladimir Sementsov-Ogievskiy
206 Kevin Wolf
207 Kevin Wolf
208 Stefan Hajnoczi
209 Vladimir Sementsov-Ogievskiy
210 Kevin Wolf
211 Kevin Wolf
212 Kevin Wolf
213 Kevin Wolf
214 Max Reitz
215 Max Reitz
216 Max Reitz
217 Max Reitz
218 Max Reitz
219 Kevin Wolf
220 Eric Blake
221 Eric Blake
223 Eric Blake
224 Max Reitz
225 Max Reitz
226 John Snow
227 Kevin Wolf
228 Max Reitz
229 Jeff Cody
231 Jeff Cody
232 Kevin Wolf
233 Daniel P. Berrangé
234 Kevin Wolf
235 Vladimir Sementsov-Ogievskiy
236 John Snow
237 Kevin Wolf
238 Stefan Hajnoczi
239 yuchenlin
240 Alberto Garcia
241 Eric Blake
242 Andrey Shinkevich
243 Kevin Wolf
244 Kevin Wolf
245 Alberto Garcia
246 John Snow
247 Kevin Wolf
248 Vladimir Sementsov-Ogievskiy
249 Alberto Garcia
250 Vladimir Sementsov-Ogievskiy
251 Max Reitz
252 Max Reitz
253 Max Reitz
254 Vladimir Sementsov-Ogievskiy
255 Kevin Wolf
256 John Snow
257 John Snow
258 Max Reitz
259 Max Reitz
260 Vladimir Sementsov-Ogievskiy
261 Max Reitz
262 Kevin Wolf
263 Maxim Levitsky
264 Vladimir Sementsov-Ogievskiy
265 Max Reitz
266 Max Reitz
267 Kevin Wolf
268 Alberto Garcia
270 Max Reitz
271 Alberto Garcia
272 Max Reitz
273 Kevin Wolf
274 Kevin Wolf
277 Andrey Shinkevich
279 Stefan Hajnoczi
280 Kevin Wolf
281 Sergio Lopez
282 Daniel Henrique Barboza
283 Vladimir Sementsov-Ogievskiy
284 Daniel P. Berrangé
286 Max Reitz
287 Denis Plotnikov
288 Stefan Hajnoczi
289 Max Reitz
290 Alberto Garcia
292 Alberto Garcia
293 Maxim Levitsky
294 Maxim Levitsky
295 Maxim Levitsky
296 Maxim Levitsky
297 Kevin Wolf
298 Vladimir Sementsov-Ogievskiy
299 Vladimir Sementsov-Ogievskiy
300 Max Reitz
301 Eric Blake
302 Nir Soffer
303 Andrey Shinkevich
304 Stefan Reiter
305 Alberto Garcia
307 Kevin Wolf
308 Max Reitz
310 Andrey Shinkevich
312 Alberto Garcia
313 Alberto Garcia
314 Andrey Drobyshev
Stefan
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 98+ messages in thread