From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:52958) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UDQxj-0002lV-Ke for qemu-devel@nongnu.org; Wed, 06 Mar 2013 21:53:44 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UDQxh-0007Jq-DX for qemu-devel@nongnu.org; Wed, 06 Mar 2013 21:53:43 -0500 Received: from mail-pb0-f51.google.com ([209.85.160.51]:57302) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UDQxh-0007Ja-6F for qemu-devel@nongnu.org; Wed, 06 Mar 2013 21:53:41 -0500 Received: by mail-pb0-f51.google.com with SMTP id un15so6902778pbc.10 for ; Wed, 06 Mar 2013 18:53:40 -0800 (PST) From: Liu Ping Fan Date: Thu, 7 Mar 2013 10:53:15 +0800 Message-Id: <1362624800-10682-1-git-send-email-qemulist@gmail.com> Subject: [Qemu-devel] [PATCH v2 0/5] make netlayer re-entrant List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Stefan Hajnoczi , "Michael S. Tsirkin" , mdroth , Anthony Liguori , Paolo Bonzini From: Liu Ping Fan changes v1->v2 Because the NetQueue is exposed not just from qemu_send_queue_xx(), so separating locks -- use NetQueue(NetQueue->lock) to protect the queue, and use nc->send_lock for the access of nc->peer so we can protect the sender from the remover. Question: Use AioContexts for hub or the raw GSource Liu Ping Fan (5): net: spread hub on AioContexts net: hub use lock to protect ports list net: introduce lock to protect NetQueue net: introduce lock to protect NetClientState's peer's access net: make netclient re-entrant with refcnt hw/qdev-properties-system.c | 15 +++++ include/block/aio.h | 1 + include/net/net.h | 12 ++++ include/net/queue.h | 14 +++++ main-loop.c | 5 ++ net/hub.c | 81 +++++++++++++++++++++++++++-- net/net.c | 122 ++++++++++++++++++++++++++++++++++++++++-- net/queue.c | 19 +++++-- net/slirp.c | 3 +- 9 files changed, 257 insertions(+), 15 deletions(-) -- 1.7.4.4