From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:54808) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VLWUt-0005fg-6n for qemu-devel@nongnu.org; Mon, 16 Sep 2013 06:57:43 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VLWUo-0000u4-IL for qemu-devel@nongnu.org; Mon, 16 Sep 2013 06:57:39 -0400 Received: from mx1.redhat.com ([209.132.183.28]:59551) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VLWUo-0000tr-As for qemu-devel@nongnu.org; Mon, 16 Sep 2013 06:57:34 -0400 Message-ID: <1379329037.7114.35.camel@nilsson.home.kraxel.org> From: Gerd Hoffmann Date: Mon, 16 Sep 2013 12:57:17 +0200 In-Reply-To: <5236D8EB.9060700@redhat.com> References: <1379314227-8855-1-git-send-email-famz@redhat.com> <1379314227-8855-6-git-send-email-famz@redhat.com> <20130916085902.GA6005@redhat.com> <5236D318.4080206@redhat.com> <20130916095121.GD22783@T430s.nay.redhat.com> <5236D8EB.9060700@redhat.com> Content-Type: text/plain; charset="UTF-8" Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH v10 5/8] module: implement module loading List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini Cc: peter.maydell@linaro.org, famz@redhat.com, mjt@tls.msk.ru, qemu-devel@nongnu.org, alex@alex.org.uk, vilanova@ac.upc.edu, rth@twiddle.net Hi, > With this patch, a module will not be able to use the module_init macro > twice. I am not sure this is an acceptable limitation, especially if we > do not have a dependency system within modules and/or load them with > G_MODULE_LOCAL/RTLD_LOCAL. Exactly. To modularize spice we need either inter-module dependencies, so spice-audio.mo can depend on spice-core.mo etc, or allow multiple module_init calls so we can link all spice components into one big spice.mo module and each component can use module_init. It's not mandatory for the initial revision, we'll need a bit more (like registering monitor commands for 'info spice') so we can actually modularize spice. But it should definitively on the radar for the planning ... cheers, Gerd