Received: from eggs.gnu.org ([2001:4830:134:3::10]:42166) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bGZRi-0007rv-BF for qemu-devel@nongnu.org; Fri, 24 Jun 2016 18:19:31 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bGZRf-0003Yd-3M for qemu-devel@nongnu.org; Fri, 24 Jun 2016 18:19:30 -0400 Received: from mx1.redhat.com ([209.132.183.28]:42329) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bGZRe-0003YJ-Tk for qemu-devel@nongnu.org; Fri, 24 Jun 2016 18:19:27 -0400 Date: Sat, 25 Jun 2016 01:19:22 +0300 From: "Michael S. Tsirkin" Message-ID: <20160625011545-mutt-send-email-mst@redhat.com> References: <1466503372-28334-1-git-send-email-marcandre.lureau@redhat.com> <20160623072807-mutt-send-email-mst@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline In-Reply-To: Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH 00/24] vhost-user reconnect fixes List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: =?iso-8859-1?Q?Marc-Andr=E9?= Lureau Cc: Tetsuya Mukawa , Yuanhan Liu , Victor Kaplansky , jonshin@cisco.com, QEMU On Fri, Jun 24, 2016 at 03:22:19PM +0200, Marc-Andr=E9 Lureau wrote: > Hi >=20 > On Thu, Jun 23, 2016 at 6:31 AM, Michael S. Tsirkin wr= ote: > > > > OK so if it's ok for read or write to fail, then I think > > the callback should just return success. > > This will make sure backends such as vhost net in kernel > > where failure indicates an internal bug are handled > > correctly, while vhost user ignores errors and attempts > > to go on. > > >=20 > That's what we are trying to do, but since it's not yet well defined > how to disconnect/reconnect and there are many bugs around this, it > would help a lot to add error checking and error reporting for now. Just for debugging? OK, how about a macro with #ifdef DEBUG or something like that then? > >> Since there is feature checks on reconnection, qemu should wait for > >> the initial connection feature negotiation to complete. The test add= ed > >> demonstrates this. > > > > > > So on disconnect, we keep the guest going? But then when connect is > > attempted, then we for some reason block guest until negotiation > > is done? Sounds rather strange to me. >=20 > When qemu is the server, it already waits for an initial connection > from vhost-user backend. Here it is just enhanced to wait for the > initial nego to complete, which is necessary for proper device > initialization and also further reconnections checks. OH, it's just for the initial connection? I didn't realize. Will have to re-read it to figure it out. Some comments in commit log and code pointing this out could also help. > --=20 > Marc-Andr=E9 Lureau