From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:49358) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YR1qD-0005dw-FG for qemu-devel@nongnu.org; Thu, 26 Feb 2015 12:03:18 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YR1q9-0007bJ-5L for qemu-devel@nongnu.org; Thu, 26 Feb 2015 12:03:13 -0500 Received: from mx2.parallels.com ([199.115.105.18]:50674) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YR1q8-0006PN-WD for qemu-devel@nongnu.org; Thu, 26 Feb 2015 12:03:09 -0500 Message-ID: <54EF5154.5030906@openvz.org> Date: Thu, 26 Feb 2015 20:01:08 +0300 From: "Denis V. Lunev" MIME-Version: 1.0 References: <1422541482-2839-1-git-send-email-den@openvz.org> <1422541482-2839-2-git-send-email-den@openvz.org> <20150219092541.GA19380@redhat.com> <54E5AEA5.8030407@openvz.org> <20150219093941.GB19380@redhat.com> <54E5B0FA.3010505@openvz.org> <20150219101732.GA24499@redhat.com> <54E5B987.9070202@openvz.org> <20150219102927.GA24587@redhat.com> <20150219122618.372cc7e7.cornelia.huck@de.ibm.com> In-Reply-To: <20150219122618.372cc7e7.cornelia.huck@de.ibm.com> Content-Type: text/plain; charset="windows-1252"; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [RESEND PATCH 1/2] balloon: call qdev_alias_all_properties for proxy dev in balloon class init List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Cornelia Huck , "Michael S. Tsirkin" Cc: Christian Borntraeger , qemu-devel@nongnu.org, Raushaniya Maksudova On 19/02/15 14:26, Cornelia Huck wrote: > On Thu, 19 Feb 2015 11:29:27 +0100 > "Michael S. Tsirkin" wrote: > >> On Thu, Feb 19, 2015 at 01:23:03PM +0300, Denis V. Lunev wrote: >>>> The problem is code duplication: all transports need to know >>>> about these balloon-specific property. >>>> Why isn't it handled by virtio_instance_init_common? >>>> >>> why it should? >>> >>> virtio_instance_init_common is common for all virtio devices >>> including VirtIO net, VirtIO block, VirtIO SCSI. Thus the patch >>> move initialization of all common stuff into the common >>> code. >> The problem seems common enough, virtio_instance_init_common >> already works for all properties, why not for these ones? > It only works for the properties that are common amongst transports and > all devices. > > Adding a virtio_balloon_init_common() that adds the guest_stats (or a > virtio_rng_init_common() that adds rng) is probably not a bad idea, but > I'd prefer it as patches on top of these. > ping. Michael, what is the decision?