From: Eric Van Hensbergen Subject: Re: [PATCH]: v9fs: add readpage support Date: Fri, 13 Jan 2006 16:27:14 -0600 Message-ID: References: <20060111011437.451FD5A809A@localhost.localdomain> <20060111033821.4b3d4d7b.akpm@osdl.org> <20060113141445.14b6469a.akpm@osdl.org> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7BIT Cc: linux-kernel@vger.kernel.org, v9fs-developer@lists.sourceforge.net, linux-fsdevel@vger.kernel.org Return-path: Received: from uproxy.gmail.com ([66.249.92.194]:58613 "EHLO uproxy.gmail.com") by vger.kernel.org with ESMTP id S1423032AbWAMW1Q convert rfc822-to-8bit (ORCPT ); Fri, 13 Jan 2006 17:27:16 -0500 Received: by uproxy.gmail.com with SMTP id s2so70886uge for ; Fri, 13 Jan 2006 14:27:14 -0800 (PST) To: Andrew Morton In-Reply-To: <20060113141445.14b6469a.akpm@osdl.org> Content-Disposition: inline Sender: linux-fsdevel-owner@vger.kernel.org List-Id: linux-fsdevel.vger.kernel.org On 1/13/06, Andrew Morton wrote: > Eric Van Hensbergen wrote: > > > > I went looking for an example of how to do this better. More or less, > > v9fs reads and writes are similar to DirectIO since they don't go > > through the page-cache. > > hm. Why not? > At the moment we'd rather not cache anything with v9fs as it hides operations from the servers, and in the case of synthetic servers it can be a bad thing. There is a somewhat well-understood strategy for how to do cacheing of static files in a sane manner under 9P, but we were holding off on trying to move that into v9fs for the time being. The only reason we added the read-only mmap support back in was to support users who were trying to access executables over 9P connections. > > > > Now, that being said, it still seems to me to be a bit heavy weight -- > > do folks have a better pointer to code that I can use as an example of > > how to do this more efficiently? > > Not really. If that's what you need to do then that's the way to do it. > We've had nasty races and other problems wrt invalidate_inode_pages2 and > pagefaults, so I suggest you test that mix carefully. > > Have you tried fsx-linux? It's really good for finding data integrity > bugs. There's a copy in > http://www.zip.com.au/~akpm/linux/patches/stuff/ext3-tools.tar.gz. > We've been regression testing with vanilla fsx, I'll upgrade to fsx-linux and make sure we are clean. > > I'd suggest that you want the mapping->nrpages test - it'll be a useful > speedup in the common case. > Yeah, as I was tracing through the invalidate_inode_pages2() this morning I realized this is probably a good idea. Should have a new patch to you by the end of the weekend. -eric