qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH] qcow2: Bring synchronous read/write back to lif


From: Jamie Lokier
Subject: Re: [Qemu-devel] [PATCH] qcow2: Bring synchronous read/write back to life
Date: Thu, 8 Oct 2009 16:28:31 +0100
User-agent: Mutt/1.5.13 (2006-08-11)

Kevin Wolf wrote:
> The original bdrv_read would mean that we read some data
> synchronously and that we won't be interrupted during this read. The
> latter assumption is no longer true with the emulation function
> which needs to use qemu_aio_poll and therefore allows the callback
> of any other concurrent AIO request to be run during the read. Which
> in turn means that (meta)data read earlier could have changed and be
> invalid now.

I'm not sure if I understand your description, specifically
"(meta)data read earlier could have changed and be invalid now".

Do you mean:

                                  Async call into qcow2 #2
                                  ------------------------

                                  issues a request with bdrv_read/write

Async call into qcow2 #1
------------------------
reads some metadata from memory (**)
does some calculations
issues a request with bdrv_read/write

                                  the request completes
                                  updates some metadata in memory
                                  async call finished with result

the request completes
updates some metadata in memory
.... ERROR, memory isn't what it was at point (**)

Thanks,
-- Jamie




reply via email to

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