On 10/3/24 15:46, Peter Krempa wrote:
Changes to v2:
- added few cleanups
- added qemumonitorjson test cases for new commands
- dropped duplicate capability flags
- fixed bugs pointed out in v2
- rewritten logic for selecting snapshot images (both for creation/deletion)
- fixed the logic to be fault tolerant same way as 'delvm'
- allowed internal snapshots of VMs with UEFI
- added explanation to all code with non-obvious implications
Nikolai Barybin via Devel (4):
qemu: monitor: Add plumbing for 'snaphot-save'/'snapshot-delete' QMP
commands
qemu: blockjob: Add job types for 'snapshot-save/delete'
qemu: capabilities: Introduce QEMU_CAPS_SNAPSHOT_INTERNAL_QMP
capability
qemu snapshot: use QMP snapshot-save for internal snapshots creation
Peter Krempa (6):
qemuDomainObjWait: Annotate with G_GNUC_WARN_UNUSED_RESULT
qemu: monitor: Store internal snapshot names from
'query-named-block-nodes'
qemu snapshot: use QMP snapshot-delete for internal snapshots deletion
qemuSnapshotActiveInternalDeleteGetDevices: Add warning when deleting
inconsistent snapshot
qemu: snapshot: Allow internal snapshots with PFLASH nvram
news: mention internal snapshot changes
NEWS.rst | 16 +
src/qemu/qemu_block.c | 2 +
src/qemu/qemu_blockjob.c | 7 +
src/qemu/qemu_blockjob.h | 2 +
src/qemu/qemu_capabilities.c | 4 +
src/qemu/qemu_capabilities.h | 3 +
src/qemu/qemu_domain.c | 10 +
src/qemu/qemu_domain.h | 3 +-
src/qemu/qemu_monitor.c | 30 ++
src/qemu/qemu_monitor.h | 17 +
src/qemu/qemu_monitor_json.c | 79 ++++
src/qemu/qemu_monitor_json.h | 13 +
src/qemu/qemu_snapshot.c | 358 +++++++++++++++++-
tests/qemublocktest.c | 11 +
.../bitmap/snapshots-internal.json | 298 +++++++++++++++
.../bitmap/snapshots-internal.out | 2 +
.../caps_6.0.0_aarch64.xml | 1 +
.../qemucapabilitiesdata/caps_6.0.0_s390x.xml | 1 +
.../caps_6.0.0_x86_64.xml | 1 +
.../caps_6.1.0_x86_64.xml | 1 +
.../caps_6.2.0_aarch64.xml | 1 +
.../qemucapabilitiesdata/caps_6.2.0_ppc64.xml | 1 +
.../caps_6.2.0_x86_64.xml | 1 +
.../caps_7.0.0_aarch64+hvf.xml | 1 +
.../caps_7.0.0_aarch64.xml | 1 +
.../qemucapabilitiesdata/caps_7.0.0_ppc64.xml | 1 +
.../caps_7.0.0_x86_64.xml | 1 +
.../qemucapabilitiesdata/caps_7.1.0_ppc64.xml | 1 +
.../caps_7.1.0_x86_64.xml | 1 +
tests/qemucapabilitiesdata/caps_7.2.0_ppc.xml | 1 +
.../caps_7.2.0_x86_64+hvf.xml | 1 +
.../caps_7.2.0_x86_64.xml | 1 +
.../caps_8.0.0_riscv64.xml | 1 +
.../caps_8.0.0_x86_64.xml | 1 +
.../qemucapabilitiesdata/caps_8.1.0_s390x.xml | 1 +
.../caps_8.1.0_x86_64.xml | 1 +
.../caps_8.2.0_aarch64.xml | 1 +
.../caps_8.2.0_armv7l.xml | 1 +
.../caps_8.2.0_loongarch64.xml | 1 +
.../qemucapabilitiesdata/caps_8.2.0_s390x.xml | 1 +
.../caps_8.2.0_x86_64.xml | 1 +
.../qemucapabilitiesdata/caps_9.0.0_sparc.xml | 1 +
.../caps_9.0.0_x86_64.xml | 1 +
.../caps_9.1.0_riscv64.xml | 1 +
.../caps_9.1.0_x86_64.xml | 1 +
tests/qemumonitorjsontest.c | 33 ++
46 files changed, 895 insertions(+), 22 deletions(-)
create mode 100644 tests/qemublocktestdata/bitmap/snapshots-internal.json
create mode 100644 tests/qemublocktestdata/bitmap/snapshots-internal.out
I reviewed and built all the patches and everything looks fine except
for minor comments I left below.