From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:46043) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TALuC-00027K-F0 for qemu-devel@nongnu.org; Sat, 08 Sep 2012 10:21:05 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TALuB-0007oc-DB for qemu-devel@nongnu.org; Sat, 08 Sep 2012 10:21:04 -0400 Received: from e23smtp05.au.ibm.com ([202.81.31.147]:48343) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TALuA-0007oR-Qu for qemu-devel@nongnu.org; Sat, 08 Sep 2012 10:21:03 -0400 Received: from /spool/local by e23smtp05.au.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Sun, 9 Sep 2012 00:20:02 +1000 Received: from d23av04.au.ibm.com (d23av04.au.ibm.com [9.190.235.139]) by d23relay03.au.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id q88EKpeF18022524 for ; Sun, 9 Sep 2012 00:20:56 +1000 Received: from d23av04.au.ibm.com (loopback [127.0.0.1]) by d23av04.au.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id q88EKpTI009187 for ; Sun, 9 Sep 2012 00:20:51 +1000 Date: Sat, 8 Sep 2012 19:52:39 +0530 From: Bharata B Rao Message-ID: <20120908142239.GG20421@in.ibm.com> References: <20120905074106.GA28080@in.ibm.com> <20120905095431.GB28080@in.ibm.com> <50484F63.5050406@redhat.com> <504867A9.3050808@redhat.com> <50486F24.2010106@redhat.com> <504875F6.9090302@redhat.com> <50487881.9030207@redhat.com> <50487B0A.6010908@redhat.com> <20120907150643.GF20421@in.ibm.com> <504A0EA5.2060308@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <504A0EA5.2060308@redhat.com> Subject: Re: [Qemu-devel] [PATCH v6 2/2] block: Support GlusterFS as a QEMU block backend Reply-To: bharata@linux.vnet.ibm.com List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini Cc: Kevin Wolf , Anthony Liguori , Anand Avati , Stefan Hajnoczi , Vijay Bellur , Amar Tumballi , qemu-devel@nongnu.org, Blue Swirl On Fri, Sep 07, 2012 at 05:11:33PM +0200, Paolo Bonzini wrote: > This is a bug that has to be fixed anyway. There are provisions in > aio.c, but they are broken apparently. Can you try this: > > diff --git a/aio.c b/aio.c > index 0a9eb10..99b8b72 100644 > --- a/aio.c > +++ b/aio.c > @@ -119,7 +119,7 @@ bool qemu_aio_wait(void) > return true; > } > > - walking_handlers = 1; > + walking_handlers++; > > FD_ZERO(&rdfds); > FD_ZERO(&wrfds); > @@ -147,7 +147,7 @@ bool qemu_aio_wait(void) > } > } > > - walking_handlers = 0; > + walking_handlers--; > > /* No AIO operations? Get us out of here */ > if (!busy) { > @@ -159,7 +159,7 @@ bool qemu_aio_wait(void) > > /* if we have any readable fds, dispatch event */ > if (ret > 0) { > - walking_handlers = 1; > + walking_handlers++; > > /* we have to walk very carefully in case > * qemu_aio_set_fd_handler is called while we're walking */ > @@ -187,7 +187,7 @@ bool qemu_aio_wait(void) > } > } > > - walking_handlers = 0; > + walking_handlers--; > } > > return true; > This works. I am able to create qcow2 files on gluster backend with this fix. Regards, Bharata.