From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:41599) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XRLTc-0007KM-Rh for qemu-devel@nongnu.org; Tue, 09 Sep 2014 09:29:01 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XRLTX-0001rv-TF for qemu-devel@nongnu.org; Tue, 09 Sep 2014 09:28:56 -0400 Received: from mx1.redhat.com ([209.132.183.28]:23150) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XRLTX-0001rf-Cn for qemu-devel@nongnu.org; Tue, 09 Sep 2014 09:28:51 -0400 Message-ID: <540F008B.9030709@redhat.com> Date: Tue, 09 Sep 2014 15:28:43 +0200 From: Paolo Bonzini MIME-Version: 1.0 References: <1410265809-27247-1-git-send-email-pbonzini@redhat.com> <1410265809-27247-5-git-send-email-pbonzini@redhat.com> <87bnqp2add.fsf@troll.troll> In-Reply-To: <87bnqp2add.fsf@troll.troll> Content-Type: text/plain; charset=iso-8859-15 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 04/10] pcspk: adding vmstate for save/restore List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: quintela@redhat.com Cc: amit.shah@redhat.com, qemu-devel@nongnu.org, Pavel.Dovgaluk@ispras.ru, dgilbert@redhat.com Il 09/09/2014 15:26, Juan Quintela ha scritto: > Paolo Bonzini wrote: >> From: Pavel Dovgalyuk >> >> VMState added by this patch preserves correct >> loading of the PC speaker device state. >> >> This breaks migration to 2.1 and earlier. >> >> Signed-off-by: Pavel Dovgalyuk >> Signed-off-by: Paolo Bonzini > > This should only be added for new machine types, right? We never did that in the past. Maybe downstream. Paolo > Later, Juan. > >> @@ -192,6 +203,7 @@ static void pcspk_class_initfn(ObjectClass *klass, void *data) >> >> dc->realize = pcspk_realizefn; >> set_bit(DEVICE_CATEGORY_SOUND, dc->categories); >> + dc->vmsd = &vmstate_spk; >> dc->props = pcspk_properties; >> /* Reason: pointer property "pit", realize sets global pcspk_state */ >> dc->cannot_instantiate_with_device_add_yet = true;