[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v2 6/6] migration/migration.c: Fix hang in ram_save_host_page
From: |
Dr. David Alan Gilbert |
Subject: |
Re: [PATCH v2 6/6] migration/migration.c: Fix hang in ram_save_host_page |
Date: |
Mon, 1 Jun 2020 17:54:44 +0100 |
User-agent: |
Mutt/1.13.4 (2020-02-15) |
* Lukas Straub (lukasstraub2@web.de) wrote:
> migration_rate_limit will erroneously ratelimit a shutdown socket,
> which causes the migration thread to hang in ram_save_host_page
> if the socket is shutdown.
>
> Fix this by explicitly testing if the socket has errors or was
> shutdown in migration_rate_limit.
>
> Signed-off-by: Lukas Straub <lukasstraub2@web.de>
Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
and queued this one (the others in the series are the same as the v1)
> ---
> migration/migration.c | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/migration/migration.c b/migration/migration.c
> index 187ac0410c..e8bd32d48c 100644
> --- a/migration/migration.c
> +++ b/migration/migration.c
> @@ -3347,6 +3347,10 @@ bool migration_rate_limit(void)
> bool urgent = false;
> migration_update_counters(s, now);
> if (qemu_file_rate_limit(s->to_dst_file)) {
> +
> + if (qemu_file_get_error(s->to_dst_file)) {
> + return false;
> + }
> /*
> * Wait for a delay to do rate limiting OR
> * something urgent to post the semaphore.
> --
> 2.20.1
--
Dr. David Alan Gilbert / dgilbert@redhat.com / Manchester, UK
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: [PATCH v2 6/6] migration/migration.c: Fix hang in ram_save_host_page,
Dr. David Alan Gilbert <=