From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:55512) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QjWF9-0005yA-TM for qemu-devel@nongnu.org; Wed, 20 Jul 2011 08:51:17 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QjWF8-0001OU-3o for qemu-devel@nongnu.org; Wed, 20 Jul 2011 08:51:15 -0400 Received: from mx1.redhat.com ([209.132.183.28]:52115) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QjWF7-0001OP-Kl for qemu-devel@nongnu.org; Wed, 20 Jul 2011 08:51:13 -0400 Message-ID: <4E26CF34.3060708@redhat.com> Date: Wed, 20 Jul 2011 14:51:00 +0200 From: Gerd Hoffmann MIME-Version: 1.0 References: <1311156579-9814-1-git-send-email-kraxel@redhat.com> <1311156579-9814-3-git-send-email-kraxel@redhat.com> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 2/9] vmstate: complain about devices without vmstate List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Maydell Cc: qemu-devel@nongnu.org On 07/20/11 14:40, Peter Maydell wrote: > On 20 July 2011 11:09, Gerd Hoffmann wrote: >> --- a/hw/qdev.c >> +++ b/hw/qdev.c >> @@ -283,7 +283,12 @@ int qdev_init(DeviceState *dev) >> qdev_free(dev); >> return rc; >> } >> - if (dev->info->vmsd) { >> + if (dev->info->vmsd == NULL) { >> + /* TODO: fixup qemu source code, then make this an assert() */ >> + error_report("WARNING: device %s has no vmstate\n", dev->info->name); >> + } else if (dev->info->vmsd == VMSD_NONE) { >> + /* device doesn't need vmstate */; >> + } else { > > I would prefer it if we didn't add this sort of targeted-at-qemu-developers > warning unless there was a reasonable period of time before the next release > where devices which provoke the warning message can be fixed. In particular, > should we postpone putting in the warning message until after 0.15 branches? Agree, makes sense to postpone that one to 0.16-devel, otherwise we'll just bug the users for no reason. Pushed migration.2 branch with that patch dropped. cheers, Gerd