qemu-block
[Top][All Lists]
Advanced

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

Re: [Qemu-block] [PATCH v2 6/9] jobs: utilize job_exit shim


From: Max Reitz
Subject: Re: [Qemu-block] [PATCH v2 6/9] jobs: utilize job_exit shim
Date: Mon, 27 Aug 2018 12:37:18 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1

On 2018-08-24 00:08, John Snow wrote:
> Utilize the job_exit shim by not calling job_defer_to_main_loop, and
> where applicable, converting the deferred callback into the job_exit
> callback.
> 
> This converts backup, stream, create, and the unit tests all at once.
> Most of these jobs do not see any changes to the order in which they
> clean up their resources, except the test-blockjob-txn test, which
> now puts down its bs before job_completed is called.
> 
> This is safe for the same reason the reordering in the mirror job is
> safe, because job_completed no longer runs under two locks, making
> the unref safe even if it causes a flush.
> 
> Signed-off-by: John Snow <address@hidden>
> ---
>  block/backup.c            | 16 ----------------
>  block/create.c            | 14 +++-----------
>  block/stream.c            | 22 +++++++---------------
>  tests/test-bdrv-drain.c   |  6 ------
>  tests/test-blockjob-txn.c | 11 ++---------
>  tests/test-blockjob.c     | 10 ++++------
>  6 files changed, 16 insertions(+), 63 deletions(-)

Reviewed-by: Max Reitz <address@hidden>

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

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