From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NpIlK-0003o5-9U for qemu-devel@nongnu.org; Wed, 10 Mar 2010 05:03:34 -0500 Received: from [199.232.76.173] (port=49313 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NpIlJ-0003nt-Lv for qemu-devel@nongnu.org; Wed, 10 Mar 2010 05:03:33 -0500 Received: from Debian-exim by monty-python.gnu.org with spam-scanned (Exim 4.60) (envelope-from ) id 1NpIlH-0001qU-Qh for qemu-devel@nongnu.org; Wed, 10 Mar 2010 05:03:33 -0500 Received: from mx1.redhat.com ([209.132.183.28]:63755) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NpIlH-0001qQ-DU for qemu-devel@nongnu.org; Wed, 10 Mar 2010 05:03:31 -0500 Received: from int-mx08.intmail.prod.int.phx2.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o2AA3UKu003934 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Wed, 10 Mar 2010 05:03:30 -0500 From: Juan Quintela Date: Wed, 10 Mar 2010 11:03:14 +0100 Message-Id: Subject: [Qemu-devel] [PATCH v2 00/14] Clear fd handlers List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org in this v2 series: - a pony for malc: 23 files changed, 133 insertions(+), 215 deletions(-) - a pony for Anthony fd_read_poll is no more. - tap/qemu-char* poll users are gone. I just folded the poll function on top of the read one. Anyone knows of a different reason that legacy for having a poll function? Only difference should be that we are calling select with more descriptors. - rename qemu_clear_fd_handler() to qemu_remove_fd_handler() It removes it from a list, don't clear anything. - now that pull function is gone, and remove of handler is a diffrent function, only one NULL is used by function -> no more qemu_set_fd_{read,write,poll}_handler, just old qemu_set_fd_handler. Monitor works, and tap works. I don't know if there is any performance difference at all. Could anyone that has a setup to meassure it test it? Later, Juan. v1 series : - convert io_handlers to one QLIST - once there, qemu_set_fd_handlers2() has lots of arguments that are a lot of times NULL. Introduce a set of functions to not have to pass NULL values. - qemu_clear_fd_handlers(): remove it - qemu_set_fd_read_handler(): only read - qemu_set_fd_write_handler(): only write - qemu_set_fd_rw_handler(): read/write - qemu_set_fd_poll_handler(): it was only used for reads and in qemu-char.c. - once there fix bt that don't need poll at all (having a poll function that always return true is the equivalent of not having one). - remove cast to (void *)(unsigned long) for things that already were pointers - IOCanRWHandler is only used for reads -> rename it (almost no users). Juan Quintela (14): Convert io handlers to QLIST remove useless cast rename IOCanRWHandler to IOCanReadHandler bt: remove bt_host_read_poll() Handle deleted IOHandlers in a single buffer tap: insert tap_can_send() into tap_send() qemu-char:stdio insert poll call into read one qemu-char:tcp insert poll call into read one qemu-char:fd insert poll call into read one qemu-char:pty insert poll call into read one qemu-char:udp insert poll call into read one Remove qemu_set_fd_handler2() Remove now unused fd_read_poll and all its only left user Add qemu_remove_fd_handler() aio.c | 2 +- audio/alsaaudio.c | 4 +- audio/ossaudio.c | 6 +- bt-host.c | 9 +---- hw/xen_backend.c | 4 +- migration-exec.c | 7 +-- migration-fd.c | 5 +- migration-tcp.c | 10 ++-- migration-unix.c | 10 ++-- migration.c | 8 ++-- net/socket.c | 6 +- net/tap.c | 27 ++++-------- net/vde.c | 2 +- qemu-aio.h | 4 +- qemu-char.c | 112 ++++++++++++++++---------------------------------- qemu-char.h | 11 +---- qemu-common.h | 2 +- qemu-tool.c | 9 ++-- usb-linux.c | 2 +- vl.c | 92 +++++++++++++++++------------------------- vnc-auth-sasl.c | 2 +- vnc-auth-vencrypt.c | 2 +- vnc.c | 12 +++--- 23 files changed, 133 insertions(+), 215 deletions(-)