[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] runstate: ignore finishmigrate -> prelaunch transition

From: Juan Quintela
Subject: Re: [PATCH] runstate: ignore finishmigrate -> prelaunch transition
Date: Wed, 08 Jan 2020 13:39:36 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux)

Laurent Vivier <address@hidden> wrote:
> Ping?
> Thanks,
> Laurent
> On 12/12/2019 20:40, Laurent Vivier wrote:
>> On 06/12/2019 20:52, Dr. David Alan Gilbert wrote:
>>> * Laurent Vivier (address@hidden) wrote:
>>>> Commit 1bd71dce4bf2 tries to prevent a finishmigrate -> prelaunch
>>>> transition by exiting at the beginning of the main_loop_should_exit()
>>>> function if the state is already finishmigrate.
>>>> As the finishmigrate state is set in the migration thread it can
>>>> happen concurrently to the function. The migration thread and the
>>>> function are normally protected by the iothread mutex and thus the
>>>> state should no evolve between the start of the function and its end.
>>>> Unfortunately during the function life the lock is released by
>>>> pause_all_vcpus() just before the point we need to be sure we are
>>>> not in finishmigrate state and if the migration thread is waiting
>>>> for the lock it will take the opportunity to change the state
>>>> to finishmigrate.
>>> Ewww.
>>> I hate those short wakeups for pause_all_vcpus; I'm sure there are loads
>>> more corners that break.
>>> Still, I _think_ this is an improvement, so:
>>> Reviewed-by: Dr. David Alan Gilbert <address@hidden>
>> Who volunteers to take this in his queue?

Reviewed-by: Juan Quintela <address@hidden>


reply via email to

[Prev in Thread] Current Thread [Next in Thread]