From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:40960) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1alzhY-0008I7-Qs for qemu-devel@nongnu.org; Fri, 01 Apr 2016 10:05:34 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1alzhT-0004Tw-8r for qemu-devel@nongnu.org; Fri, 01 Apr 2016 10:05:28 -0400 Received: from e06smtp05.uk.ibm.com ([195.75.94.101]:58396) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1alzhS-0004Th-Vs for qemu-devel@nongnu.org; Fri, 01 Apr 2016 10:05:23 -0400 Received: from localhost by e06smtp05.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Fri, 1 Apr 2016 15:05:20 +0100 Received: from b06cxnps4074.portsmouth.uk.ibm.com (d06relay11.portsmouth.uk.ibm.com [9.149.109.196]) by d06dlp01.portsmouth.uk.ibm.com (Postfix) with ESMTP id 0C46E17D87C8 for ; Fri, 1 Apr 2016 15:05:56 +0100 (BST) Received: from d06av01.portsmouth.uk.ibm.com (d06av01.portsmouth.uk.ibm.com [9.149.37.212]) by b06cxnps4074.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id u31E5GnR42860634 for ; Fri, 1 Apr 2016 14:05:17 GMT Received: from d06av01.portsmouth.uk.ibm.com (localhost [127.0.0.1]) by d06av01.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id u31E5GK8001124 for ; Fri, 1 Apr 2016 08:05:16 -0600 Date: Fri, 1 Apr 2016 16:05:15 +0200 From: Cornelia Huck Message-ID: <20160401160515.62e47d60.cornelia.huck@de.ibm.com> In-Reply-To: <1459516794-23629-7-git-send-email-pbonzini@redhat.com> References: <1459516794-23629-1-git-send-email-pbonzini@redhat.com> <1459516794-23629-7-git-send-email-pbonzini@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 6/9] virtio-blk: use aio handler for data plane List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini Cc: famz@redhat.com, borntraeger@de.ibm.com, mst@redhat.com, qemu-devel@nongnu.org, tubo@linux.vnet.ibm.com, stefanha@redhat.com On Fri, 1 Apr 2016 15:19:51 +0200 Paolo Bonzini wrote: > From: "Michael S. Tsirkin" > > In addition to handling IO in vcpu thread and in io thread, dataplane > introduces yet another mode: handling it by aio. > > This reuses the same handler as previous modes, which triggers races as > these were not designed to be reentrant. > > Use a separate handler just for aio, and disable regular handlers when > dataplane is active. > > Signed-off-by: Michael S. Tsirkin > Signed-off-by: Paolo Bonzini > --- > hw/block/dataplane/virtio-blk.c | 13 +++++++++++++ > hw/block/virtio-blk.c | 27 +++++++++++++++++---------- > include/hw/virtio/virtio-blk.h | 2 ++ > 3 files changed, 32 insertions(+), 10 deletions(-) Reviewed-by: Cornelia Huck