[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v4 10/10] migration: block incoming colo when capability is d
|
From: |
Juan Quintela |
|
Subject: |
Re: [PATCH v4 10/10] migration: block incoming colo when capability is disabled |
|
Date: |
Tue, 09 May 2023 20:23:44 +0200 |
|
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) |
Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru> wrote:
> We generally require same set of capabilities on source and target.
> Let's require x-colo capability to use COLO on target.
>
> Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>
Reviewed-by: Juan Quintela <quintela@redhat.com>
I will update the docs as said by lukas.
> ---
> migration/migration.c | 6 ++++++
> 1 file changed, 6 insertions(+)
>
> diff --git a/migration/migration.c b/migration/migration.c
> index 8c5bbf3e94..5e162c0622 100644
> --- a/migration/migration.c
> +++ b/migration/migration.c
> @@ -395,6 +395,12 @@ int migration_incoming_enable_colo(void)
> return -ENOTSUP;
> #endif
>
> + if (!migrate_colo()) {
> + error_report("ENABLE_COLO command come in migration stream, but
> c-colo "
> + "capability is not set");
> + return -EINVAL;
> + }
> +
> if (ram_block_discard_disable(true)) {
> error_report("COLO: cannot disable RAM discard");
> return -EBUSY;