From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:44800) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZyGOt-0000ln-Rs for qemu-devel@nongnu.org; Mon, 16 Nov 2015 04:48:40 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZyGOq-0000pd-NB for qemu-devel@nongnu.org; Mon, 16 Nov 2015 04:48:39 -0500 Received: from mx2.suse.de ([195.135.220.15]:59117) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZyGOq-0000pW-H3 for qemu-devel@nongnu.org; Mon, 16 Nov 2015 04:48:36 -0500 References: <1444739866-14798-1-git-send-email-berrange@redhat.com> <1444739866-14798-7-git-send-email-berrange@redhat.com> <5646286B.2030307@suse.de> <56464F8A.3070709@de.ibm.com> <56465533.3030501@suse.de> <56499972.1080103@redhat.com> From: =?UTF-8?Q?Andreas_F=c3=a4rber?= Message-ID: <5649A672.5040605@suse.de> Date: Mon, 16 Nov 2015 10:48:34 +0100 MIME-Version: 1.0 In-Reply-To: <56499972.1080103@redhat.com> Content-Type: text/plain; charset=iso-8859-15 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH v4 6/7] qom: replace object property list with GHashTable List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini Cc: Christian Borntraeger , Pavel Fedin , qemu-devel@nongnu.org, Markus Armbruster , Peter Maydell Am 16.11.2015 um 09:53 schrieb Paolo Bonzini: > On 13/11/2015 22:25, Andreas F=E4rber wrote: >> Thanks! sclp_init() seems to violate several QOM design principles in >> that it uses object_new() during TypeInfo::instance_init() >=20 > There's nothing wrong with that. It's wrong however to use > qdev_set_parent_bus in instance_init. That should be moved to > sclp_realize, before the realized property is set to true. Negative, realize is too late. Since there are two call sites for initialization, I don't see a better place for it. > Otherwise, sclp->event_facility outlives its parent. I'm not sure why > that works only with the list and not with the hash table though. It > may well be a bug in this patch. Luckily that's not the problem here. The unref should account for its lifetime. >> and uses a TYPE_... constant as property name. >=20 > That's just a little weird, it doesn't break anything per se. It risks renaming the type causing the property to change name, which affects ABI stability. Therefore we always "inline" property names. Will adjust after I have a fix. Regards, Andreas --=20 SUSE Linux GmbH, Maxfeldstr. 5, 90409 N=FCrnberg, Germany GF: Felix Imend=F6rffer, Jane Smithard, Graham Norton; HRB 21284 (AG N=FC= rnberg)