From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:37249) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WsXBO-0002SK-HH for qemu-devel@nongnu.org; Thu, 05 Jun 2014 08:54:23 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WsXBF-0007bp-GP for qemu-devel@nongnu.org; Thu, 05 Jun 2014 08:54:14 -0400 Received: from mail-we0-x233.google.com ([2a00:1450:400c:c03::233]:45564) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WsXBF-0007bO-8h for qemu-devel@nongnu.org; Thu, 05 Jun 2014 08:54:05 -0400 Received: by mail-we0-f179.google.com with SMTP id q59so1021479wes.24 for ; Thu, 05 Jun 2014 05:54:04 -0700 (PDT) Sender: Paolo Bonzini From: Paolo Bonzini Date: Thu, 5 Jun 2014 14:53:57 +0200 Message-Id: <1401972839-25213-1-git-send-email-pbonzini@redhat.com> Subject: [Qemu-devel] [PATCH v2 0/2] block: thread-safety patches for virtio-blk dataplane rerror/werror List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: kwolf@redhat.com, famz@redhat.com, stefanha@redhat.com With virtio-blk dataplane, I/O errors might occur while QEMU is not in the main I/O thread. This makes the block layer's bdrv_error_action() function thread-safe (modulo changes in the monitor to make QMP events thread-safe too, already posted). Thanks to Kevin for discussing v1, the ideas are based on his input too. v1->v2: redone, v1 should really have been an RFC Paolo Bonzini (2): vl: allow other threads to do qemu_system_vmstop_request block: asynchronously stop the VM on I/O errors block.c | 20 ++++++++++-- cpus.c | 1 + docs/qmp/qmp-events.txt | 2 +- include/sysemu/sysemu.h | 1 + stubs/vm-stop.c | 7 +++- target-lm32/op_helper.c | 2 +- vl.c | 85 +++++++++++++++++++++++++++++++------------------ 7 files changed, 82 insertions(+), 36 deletions(-) -- 1.8.3.1