[libvirt PATCH 7/7] qemu_migration: Implement VIR_MIGRATE_ZEROCOPY flag
Daniel P. Berrangé
berrange at redhat.com
Thu Jun 23 14:08:30 UTC 2022
On Thu, Jun 23, 2022 at 03:58:12PM +0200, Jiri Denemark wrote:
> Resolves: https://gitlab.com/libvirt/libvirt/-/issues/306
>
> Signed-off-by: Jiri Denemark <jdenemar at redhat.com>
> ---
> src/qemu/qemu_migration.c | 21 +++++++++++++++++++++
> src/qemu/qemu_migration.h | 1 +
> src/qemu/qemu_migration_params.c | 6 ++++++
> src/qemu/qemu_migration_params.h | 1 +
> 4 files changed, 29 insertions(+)
>
> diff --git a/src/qemu/qemu_migration.c b/src/qemu/qemu_migration.c
> index 272f1b1b59..02a465f6cb 100644
> --- a/src/qemu/qemu_migration.c
> +++ b/src/qemu/qemu_migration.c
> @@ -2634,6 +2634,12 @@ qemuMigrationSrcBeginPhase(virQEMUDriver *driver,
> }
> }
>
> + if (flags & VIR_MIGRATE_ZEROCOPY && !(flags & VIR_MIGRATE_PARALLEL)) {
> + virReportError(VIR_ERR_OPERATION_INVALID, "%s",
> + _("zero-copy is only available for parallel migration"));
> + return NULL;
> + }
It is also not compatible with compression, or TLS.
> diff --git a/src/qemu/qemu_migration_params.c b/src/qemu/qemu_migration_params.c
> index 4e83d8d8bd..cc66ed8229 100644
> --- a/src/qemu/qemu_migration_params.c
> +++ b/src/qemu/qemu_migration_params.c
> @@ -94,6 +94,7 @@ VIR_ENUM_IMPL(qemuMigrationCapability,
> "multifd",
> "dirty-bitmaps",
> "return-path",
> + "zero-copy-send",
> );
Note the QEMU name was picked in case we later get zero copy
receive, as a separately enabled feature.
With regards,
Daniel
--
|: https://berrange.com -o- https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org -o- https://fstop138.berrange.com :|
|: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|
More information about the libvir-list
mailing list