All of lore.kernel.org
 help / color / mirror / Atom feed
From: Kevin Wolf <kwolf@redhat.com>
To: Marcelo Tosatti <mtosatti@redhat.com>
Cc: Stefan Hajnoczi <stefanha@gmail.com>,
	quintela@redhat.com, KVM devel mailing list <kvm@vger.kernel.org>,
	qemu-devel@nongnu.org, Chris Wright <chrisw@redhat.com>,
	Dor Laor <dlaor@redhat.com>, Avi Kivity <avi@redhat.com>
Subject: Re: KVM call agenda for June 28
Date: Thu, 30 Jun 2011 16:52:00 +0200	[thread overview]
Message-ID: <4E0C8D90.8050305@redhat.com> (raw)
In-Reply-To: <20110630143620.GA4366@amt.cnet>

Am 30.06.2011 16:36, schrieb Marcelo Tosatti:
>> 4. Live block copy API and high-level control - the main code that
>> adds the live block copy feature.  Existing patches by Marcelo, can be
>> restructured to use common core by Marcelo.
> 
> Can use your proposed block_stream interface, with a "block_switch"
> command on top, so:
> 
> 1) management creates copy.img with backing file current.img, allows
> access
> 2) management issues "block_switch dev copy.img"
> 3) management issues "block_stream dev base"

Isn't this block_switch command the same as the existing snapshot_blkdev?

> Thought of implementing "block_stream" command by reopening device with
> 
> blkstream:imagename.img
> 
> Then:
> 
> AIO_READ:
> - for each cluster in request:
>     - if allocated-or-in-final-base, read.
>     - check write queue, if present wait on it, if not, add "copy"
>       entry to write queue.
>     - issue cluster sized read from source.
>     - on completion:
>         - copy data to original read buffer, complete it.
>         - if not cancelled, write cluster to destination.
> 
> AIO_WRITE
> for each cluster in request:
>     - check write queue, cancel/wait for "copy" entry.
>     - add "guest" entry to write queue.
>     - issue write to destination.
>     - on completion:
>         - remove write queue entry.
> 
> 
> With the 0...END background read, once it completes write final base
> file for image.
> 
> So block_stream/block_stream_cancel/block_stream_status commands, the
> background read and the rebase -u update can be separate from the block
> driver.

The way how it works looks good to me, I'm just not entirely sure about
the right place to implement it. I think request queueing and copy on
read could be useful outside blkstream, too.

Kevin

WARNING: multiple messages have this Message-ID (diff)
From: Kevin Wolf <kwolf@redhat.com>
To: Marcelo Tosatti <mtosatti@redhat.com>
Cc: Chris Wright <chrisw@redhat.com>,
	KVM devel mailing list <kvm@vger.kernel.org>,
	quintela@redhat.com, Stefan Hajnoczi <stefanha@gmail.com>,
	Dor Laor <dlaor@redhat.com>,
	qemu-devel@nongnu.org, Avi Kivity <avi@redhat.com>
Subject: Re: [Qemu-devel] KVM call agenda for June 28
Date: Thu, 30 Jun 2011 16:52:00 +0200	[thread overview]
Message-ID: <4E0C8D90.8050305@redhat.com> (raw)
In-Reply-To: <20110630143620.GA4366@amt.cnet>

Am 30.06.2011 16:36, schrieb Marcelo Tosatti:
>> 4. Live block copy API and high-level control - the main code that
>> adds the live block copy feature.  Existing patches by Marcelo, can be
>> restructured to use common core by Marcelo.
> 
> Can use your proposed block_stream interface, with a "block_switch"
> command on top, so:
> 
> 1) management creates copy.img with backing file current.img, allows
> access
> 2) management issues "block_switch dev copy.img"
> 3) management issues "block_stream dev base"

Isn't this block_switch command the same as the existing snapshot_blkdev?

> Thought of implementing "block_stream" command by reopening device with
> 
> blkstream:imagename.img
> 
> Then:
> 
> AIO_READ:
> - for each cluster in request:
>     - if allocated-or-in-final-base, read.
>     - check write queue, if present wait on it, if not, add "copy"
>       entry to write queue.
>     - issue cluster sized read from source.
>     - on completion:
>         - copy data to original read buffer, complete it.
>         - if not cancelled, write cluster to destination.
> 
> AIO_WRITE
> for each cluster in request:
>     - check write queue, cancel/wait for "copy" entry.
>     - add "guest" entry to write queue.
>     - issue write to destination.
>     - on completion:
>         - remove write queue entry.
> 
> 
> With the 0...END background read, once it completes write final base
> file for image.
> 
> So block_stream/block_stream_cancel/block_stream_status commands, the
> background read and the rebase -u update can be separate from the block
> driver.

The way how it works looks good to me, I'm just not entirely sure about
the right place to implement it. I think request queueing and copy on
read could be useful outside blkstream, too.

Kevin

  reply	other threads:[~2011-06-30 14:49 UTC|newest]

Thread overview: 55+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-06-27 14:32 KVM call agenda for June 28 Juan Quintela
2011-06-27 14:32 ` [Qemu-devel] " Juan Quintela
2011-06-28 13:38 ` Stefan Hajnoczi
2011-06-28 13:38   ` [Qemu-devel] " Stefan Hajnoczi
2011-06-28 19:41   ` Marcelo Tosatti
2011-06-28 19:41     ` [Qemu-devel] " Marcelo Tosatti
2011-06-29  5:32     ` Stefan Hajnoczi
2011-06-29  5:32       ` [Qemu-devel] " Stefan Hajnoczi
2011-06-29  7:57     ` Kevin Wolf
2011-06-29  7:57       ` [Qemu-devel] " Kevin Wolf
2011-06-29 10:08       ` Stefan Hajnoczi
2011-06-29 10:08         ` [Qemu-devel] " Stefan Hajnoczi
2011-06-29 15:41         ` Marcelo Tosatti
2011-06-29 15:41           ` [Qemu-devel] " Marcelo Tosatti
2011-06-30 11:48           ` Stefan Hajnoczi
2011-06-30 11:48             ` [Qemu-devel] " Stefan Hajnoczi
2011-06-30 12:39             ` Kevin Wolf
2011-06-30 12:39               ` [Qemu-devel] " Kevin Wolf
2011-06-30 12:54           ` Stefan Hajnoczi
2011-06-30 12:54             ` [Qemu-devel] " Stefan Hajnoczi
2011-06-30 14:36             ` Marcelo Tosatti
2011-06-30 14:36               ` [Qemu-devel] " Marcelo Tosatti
2011-06-30 14:52               ` Kevin Wolf [this message]
2011-06-30 14:52                 ` Kevin Wolf
2011-06-30 18:38                 ` Marcelo Tosatti
2011-07-05  8:01                   ` Dor Laor
2011-07-05 12:40                     ` Stefan Hajnoczi
2011-07-05 12:40                       ` Stefan Hajnoczi
2011-07-05 12:58                       ` Marcelo Tosatti
2011-07-05 12:58                         ` Marcelo Tosatti
2011-07-05 13:39                         ` Dor Laor
2011-07-05 13:39                           ` Dor Laor
2011-07-05 14:29                           ` Marcelo Tosatti
2011-07-05 14:29                             ` [Qemu-devel] " Marcelo Tosatti
2011-07-05 14:32                           ` Marcelo Tosatti
2011-07-05 14:32                             ` Marcelo Tosatti
2011-07-05 14:46                             ` Kevin Wolf
2011-07-05 14:46                               ` Kevin Wolf
2011-07-05 15:04                             ` Dor Laor
2011-07-05 15:04                               ` Dor Laor
2011-07-05 15:29                               ` Marcelo Tosatti
2011-07-05 15:29                                 ` Marcelo Tosatti
2011-07-05 15:37                             ` Stefan Hajnoczi
2011-07-05 15:37                               ` Stefan Hajnoczi
2011-07-05 18:18                               ` Marcelo Tosatti
2011-07-05 18:18                                 ` Marcelo Tosatti
2011-07-06  7:48                                 ` Kevin Wolf
2011-07-06  7:48                                   ` Kevin Wolf
2011-07-07 15:25                                 ` Stefan Hajnoczi
2011-07-07 15:25                                   ` Stefan Hajnoczi
2011-06-28 13:43 ` Anthony Liguori
2011-06-28 13:43   ` Anthony Liguori
2011-06-28 13:48   ` Avi Kivity
2011-06-28 13:48     ` Avi Kivity
2011-06-30 14:10     ` Anthony Liguori

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4E0C8D90.8050305@redhat.com \
    --to=kwolf@redhat.com \
    --cc=avi@redhat.com \
    --cc=chrisw@redhat.com \
    --cc=dlaor@redhat.com \
    --cc=kvm@vger.kernel.org \
    --cc=mtosatti@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=quintela@redhat.com \
    --cc=stefanha@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.