From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:47808) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UrOsb-0002T5-IY for qemu-devel@nongnu.org; Tue, 25 Jun 2013 04:45:40 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UrOsX-0004yd-Vm for qemu-devel@nongnu.org; Tue, 25 Jun 2013 04:45:37 -0400 Received: from mx1.redhat.com ([209.132.183.28]:60784) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UrOsX-0004yI-JU for qemu-devel@nongnu.org; Tue, 25 Jun 2013 04:45:33 -0400 Date: Tue, 25 Jun 2013 10:45:27 +0200 From: Stefan Hajnoczi Message-ID: <20130625084527.GD25539@stefanha-thinkpad.redhat.com> References: <1372181185-3595-1-git-send-email-pingfank@linux.vnet.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1372181185-3595-1-git-send-email-pingfank@linux.vnet.ibm.com> Subject: Re: [Qemu-devel] [PATCH v5] QEMUBH: make AioContext's bh re-entrant List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Liu Ping Fan Cc: Kevin Wolf , Paolo Bonzini , qemu-devel@nongnu.org, Anthony Liguori On Wed, Jun 26, 2013 at 01:26:25AM +0800, Liu Ping Fan wrote: > BH will be used outside big lock, so introduce lock to protect > between the writers, ie, bh's adders and deleter. The lock only > affects the writers and bh's callback does not take this extra lock. > Note that for the same AioContext, aio_bh_poll() can not run in > parallel yet. > > Signed-off-by: Liu Ping Fan > > --------- > v4->v5 > fix some grammar issue > v3->v4 > resolve memory order of bh->idle and ->scheduled > add comments for qemu_bh_delete/cancel > --- > async.c | 32 ++++++++++++++++++++++++++++++-- > include/block/aio.h | 7 +++++++ > 2 files changed, 37 insertions(+), 2 deletions(-) Reviewed-by: Stefan Hajnoczi