qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH 3/3] block: Drain requests in bdrv_close


From: Paolo Bonzini
Subject: Re: [Qemu-devel] [PATCH 3/3] block: Drain requests in bdrv_close
Date: Thu, 12 Apr 2012 19:23:51 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:11.0) Gecko/20120329 Thunderbird/11.0.1

Il 11/04/2012 12:40, Kevin Wolf ha scritto:
> @@ -816,6 +816,8 @@ void bdrv_close(BlockDriverState *bs)
>          if (bs->job) {
>              block_job_cancel_sync(bs->job);
>          }
> +        bdrv_drain_all();

Actually the bdrv_drain_all needs to go first.

This is because block_job_cancel_sync guarantees to exit only after the
block job's own I/O has finished, *but* it needs to see all I/O from the
guest.

Paolo




reply via email to

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