From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:49973) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ws77g-00026s-Ho for qemu-devel@nongnu.org; Wed, 04 Jun 2014 05:04:47 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Ws77U-0002cp-UH for qemu-devel@nongnu.org; Wed, 04 Jun 2014 05:04:40 -0400 Received: from mx1.redhat.com ([209.132.183.28]:27582) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ws77U-0002cf-MB for qemu-devel@nongnu.org; Wed, 04 Jun 2014 05:04:28 -0400 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id s5494RMe017298 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Wed, 4 Jun 2014 05:04:28 -0400 Message-ID: <538EE118.7060407@redhat.com> Date: Wed, 04 Jun 2014 11:04:24 +0200 From: Paolo Bonzini MIME-Version: 1.0 References: <1401804987-31085-1-git-send-email-pbonzini@redhat.com> <20140603143719.GD3264@noname.str.redhat.com> <538DEF19.80802@redhat.com> <20140604082831.GB3851@noname.str.redhat.com> In-Reply-To: <20140604082831.GB3851@noname.str.redhat.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH] block: asynchronously stop the VM on I/O errors List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Kevin Wolf Cc: famz@redhat.com, qemu-devel@nongnu.org, stefanha@redhat.com Il 04/06/2014 10:28, Kevin Wolf ha scritto: >> Breaking this invariant means that you have a very small window where >> {'execute':'cont'} would actually not restart the VM. I think this >> should be fixed by dropping the request in vm_start, like this: >> [...] > > Sounds like an option. Do we need to send a QEVENT_STOP/QEVENT_RESUME > pair? If we don't, the client will still notice a difference to a real > stop and resume. Yes, better do that. >> Also, I think that bdrv_emit_qmp_error_event is placed wrong. >> It should be called only after setting the iostatus, otherwise >> there is a small window where the iostatus is "no error" but >> the event has been generated already. > > Yes, I agree. > > The documentation for this event actually answers my above question: > > Note: If action is "stop", a STOP event will eventually follow the > BLOCK_IO_ERROR event. > > Perhaps we should also change the documentation of the "stop" value to > clarify that the VM may not actually be stopped yet. It currently reads > like this: > > "stop": error caused VM to be stopped Yes. Paolo