[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 1/2] migration: Reset rather than destroy main_t
From: |
Stafford Horne |
Subject: |
Re: [Qemu-devel] [PATCH 1/2] migration: Reset rather than destroy main_thread_load_event |
Date: |
Sat, 26 Aug 2017 22:55:19 +0900 |
User-agent: |
Mutt/1.8.3 (2017-05-23) |
On Fri, Aug 25, 2017 at 03:19:39PM +0100, Dr. David Alan Gilbert (git) wrote:
> From: "Dr. David Alan Gilbert" <address@hidden>
>
> migration_incoming_state_destroy doesn't really destroy, it cleans up.
> After a loadvm it's called, but the loadvm command can be run twice,
> and so destroying an init-once mutex breaks on the second loadvm.
>
> Reported-by: Stafford Horne <address@hidden>
> Signed-off-by: Dr. David Alan Gilbert <address@hidden>
> ---
> migration/migration.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/migration/migration.c b/migration/migration.c
> index c3fe0ed9ca..a625551ce5 100644
> --- a/migration/migration.c
> +++ b/migration/migration.c
> @@ -167,7 +167,7 @@ void migration_incoming_state_destroy(void)
> mis->from_src_file = NULL;
> }
>
> - qemu_event_destroy(&mis->main_thread_load_event);
> + qemu_event_reset(&mis->main_thread_load_event);
> }
>
> static void migrate_generate_event(int new_state)
For what its worth:
Tested-by: Stafford Horne <address@hidden>
Thanks, I saw the mail from Peter as well, I agree it makes sense to not
call the parent method destroy. But this works for me at the moment.
-Stafford