From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:55485) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VLWXp-0007tW-P8 for qemu-devel@nongnu.org; Mon, 16 Sep 2013 07:00:47 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VLWXi-0001nY-BI for qemu-devel@nongnu.org; Mon, 16 Sep 2013 07:00:41 -0400 Received: from mx1.redhat.com ([209.132.183.28]:63624) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VLWXh-0001nJ-Ux for qemu-devel@nongnu.org; Mon, 16 Sep 2013 07:00:34 -0400 Message-ID: <5236E4C0.5050007@redhat.com> Date: Mon, 16 Sep 2013 13:00:16 +0200 From: Paolo Bonzini MIME-Version: 1.0 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> <1379329037.7114.35.camel@nilsson.home.kraxel.org> In-Reply-To: <1379329037.7114.35.camel@nilsson.home.kraxel.org> Content-Type: text/plain; charset=UTF-8 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: Gerd Hoffmann 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 Il 16/09/2013 12:57, Gerd Hoffmann ha scritto: > 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. We could also have a huge web of shared objects like LibreOffice has (spice-core.so depending on qemu-system.so, and spice.mo depending on spice-core.so), but I'm not really suggesting that... Paolo > 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 > > >