All of lore.kernel.org
 help / color / mirror / Atom feed
From: Anthony Liguori <aliguori@us.ibm.com>
To: Stefan Berger <stefanb@linux.vnet.ibm.com>
Cc: qemu-devel@nongnu.org, aliguori@linux.vnet.ibm.com,
	Michael Roth <mdroth@linux.vnet.ibm.com>,
	"Michael S. Tsirkin" <mst@redhat.com>
Subject: Re: [Qemu-devel] [RFC] New Migration Protocol using Visitor	Interface
Date: Wed, 05 Oct 2011 07:54:21 -0500	[thread overview]
Message-ID: <4E8C537D.2090007@us.ibm.com> (raw)
In-Reply-To: <4E8BBB4E.5000907@linux.vnet.ibm.com>

On 10/04/2011 09:05 PM, Stefan Berger wrote:
> On 10/03/2011 09:43 AM, Anthony Liguori wrote:
>> On 10/03/2011 08:24 AM, Michael S. Tsirkin wrote:
>>> On Mon, Oct 03, 2011 at 07:51:00AM -0500, Anthony Liguori wrote:
>>>>> Here are some suggestions:
>>>>>
>>>>> - Let's make the protocol be BER directly.
>>>>> As a first step, use a single octet string for
>>>>> the whole of data. Next, start splitting this up.
>>>>
>>>> This can't be done without breaking the old style migration
>>>> protocol. I don't have a problem with that but I do have a problem
>>>> with repeatedly breaking migration protocol.
>>>
>>> As long as this is within a release cycle, is this a real problem?
>>
>> I think if we try to fit it within a release we'll either end up with a 2 year
>> long release or a half-broken conversion.
>>
>> I'd rather buy ourselves time by supporting both formats. That way we can
>> remove the old format when we're satisfied with the ASN.1 encoding.
> Hm, if backwards compatibility is what we want to achieve (migrating from Qemu
> 1.1 to Qemu 1.0) then at least the ASN.1 decoder / encoder should be all done in
> 1.0, no? Otherwise what would it mean to if 1.0 just skipped types 1.1 sends and
> doesn't understand?

Before we introduce ASN1, we ought to introduce migration capabilities. 
Migration capabilities would be used to negotation ASN.1 over the wire.  That 
means that 1.1 would use the existing protocol to talk to 1.0.

>> There are multiple things to consider with compatibility:
>>
>> 1) Creating compatible device models. This is a qdev problem and can't be
>> solved in the protocol.
>>
>> 2) Ensuring we are sending all the data we need to. I think we solve this
>> problem by autogenerating Visitors from the C definitions of the device
>> structures.
>>
> I would have thought that we would write a function that takes the
> VMStateDescription as an argument and write ASN.1 BER or CER comprising:
> - a header containing the version of the device data
> - the minimum version required to read the device data
> - walk the array of VMStateFields and encode the the device data

Sort of.  You modify VMStateInfo to accept a visitor and name parameter in load 
and put.  Then you write an ASN.1 BER Visitor and pass that visitor to 
VMStateInfo->load/put.

Regards,

Anthony Liguori

>
> and similarly a function for walking the fields for decoding of each device state.
>
> So at least I am surprised to hear 'autogeneration' for this particular case...
>
> Stefan

  reply	other threads:[~2011-10-05 12:55 UTC|newest]

Thread overview: 50+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-19 14:41 [Qemu-devel] [RFC] New Migration Protocol using Visitor Interface Michael Roth
2011-09-19 14:41 ` [Qemu-devel] [RFC 1/8] qapi: add Visitor interfaces for uint*_t and int*_t Michael Roth
2011-09-19 14:41 ` [Qemu-devel] [RFC 2/8] qapi: add QemuFileOutputVisitor Michael Roth
2011-09-19 14:41 ` [Qemu-devel] [RFC 3/8] qapi: add QemuFileInputVisitor Michael Roth
2011-10-24 23:59   ` Chris Krumme
2011-09-19 14:41 ` [Qemu-devel] [RFC 4/8] savevm: move QEMUFile interfaces into qemu-file.c Michael Roth
2011-09-24  7:23   ` Blue Swirl
2011-09-19 14:41 ` [Qemu-devel] [RFC 5/8] qapi: test cases for QEMUFile input/output visitors Michael Roth
2011-09-19 14:41 ` [Qemu-devel] [RFC 6/8] savevm: add QEMUFile->visitor lookup routines Michael Roth
2011-09-19 14:41 ` [Qemu-devel] [RFC 7/8] cutil: add strocat(), to concat a string to an offset in another Michael Roth
2011-09-20 10:43   ` Paolo Bonzini
2011-09-19 14:41 ` [Qemu-devel] [RFC 8/8] slirp: convert save/load function to visitor interface Michael Roth
2011-09-30 13:39   ` Anthony Liguori
2011-09-30 14:08     ` Michael Roth
2011-10-02 20:21 ` [Qemu-devel] [RFC] New Migration Protocol using Visitor Interface Stefan Berger
2011-10-02 21:08   ` Michael S. Tsirkin
2011-10-03 12:55     ` Anthony Liguori
2011-10-03 13:10       ` Stefan Berger
2011-10-03 13:18         ` Anthony Liguori
2011-10-03 13:30           ` Michael S. Tsirkin
2011-10-03 13:48             ` Anthony Liguori
2011-10-03 14:18               ` Michael S. Tsirkin
2011-10-03 14:56                 ` Anthony Liguori
2011-10-03 15:42                   ` Michael S. Tsirkin
2011-10-03 13:38       ` Michael S. Tsirkin
2011-10-03 13:51         ` Anthony Liguori
2011-10-03 14:41           ` Michael S. Tsirkin
2011-10-03 15:00             ` Anthony Liguori
2011-10-03 15:45               ` Michael S. Tsirkin
2011-10-03 16:05                 ` Anthony Liguori
2011-10-03 16:24                   ` Daniel P. Berrange
2011-10-03 16:51                   ` Michael S. Tsirkin
2011-10-05 11:28               ` Michael S. Tsirkin
2011-10-05 12:46                 ` Anthony Liguori
2011-10-03  6:46 ` Michael S. Tsirkin
2011-10-03 12:51   ` Anthony Liguori
2011-10-03 13:24     ` Michael S. Tsirkin
2011-10-03 13:43       ` Anthony Liguori
2011-10-03 14:11         ` Michael S. Tsirkin
2011-10-03 14:42           ` Anthony Liguori
2011-10-03 15:29             ` Michael S. Tsirkin
2011-10-03 15:44               ` Anthony Liguori
2011-10-03 15:58                 ` Michael S. Tsirkin
2011-10-03 16:02                   ` Anthony Liguori
2011-10-03 14:15         ` Michael S. Tsirkin
2011-10-03 14:55           ` Anthony Liguori
2011-10-03 15:41             ` Michael S. Tsirkin
2011-10-05  2:05         ` Stefan Berger
2011-10-05 12:54           ` Anthony Liguori [this message]
2011-10-05 19:06             ` Michael S. Tsirkin

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=4E8C537D.2090007@us.ibm.com \
    --to=aliguori@us.ibm.com \
    --cc=aliguori@linux.vnet.ibm.com \
    --cc=mdroth@linux.vnet.ibm.com \
    --cc=mst@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=stefanb@linux.vnet.ibm.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.