From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:39940) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RbYVJ-0003qE-Ol for qemu-devel@nongnu.org; Fri, 16 Dec 2011 09:11:23 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RbYV9-0004s0-L3 for qemu-devel@nongnu.org; Fri, 16 Dec 2011 09:11:17 -0500 Received: from mail-iy0-f173.google.com ([209.85.210.173]:51922) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RbYV9-0004ru-CV for qemu-devel@nongnu.org; Fri, 16 Dec 2011 09:11:07 -0500 Received: by iagj37 with SMTP id j37so5036284iag.4 for ; Fri, 16 Dec 2011 06:11:06 -0800 (PST) Message-ID: <4EEB5175.8070507@codemonkey.ws> Date: Fri, 16 Dec 2011 08:11:01 -0600 From: Anthony Liguori MIME-Version: 1.0 References: <1323721784-704-1-git-send-email-aliguori@us.ibm.com> <4EEA3813.80006@us.ibm.com> <4EEB1277.4070803@redhat.com> <4EEB1ABB.50204@redhat.com> <4EEB1F3B.8070302@redhat.com> <4EEB3891.2020003@redhat.com> <4EEB4CD1.7050701@us.ibm.com> <4EEB4D38.6050200@redhat.com> In-Reply-To: <4EEB4D38.6050200@redhat.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH v3 00/20] qom: dynamic properties and composition tree List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini Cc: Kevin Wolf , Peter Maydell , Anthony Liguori , Stefan Hajnoczi , Jan Kiszka , qemu-devel@nongnu.org, Luiz Capitulino , Markus Armbruster On 12/16/2011 07:52 AM, Paolo Bonzini wrote: > On 12/16/2011 02:51 PM, Anthony Liguori wrote: >> struct ISASerial { >> Device parent; >> >> UART _child uart; >> ISABus _link *bus; >> }; >> >> A child should be able to be part of the parent devices memory with its >> life cycle bound to the parents life cycle. This is why a child >> property shouldn't be nullable. > > 100% agreed in principle. > > But technically, if you do not make them pointers how do you handle children > that, for some reason (broken reference counting for example) outlive the > parent? Aborting could be a very good answer. :) Yes, aborting would be the answer. Regards, Anthony Liguori > > Paolo >