From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=48477 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Oe6R8-0005iE-AZ for qemu-devel@nongnu.org; Wed, 28 Jul 2010 09:12:43 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1Oe6R6-0002pp-Pf for qemu-devel@nongnu.org; Wed, 28 Jul 2010 09:12:42 -0400 Received: from mail-qw0-f45.google.com ([209.85.216.45]:52308) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Oe6R6-0002pi-Mv for qemu-devel@nongnu.org; Wed, 28 Jul 2010 09:12:40 -0400 Received: by qwi4 with SMTP id 4so918684qwi.4 for ; Wed, 28 Jul 2010 06:12:40 -0700 (PDT) Sender: Paolo Bonzini Message-ID: <4C502CBC.3030005@redhat.com> Date: Wed, 28 Jul 2010 15:12:28 +0200 From: Paolo Bonzini MIME-Version: 1.0 References: In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Subject: [Qemu-devel] Re: [PATCH] vmstate: fix vmstate_subsection_load List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: TeLeMan Cc: qemu-devel , quintela@redhat.com On 07/28/2010 02:51 PM, TeLeMan wrote: > On Wed, Jul 28, 2010 at 20:32, Juan Quintela wrote: >> TeLeMan wrote: >>> On Wed, Jul 28, 2010 at 19:51, Juan Quintela wrote: >>>> I hope this hepls to understand how subsections are supposed to work. >>>> >>>> Thanks for the comments, Juan. >>>> >>> I see, thanks a lot. But I still hope to have the similar subsection >>> that can be ignored simply. >> >> Then it is better not to be sent in the 1st place. >> >> Do you have any example of why you want to do? When I dessigned >> subsections, I looked at all the changes that we had from 0.11 to 0.12, >> subsections can handle all of them. Just curious about what you need.\ >> >> Notice that ignoring subsections at this point is not trivial, as >> (sub)sections don't have a size field. Working on getting size there, >> but it is a long term project (it requires 1st to change everything to >> VMState to be able to change how QEMUFile works). > > I have some extra data to be saved to vmstate and I want the new > vmstate to be compatible with the official version. You are right, I > thought it was simple. Now I discard my thought. Even if they are mandatory, subsections still improve the situation here, because they provide a clean way to "branch" off an upstream vmstate version. At least the failure will be clear, because an unsupported subsection is easily detected when migrating to (or restoring with) upstream. Instead, for example RHEL5.5's "version 9" cpu save format will often crash upstream version 9 with a SIGSEGV.