From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:60270) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Wv11j-0003iy-99 for qemu-devel@nongnu.org; Thu, 12 Jun 2014 05:10:36 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Wv11e-0008QM-7Y for qemu-devel@nongnu.org; Thu, 12 Jun 2014 05:10:31 -0400 Received: from mx1.redhat.com ([209.132.183.28]:53095) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Wv11d-0008QI-Vb for qemu-devel@nongnu.org; Thu, 12 Jun 2014 05:10:26 -0400 Message-ID: <1402564219.7148.4.camel@nilsson.home.kraxel.org> From: Gerd Hoffmann Date: Thu, 12 Jun 2014 11:10:19 +0200 In-Reply-To: <1402500316-6894-1-git-send-email-david.marchand@6wind.com> References: <53986E13.4090607@redhat.com> <1402500316-6894-1-git-send-email-david.marchand@6wind.com> Content-Type: text/plain; charset="UTF-8" Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH v2] char: fix avail_connections init in qemu_chr_open_eventfd() List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: David Marchand Cc: pbonzini@redhat.com, cam@cs.ualberta.ca, qemu-devel@nongnu.org, aliguori@amazon.com On Mi, 2014-06-11 at 17:25 +0200, David Marchand wrote: > When trying to use a ivshmem server with qemu, ivshmem init code tries to > create a CharDriverState object for each eventfd retrieved from the server. > To create this object, a call to qemu_chr_open_eventfd() is done. > Right after this, before adding a frontend, qemu_chr_fe_claim_no_fail() is > called. > qemu_chr_open_eventfd() does not set avail_connections to 1, so no frontend can > be associated because qemu_chr_fe_claim_no_fail() makes qemu stop right away. > > This problem comes from 456d60692310e7ac25cf822cc1e98192ad636ece > "qemu-char: Call fe_claim / fe_release when not using qdev chr properties". > > Fix this, by setting avail_connections to 1 in qemu_chr_open_eventfd(). > > Signed-off-by: David Marchand Picked up. cheers, Gerd