Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MCbng-0008Bm-Ct for qemu-devel@nongnu.org; Fri, 05 Jun 2009 11:57:48 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MCbnc-0008Al-Ot for qemu-devel@nongnu.org; Fri, 05 Jun 2009 11:57:48 -0400 Received: from [199.232.76.173] (port=48060 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MCbnc-0008Af-Ey for qemu-devel@nongnu.org; Fri, 05 Jun 2009 11:57:44 -0400 Received: from verein.lst.de ([213.95.11.210]:54332) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_3DES_EDE_CBC_SHA1:24) (Exim 4.60) (envelope-from ) id 1MCbnb-00061k-UD for qemu-devel@nongnu.org; Fri, 05 Jun 2009 11:57:44 -0400 Date: Fri, 5 Jun 2009 17:57:39 +0200 From: Christoph Hellwig Subject: Re: [Qemu-devel] [PATCH] fix qemu_aio_flush Message-ID: <20090605155739.GA16012@lst.de> References: <20090528163309.GJ20464@random.random> <20090530100842.GA28053@lst.de> <20090530121709.GA22104@random.random> <20090604112645.GQ25483@random.random> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20090604112645.GQ25483@random.random> List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Andrea Arcangeli Cc: Kevin Wolf , Christoph Hellwig , qemu-devel@nongnu.org On Thu, Jun 04, 2009 at 01:26:45PM +0200, Andrea Arcangeli wrote: > Hello, > > Kevin has good point that when highlevel callback handler completes we > should be guaranteed all underlying layers of callbacks events > completed for that specific aio operation. So it seems the main bug > was only in qemu_aio_flush() (only made visible by the debug code > included in the ide_dma_cancel patch). I guess that's a problem for > savevm/reset that assumes there is no outstanding aio waiting to be > run while in fact there can be because of the bug. Patch is much > simpler as seen below: Yes, this looks better.