From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:47034) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ag8PS-0007Lx-P6 for qemu-devel@nongnu.org; Wed, 16 Mar 2016 06:10:39 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ag8PN-0005e5-6h for qemu-devel@nongnu.org; Wed, 16 Mar 2016 06:10:34 -0400 From: Fam Zheng Date: Wed, 16 Mar 2016 18:10:14 +0800 Message-Id: <1458123018-18651-1-git-send-email-famz@redhat.com> Subject: [Qemu-devel] [PATCH 0/4] Tweaks around virtio-blk start/stop List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Kevin Wolf , qemu-block@nongnu.org, "Michael S. Tsirkin" , tubo@linux.vnet.ibm.com, Stefan Hajnoczi , cornelia.huck@de.ibm.com, pbonzini@redhat.com, borntraeger@de.ibm.com These are some ideas originated from analyzing the Christian's crash report on virtio-blk dataplane torture test: https://lists.gnu.org/archive/html/qemu-devel/2016-03/msg02093.html The ideas are mostly inspired/suggested by Paolo. This doesn't fix the bug, but the first and the last patches seem to make the crash less frequent. Also thanks Cornelia Huck for reviewing the draft version posted in that thread. Fam Zheng (4): block: Use drained section in bdrv_set_aio_context block-backend: Introduce blk_drained_begin/end virtio-blk: Use blk_drained_begin/end around dataplane stop virtio-blk: Clean up start/stop with mutex and BH block.c | 4 ++- block/block-backend.c | 14 ++++++++++ hw/block/dataplane/virtio-blk.c | 58 +++++++++++++++++++++++++++++++---------- hw/block/virtio-blk.c | 3 ++- include/sysemu/block-backend.h | 2 ++ 5 files changed, 65 insertions(+), 16 deletions(-) -- 2.4.3