From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LB8wc-0002C0-3Z for qemu-devel@nongnu.org; Fri, 12 Dec 2008 09:24:42 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LB8wb-0002Bj-Jj for qemu-devel@nongnu.org; Fri, 12 Dec 2008 09:24:41 -0500 Received: from [199.232.76.173] (port=47053 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LB8wb-0002Bd-El for qemu-devel@nongnu.org; Fri, 12 Dec 2008 09:24:41 -0500 Received: from mx2.redhat.com ([66.187.237.31]:51753) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1LB8wb-00032Y-1l for qemu-devel@nongnu.org; Fri, 12 Dec 2008 09:24:41 -0500 Date: Fri, 12 Dec 2008 15:24:35 +0100 From: Andrea Arcangeli Subject: Re: [Qemu-devel] [RFC] Replace posix-aio with custom thread pool Message-ID: <20081212142435.GL6809@random.random> References: <1228512061-25398-1-git-send-email-aliguori@us.ibm.com> <493E941D.4000608@redhat.com> <493E965E.5050701@us.ibm.com> <20081210164401.GF18814@random.random> <493FFAB6.2000106@codemonkey.ws> <493FFC8E.9080802@redhat.com> <49400F69.8080707@codemonkey.ws> <20081210190810.GG18814@random.random> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20081210190810.GG18814@random.random> Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Anthony Liguori Cc: Gerd Hoffmann , kvm-devel , qemu-devel@nongnu.org On Wed, Dec 10, 2008 at 08:08:10PM +0100, Andrea Arcangeli wrote: > On Wed, Dec 10, 2008 at 12:50:17PM -0600, Anthony Liguori wrote: > > But opening twice means that you lose coherency with NFS. > > Not sure why. They're not running from different nfs clients. If this I just got confirmation from Trond that from nfs point of view, opening the file multiple times or duping it, is the same as I expected (all it matters is that the inode is the same so the pagecache radix tree is the same etc..). So opening the file each time a thread starts, would provide a local f_pos and it would work fine on older/current kernels too. In theory other nfs clients should also behave. Not sure what's best, if to hack around the bdrv api and open the file multiple times or wait for preadv/pwritev.