From: Peter Krempa Date: Wed, 12 Mar 2025 16:08:33 +0000 (+0100) Subject: qemu: domain: Remove qemuDomainSupportsCheckpointsBlockjobs X-Git-Tag: v11.2.0-rc1~152 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=eb27abb4159c18c7a5c8e63c8a03755157f023b5;p=thirdparty%2Flibvirt.git qemu: domain: Remove qemuDomainSupportsCheckpointsBlockjobs The function now serves no real purpose. Signed-off-by: Peter Krempa Reviewed-by: Ján Tomko --- diff --git a/src/qemu/qemu_block.c b/src/qemu/qemu_block.c index 76e7f4ca83..2468725bf7 100644 --- a/src/qemu/qemu_block.c +++ b/src/qemu/qemu_block.c @@ -3592,9 +3592,6 @@ qemuBlockCommit(virDomainObj *vm, if (qemuDomainDiskBlockJobIsActive(disk)) return NULL; - if (qemuDomainSupportsCheckpointsBlockjobs(vm) < 0) - return NULL; - if (topSource == disk->src) { /* XXX Should we auto-pivot when COMMIT_ACTIVE is not specified? */ if (!(flags & VIR_DOMAIN_BLOCK_COMMIT_ACTIVE)) { diff --git a/src/qemu/qemu_domain.c b/src/qemu/qemu_domain.c index ea29765c61..29fac0034e 100644 --- a/src/qemu/qemu_domain.c +++ b/src/qemu/qemu_domain.c @@ -10169,20 +10169,6 @@ qemuDomainDefHasManagedPR(virDomainObj *vm) } -/** - * qemuDomainSupportsCheckpointsBlockjobs: - * @vm: domain object - * - * Checks whether a block job is supported in possible combination with - * checkpoints (qcow2 bitmaps). Returns -1 if unsupported and reports an error - * 0 in case everything is supported. - */ -int -qemuDomainSupportsCheckpointsBlockjobs(virDomainObj *vm G_GNUC_UNUSED) -{ - return 0; -} - /** * qemuDomainInitializePflashStorageSource: * diff --git a/src/qemu/qemu_domain.h b/src/qemu/qemu_domain.h index 04577f1297..8e53a270a7 100644 --- a/src/qemu/qemu_domain.h +++ b/src/qemu/qemu_domain.h @@ -1053,10 +1053,6 @@ int qemuDomainValidateActualNetDef(const virDomainNetDef *net, virQEMUCaps *qemuCaps); -int -qemuDomainSupportsCheckpointsBlockjobs(virDomainObj *vm) - G_GNUC_WARN_UNUSED_RESULT; - int qemuDomainMakeCPUMigratable(virArch arch, virCPUDef *cpu, diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c index f974d2fba8..af5445f78d 100644 --- a/src/qemu/qemu_driver.c +++ b/src/qemu/qemu_driver.c @@ -13624,9 +13624,6 @@ qemuDomainBlockPullCommon(virDomainObj *vm, if (virDomainObjCheckActive(vm) < 0) goto endjob; - if (qemuDomainSupportsCheckpointsBlockjobs(vm) < 0) - goto endjob; - if (!(disk = qemuDomainDiskByName(vm->def, path))) goto endjob; @@ -14150,9 +14147,6 @@ qemuDomainBlockCopyCommon(virDomainObj *vm, if (virDomainObjCheckActive(vm) < 0) goto endjob; - if (qemuDomainSupportsCheckpointsBlockjobs(vm) < 0) - goto endjob; - if (!(disk = qemuDomainDiskByName(vm->def, path))) goto endjob; diff --git a/src/qemu/qemu_snapshot.c b/src/qemu/qemu_snapshot.c index 9556bd1216..9c2ab47c51 100644 --- a/src/qemu/qemu_snapshot.c +++ b/src/qemu/qemu_snapshot.c @@ -1082,7 +1082,6 @@ qemuSnapshotPrepare(virDomainObj *vm, } /* Handle interlocking with 'checkpoints': - * - if the VM is online use qemuDomainSupportsCheckpointsBlockjobs * - if the VM is offline disallow external snapshots as the support for * propagating bitmaps into the would-be-created overlay is not yet implemented */ @@ -1093,9 +1092,6 @@ qemuSnapshotPrepare(virDomainObj *vm, _("support for offline external snapshots while checkpoint exists was not yet implemented")); return -1; } - } else { - if (qemuDomainSupportsCheckpointsBlockjobs(vm) < 0) - return -1; } /* Alter flags to let later users know what we learned. */