From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=32872 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PxKXC-0003il-6D for qemu-devel@nongnu.org; Wed, 09 Mar 2011 09:38:44 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PxKXA-0007oP-Ud for qemu-devel@nongnu.org; Wed, 09 Mar 2011 09:38:41 -0500 Received: from mail-qw0-f45.google.com ([209.85.216.45]:50356) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PxKXA-0007oH-JS for qemu-devel@nongnu.org; Wed, 09 Mar 2011 09:38:40 -0500 Received: by qwj8 with SMTP id 8so499766qwj.4 for ; Wed, 09 Mar 2011 06:38:40 -0800 (PST) Sender: Paolo Bonzini Message-ID: <4D7790EB.1050206@redhat.com> Date: Wed, 09 Mar 2011 15:38:35 +0100 From: Paolo Bonzini MIME-Version: 1.0 References: <1299528642-23631-1-git-send-email-mdroth@linux.vnet.ibm.com> <1299528642-23631-2-git-send-email-mdroth@linux.vnet.ibm.com> <4D778787.1020606@redhat.com> <4D778A95.1000808@linux.vnet.ibm.com> In-Reply-To: <4D778A95.1000808@linux.vnet.ibm.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: [Qemu-devel] Re: [RFC][PATCH v7 01/16] Move code related to fd handlers into utility functions List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Michael Roth Cc: agl@linux.vnet.ibm.com, stefanha@linux.vnet.ibm.com, abeekhof@redhat.com, qemu-devel@nongnu.org, Jes.Sorensen@redhat.com, aliguori@linux.vnet.ibm.com, markus_mueller@de.ibm.com On 03/09/2011 03:11 PM, Michael Roth wrote: > > In the context of virtagent I would agree. The only complication there > being that a large part of the event-driven code (the async read/write > handlers for instance) is shared between virtagent and the host. What exactly? The dependencies in 16/16 give: qemu-tool.o qemu-error.o qemu-sockets.c $(oslib-obj-y) $(trace-obj-y) $(block-obj-y) $(qobject-obj-y) $(version-obj-y) qemu-timer-common.o qemu-timer.o Compared to other tools, only qemu-sockets.c is added (and timers); overall it is quite self contained and interfaces well with glib's GIOChannels, which provide qemu_set_fd_handler-equivalent functionality. In addition, qemu iohandlers have a lot of unwritten assumptions, for example on Win32 they only work with sockets and not other kinds of file descriptors. Paolo