iotests: Use -qmp-pretty in 067
067 invokes query-block, resulting in a reference output with really long lines (which may pose a problem in email patches and always poses a problem when the output changes, because it is hard to see what has actually changed). Use -qmp-pretty to mitigate this issue. Signed-off-by: Max Reitz <mreitz@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
This commit is contained in:
parent
cc20b07a42
commit
2389eeae69
|
@ -39,7 +39,7 @@ _supported_os Linux
|
||||||
function do_run_qemu()
|
function do_run_qemu()
|
||||||
{
|
{
|
||||||
echo Testing: "$@"
|
echo Testing: "$@"
|
||||||
$QEMU -nographic -qmp stdio -serial none "$@"
|
$QEMU -nographic -qmp-pretty stdio -serial none "$@"
|
||||||
echo
|
echo
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,77 +4,742 @@ Formatting 'TEST_DIR/t.IMGFMT', fmt=IMGFMT size=134217728
|
||||||
=== -drive/-device and device_del ===
|
=== -drive/-device and device_del ===
|
||||||
|
|
||||||
Testing: -drive file=TEST_DIR/t.qcow2,format=qcow2,if=none,id=disk -device virtio-blk-pci,drive=disk,id=virtio0
|
Testing: -drive file=TEST_DIR/t.qcow2,format=qcow2,if=none,id=disk -device virtio-blk-pci,drive=disk,id=virtio0
|
||||||
QMP_VERSION
|
{
|
||||||
{"return": {}}
|
QMP_VERSION
|
||||||
{"return": [{"io-status": "ok", "device": "disk", "locked": false, "removable": false, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "image": {"virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "lazy-refcounts": false, "corrupt": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "file": "TEST_DIR/t.qcow2", "encryption_key_missing": false}, "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}, {"device": "floppy0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}, {"device": "sd0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}]}
|
}
|
||||||
{"return": {}}
|
{
|
||||||
{"return": {}}
|
"return": {
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "DEVICE_DELETED", "data": {"path": "/machine/peripheral/virtio0/virtio-backend"}}
|
}
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "DEVICE_DELETED", "data": {"device": "virtio0", "path": "/machine/peripheral/virtio0"}}
|
}
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "RESET"}
|
{
|
||||||
{"return": [{"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}, {"device": "floppy0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}, {"device": "sd0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}]}
|
"return": [
|
||||||
{"return": {}}
|
{
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN"}
|
"io-status": "ok",
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "DEVICE_TRAY_MOVED", "data": {"device": "ide1-cd0", "tray-open": true}}
|
"device": "disk",
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "DEVICE_TRAY_MOVED", "data": {"device": "floppy0", "tray-open": true}}
|
"locked": false,
|
||||||
|
"removable": false,
|
||||||
|
"inserted": {
|
||||||
|
"iops_rd": 0,
|
||||||
|
"detect_zeroes": "off",
|
||||||
|
"image": {
|
||||||
|
"virtual-size": 134217728,
|
||||||
|
"filename": "TEST_DIR/t.qcow2",
|
||||||
|
"cluster-size": 65536,
|
||||||
|
"format": "qcow2",
|
||||||
|
"actual-size": SIZE,
|
||||||
|
"format-specific": {
|
||||||
|
"type": "qcow2",
|
||||||
|
"data": {
|
||||||
|
"compat": "1.1",
|
||||||
|
"lazy-refcounts": false,
|
||||||
|
"corrupt": false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"dirty-flag": false
|
||||||
|
},
|
||||||
|
"iops_wr": 0,
|
||||||
|
"ro": false,
|
||||||
|
"backing_file_depth": 0,
|
||||||
|
"drv": "qcow2",
|
||||||
|
"iops": 0,
|
||||||
|
"bps_wr": 0,
|
||||||
|
"encrypted": false,
|
||||||
|
"bps": 0,
|
||||||
|
"bps_rd": 0,
|
||||||
|
"file": "TEST_DIR/t.qcow2",
|
||||||
|
"encryption_key_missing": false
|
||||||
|
},
|
||||||
|
"type": "unknown"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"io-status": "ok",
|
||||||
|
"device": "ide1-cd0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"device": "floppy0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"device": "sd0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"return": {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"return": {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "DEVICE_DELETED",
|
||||||
|
"data": {
|
||||||
|
"path": "/machine/peripheral/virtio0/virtio-backend"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "DEVICE_DELETED",
|
||||||
|
"data": {
|
||||||
|
"device": "virtio0",
|
||||||
|
"path": "/machine/peripheral/virtio0"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "RESET"
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"return": [
|
||||||
|
{
|
||||||
|
"io-status": "ok",
|
||||||
|
"device": "ide1-cd0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"device": "floppy0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"device": "sd0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"return": {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "SHUTDOWN"
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "DEVICE_TRAY_MOVED",
|
||||||
|
"data": {
|
||||||
|
"device": "ide1-cd0",
|
||||||
|
"tray-open": true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "DEVICE_TRAY_MOVED",
|
||||||
|
"data": {
|
||||||
|
"device": "floppy0",
|
||||||
|
"tray-open": true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
=== -drive/device_add and device_del ===
|
=== -drive/device_add and device_del ===
|
||||||
|
|
||||||
Testing: -drive file=TEST_DIR/t.qcow2,format=qcow2,if=none,id=disk
|
Testing: -drive file=TEST_DIR/t.qcow2,format=qcow2,if=none,id=disk
|
||||||
QMP_VERSION
|
{
|
||||||
{"return": {}}
|
QMP_VERSION
|
||||||
{"return": [{"device": "disk", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "image": {"virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "lazy-refcounts": false, "corrupt": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "file": "TEST_DIR/t.qcow2", "encryption_key_missing": false}, "tray_open": false, "type": "unknown"}, {"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}, {"device": "floppy0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}, {"device": "sd0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}]}
|
}
|
||||||
{"return": {}}
|
{
|
||||||
{"return": {}}
|
"return": {
|
||||||
{"return": {}}
|
}
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "DEVICE_DELETED", "data": {"path": "/machine/peripheral/virtio0/virtio-backend"}}
|
}
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "DEVICE_DELETED", "data": {"device": "virtio0", "path": "/machine/peripheral/virtio0"}}
|
{
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "RESET"}
|
"return": [
|
||||||
{"return": [{"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}, {"device": "floppy0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}, {"device": "sd0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}]}
|
{
|
||||||
{"return": {}}
|
"device": "disk",
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN"}
|
"locked": false,
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "DEVICE_TRAY_MOVED", "data": {"device": "ide1-cd0", "tray-open": true}}
|
"removable": true,
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "DEVICE_TRAY_MOVED", "data": {"device": "floppy0", "tray-open": true}}
|
"inserted": {
|
||||||
|
"iops_rd": 0,
|
||||||
|
"detect_zeroes": "off",
|
||||||
|
"image": {
|
||||||
|
"virtual-size": 134217728,
|
||||||
|
"filename": "TEST_DIR/t.qcow2",
|
||||||
|
"cluster-size": 65536,
|
||||||
|
"format": "qcow2",
|
||||||
|
"actual-size": SIZE,
|
||||||
|
"format-specific": {
|
||||||
|
"type": "qcow2",
|
||||||
|
"data": {
|
||||||
|
"compat": "1.1",
|
||||||
|
"lazy-refcounts": false,
|
||||||
|
"corrupt": false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"dirty-flag": false
|
||||||
|
},
|
||||||
|
"iops_wr": 0,
|
||||||
|
"ro": false,
|
||||||
|
"backing_file_depth": 0,
|
||||||
|
"drv": "qcow2",
|
||||||
|
"iops": 0,
|
||||||
|
"bps_wr": 0,
|
||||||
|
"encrypted": false,
|
||||||
|
"bps": 0,
|
||||||
|
"bps_rd": 0,
|
||||||
|
"file": "TEST_DIR/t.qcow2",
|
||||||
|
"encryption_key_missing": false
|
||||||
|
},
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"io-status": "ok",
|
||||||
|
"device": "ide1-cd0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"device": "floppy0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"device": "sd0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"return": {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"return": {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"return": {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "DEVICE_DELETED",
|
||||||
|
"data": {
|
||||||
|
"path": "/machine/peripheral/virtio0/virtio-backend"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "DEVICE_DELETED",
|
||||||
|
"data": {
|
||||||
|
"device": "virtio0",
|
||||||
|
"path": "/machine/peripheral/virtio0"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "RESET"
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"return": [
|
||||||
|
{
|
||||||
|
"io-status": "ok",
|
||||||
|
"device": "ide1-cd0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"device": "floppy0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"device": "sd0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"return": {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "SHUTDOWN"
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "DEVICE_TRAY_MOVED",
|
||||||
|
"data": {
|
||||||
|
"device": "ide1-cd0",
|
||||||
|
"tray-open": true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "DEVICE_TRAY_MOVED",
|
||||||
|
"data": {
|
||||||
|
"device": "floppy0",
|
||||||
|
"tray-open": true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
=== drive_add/device_add and device_del ===
|
=== drive_add/device_add and device_del ===
|
||||||
|
|
||||||
Testing:
|
Testing:
|
||||||
QMP_VERSION
|
{
|
||||||
{"return": {}}
|
QMP_VERSION
|
||||||
{"return": "OK\r\n"}
|
}
|
||||||
{"return": [{"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}, {"device": "floppy0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}, {"device": "sd0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}, {"device": "disk", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "image": {"virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "lazy-refcounts": false, "corrupt": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "file": "TEST_DIR/t.qcow2", "encryption_key_missing": false}, "tray_open": false, "type": "unknown"}]}
|
{
|
||||||
{"return": {}}
|
"return": {
|
||||||
{"return": {}}
|
}
|
||||||
{"return": {}}
|
}
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "DEVICE_DELETED", "data": {"path": "/machine/peripheral/virtio0/virtio-backend"}}
|
{
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "DEVICE_DELETED", "data": {"device": "virtio0", "path": "/machine/peripheral/virtio0"}}
|
"return": "OK\r\n"
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "RESET"}
|
}
|
||||||
{"return": [{"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}, {"device": "floppy0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}, {"device": "sd0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}]}
|
{
|
||||||
{"return": {}}
|
"return": [
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN"}
|
{
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "DEVICE_TRAY_MOVED", "data": {"device": "ide1-cd0", "tray-open": true}}
|
"io-status": "ok",
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "DEVICE_TRAY_MOVED", "data": {"device": "floppy0", "tray-open": true}}
|
"device": "ide1-cd0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"device": "floppy0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"device": "sd0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"device": "disk",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"inserted": {
|
||||||
|
"iops_rd": 0,
|
||||||
|
"detect_zeroes": "off",
|
||||||
|
"image": {
|
||||||
|
"virtual-size": 134217728,
|
||||||
|
"filename": "TEST_DIR/t.qcow2",
|
||||||
|
"cluster-size": 65536,
|
||||||
|
"format": "qcow2",
|
||||||
|
"actual-size": SIZE,
|
||||||
|
"format-specific": {
|
||||||
|
"type": "qcow2",
|
||||||
|
"data": {
|
||||||
|
"compat": "1.1",
|
||||||
|
"lazy-refcounts": false,
|
||||||
|
"corrupt": false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"dirty-flag": false
|
||||||
|
},
|
||||||
|
"iops_wr": 0,
|
||||||
|
"ro": false,
|
||||||
|
"backing_file_depth": 0,
|
||||||
|
"drv": "qcow2",
|
||||||
|
"iops": 0,
|
||||||
|
"bps_wr": 0,
|
||||||
|
"encrypted": false,
|
||||||
|
"bps": 0,
|
||||||
|
"bps_rd": 0,
|
||||||
|
"file": "TEST_DIR/t.qcow2",
|
||||||
|
"encryption_key_missing": false
|
||||||
|
},
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"return": {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"return": {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"return": {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "DEVICE_DELETED",
|
||||||
|
"data": {
|
||||||
|
"path": "/machine/peripheral/virtio0/virtio-backend"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "DEVICE_DELETED",
|
||||||
|
"data": {
|
||||||
|
"device": "virtio0",
|
||||||
|
"path": "/machine/peripheral/virtio0"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "RESET"
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"return": [
|
||||||
|
{
|
||||||
|
"io-status": "ok",
|
||||||
|
"device": "ide1-cd0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"device": "floppy0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"device": "sd0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"return": {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "SHUTDOWN"
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "DEVICE_TRAY_MOVED",
|
||||||
|
"data": {
|
||||||
|
"device": "ide1-cd0",
|
||||||
|
"tray-open": true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "DEVICE_TRAY_MOVED",
|
||||||
|
"data": {
|
||||||
|
"device": "floppy0",
|
||||||
|
"tray-open": true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
=== blockdev_add/device_add and device_del ===
|
=== blockdev_add/device_add and device_del ===
|
||||||
|
|
||||||
Testing:
|
Testing:
|
||||||
QMP_VERSION
|
{
|
||||||
{"return": {}}
|
QMP_VERSION
|
||||||
{"return": {}}
|
}
|
||||||
{"return": [{"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}, {"device": "floppy0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}, {"device": "sd0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}, {"device": "disk", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "image": {"virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "lazy-refcounts": false, "corrupt": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "file": "TEST_DIR/t.qcow2", "encryption_key_missing": false}, "tray_open": false, "type": "unknown"}]}
|
{
|
||||||
{"return": {}}
|
"return": {
|
||||||
{"return": {}}
|
}
|
||||||
{"return": {}}
|
}
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "DEVICE_DELETED", "data": {"path": "/machine/peripheral/virtio0/virtio-backend"}}
|
{
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "DEVICE_DELETED", "data": {"device": "virtio0", "path": "/machine/peripheral/virtio0"}}
|
"return": {
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "RESET"}
|
}
|
||||||
{"return": [{"io-status": "ok", "device": "ide1-cd0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}, {"device": "floppy0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}, {"device": "sd0", "locked": false, "removable": true, "tray_open": false, "type": "unknown"}, {"io-status": "ok", "device": "disk", "locked": false, "removable": true, "inserted": {"iops_rd": 0, "detect_zeroes": "off", "image": {"virtual-size": 134217728, "filename": "TEST_DIR/t.qcow2", "cluster-size": 65536, "format": "qcow2", "actual-size": SIZE, "format-specific": {"type": "qcow2", "data": {"compat": "1.1", "lazy-refcounts": false, "corrupt": false}}, "dirty-flag": false}, "iops_wr": 0, "ro": false, "backing_file_depth": 0, "drv": "qcow2", "iops": 0, "bps_wr": 0, "encrypted": false, "bps": 0, "bps_rd": 0, "file": "TEST_DIR/t.qcow2", "encryption_key_missing": false}, "tray_open": false, "type": "unknown"}]}
|
}
|
||||||
{"return": {}}
|
{
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "SHUTDOWN"}
|
"return": [
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "DEVICE_TRAY_MOVED", "data": {"device": "ide1-cd0", "tray-open": true}}
|
{
|
||||||
{"timestamp": {"seconds": TIMESTAMP, "microseconds": TIMESTAMP}, "event": "DEVICE_TRAY_MOVED", "data": {"device": "floppy0", "tray-open": true}}
|
"io-status": "ok",
|
||||||
|
"device": "ide1-cd0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"device": "floppy0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"device": "sd0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"device": "disk",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"inserted": {
|
||||||
|
"iops_rd": 0,
|
||||||
|
"detect_zeroes": "off",
|
||||||
|
"image": {
|
||||||
|
"virtual-size": 134217728,
|
||||||
|
"filename": "TEST_DIR/t.qcow2",
|
||||||
|
"cluster-size": 65536,
|
||||||
|
"format": "qcow2",
|
||||||
|
"actual-size": SIZE,
|
||||||
|
"format-specific": {
|
||||||
|
"type": "qcow2",
|
||||||
|
"data": {
|
||||||
|
"compat": "1.1",
|
||||||
|
"lazy-refcounts": false,
|
||||||
|
"corrupt": false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"dirty-flag": false
|
||||||
|
},
|
||||||
|
"iops_wr": 0,
|
||||||
|
"ro": false,
|
||||||
|
"backing_file_depth": 0,
|
||||||
|
"drv": "qcow2",
|
||||||
|
"iops": 0,
|
||||||
|
"bps_wr": 0,
|
||||||
|
"encrypted": false,
|
||||||
|
"bps": 0,
|
||||||
|
"bps_rd": 0,
|
||||||
|
"file": "TEST_DIR/t.qcow2",
|
||||||
|
"encryption_key_missing": false
|
||||||
|
},
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"return": {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"return": {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"return": {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "DEVICE_DELETED",
|
||||||
|
"data": {
|
||||||
|
"path": "/machine/peripheral/virtio0/virtio-backend"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "DEVICE_DELETED",
|
||||||
|
"data": {
|
||||||
|
"device": "virtio0",
|
||||||
|
"path": "/machine/peripheral/virtio0"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "RESET"
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"return": [
|
||||||
|
{
|
||||||
|
"io-status": "ok",
|
||||||
|
"device": "ide1-cd0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"device": "floppy0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"device": "sd0",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"io-status": "ok",
|
||||||
|
"device": "disk",
|
||||||
|
"locked": false,
|
||||||
|
"removable": true,
|
||||||
|
"inserted": {
|
||||||
|
"iops_rd": 0,
|
||||||
|
"detect_zeroes": "off",
|
||||||
|
"image": {
|
||||||
|
"virtual-size": 134217728,
|
||||||
|
"filename": "TEST_DIR/t.qcow2",
|
||||||
|
"cluster-size": 65536,
|
||||||
|
"format": "qcow2",
|
||||||
|
"actual-size": SIZE,
|
||||||
|
"format-specific": {
|
||||||
|
"type": "qcow2",
|
||||||
|
"data": {
|
||||||
|
"compat": "1.1",
|
||||||
|
"lazy-refcounts": false,
|
||||||
|
"corrupt": false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"dirty-flag": false
|
||||||
|
},
|
||||||
|
"iops_wr": 0,
|
||||||
|
"ro": false,
|
||||||
|
"backing_file_depth": 0,
|
||||||
|
"drv": "qcow2",
|
||||||
|
"iops": 0,
|
||||||
|
"bps_wr": 0,
|
||||||
|
"encrypted": false,
|
||||||
|
"bps": 0,
|
||||||
|
"bps_rd": 0,
|
||||||
|
"file": "TEST_DIR/t.qcow2",
|
||||||
|
"encryption_key_missing": false
|
||||||
|
},
|
||||||
|
"tray_open": false,
|
||||||
|
"type": "unknown"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"return": {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "SHUTDOWN"
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "DEVICE_TRAY_MOVED",
|
||||||
|
"data": {
|
||||||
|
"device": "ide1-cd0",
|
||||||
|
"tray-open": true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{
|
||||||
|
"timestamp": {
|
||||||
|
"seconds": TIMESTAMP,
|
||||||
|
"microseconds": TIMESTAMP
|
||||||
|
},
|
||||||
|
"event": "DEVICE_TRAY_MOVED",
|
||||||
|
"data": {
|
||||||
|
"device": "floppy0",
|
||||||
|
"tray-open": true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
*** done
|
*** done
|
||||||
|
|
Loading…
Reference in a new issue