From: Nick Piggin Subject: Re: [rfc][patch 3/5] afs: new aops Date: Wed, 14 Nov 2007 22:32:10 +0100 Message-ID: <20071114213210.GB31048@wotan.suse.de> References: <20071114042420.GF557@wotan.suse.de> <20071113004459.GE30650@wotan.suse.de> <20071113001548.GA30650@wotan.suse.de> <20071112071448.GE22953@wotan.suse.de> <20071112071245.GB22953@wotan.suse.de> <6161.1194881354@redhat.com> <17445.1194913805@redhat.com> <18637.1194951385@redhat.com> <30440.1195042723@redhat.com> <22543.1195055866@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Andrew Morton , linux-fsdevel@vger.kernel.org, mhalcrow@us.ibm.com, phillip@hellewell.homeip.net, sfrench@samba.org To: David Howells Return-path: Received: from mx2.suse.de ([195.135.220.15]:42168 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755155AbXKNVcP (ORCPT ); Wed, 14 Nov 2007 16:32:15 -0500 Content-Disposition: inline In-Reply-To: <22543.1195055866@redhat.com> Sender: linux-fsdevel-owner@vger.kernel.org List-Id: linux-fsdevel.vger.kernel.org On Wed, Nov 14, 2007 at 03:57:46PM +0000, David Howells wrote: > Nick Piggin wrote: > > > In core code, the PAGE_CACHE_SIZE is for page cache struct pages. Single > > struct pages (not page arrays). Take a look at generic mapping read or > > something. > > So you're saying a struct page controls an area of PAGE_CACHE_SIZE, not an > area of PAGE_SIZE? No, a pagecache page is PAGE_CACHE_SIZE. And not all struct pages control the same amount of data anyway, with compound pages. > Is a struct page then a purely pagecache concept? > > > Documentation is the opposite of convention ;) > > If it's not Documented, then it's irrelevant. But you can't just decide yourself that it is irrelevant because you don't grep hard enough ;) include/linux/mm.h: * A page may belong to an inode's memory mapping. In this case, page->mapping * is the pointer to the inode, and page->index is the file offset of the page, * in units of PAGE_CACHE_SIZE. include/linux/mm_types.h unsigned long vm_pgoff; /* Offset (within vm_file) in PAGE_SIZE units, *not* PAGE_CACHE_SIZE */ Looks like documentation to me.