[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <YPcOAADVC2ta+7Zh@casper.infradead.org>
Date: Tue, 20 Jul 2021 18:55:12 +0100
From: Matthew Wilcox <willy@...radead.org>
To: Mike Rapoport <rppt@...nel.org>
Cc: linux-kernel@...r.kernel.org, linux-mm@...ck.org,
linux-fsdevel@...r.kernel.org, Christoph Hellwig <hch@....de>,
Jeff Layton <jlayton@...nel.org>,
"Kirill A . Shutemov" <kirill.shutemov@...ux.intel.com>,
Vlastimil Babka <vbabka@...e.cz>,
William Kucharski <william.kucharski@...cle.com>,
David Howells <dhowells@...hat.com>
Subject: Re: [PATCH v14 014/138] mm/filemap: Add folio_next_index()
On Tue, Jul 20, 2021 at 01:42:11PM +0300, Mike Rapoport wrote:
> > diff --git a/include/linux/pagemap.h b/include/linux/pagemap.h
> > index f7c165b5991f..bd0e7e91bfd4 100644
> > --- a/include/linux/pagemap.h
> > +++ b/include/linux/pagemap.h
> > @@ -406,6 +406,17 @@ static inline pgoff_t folio_index(struct folio *folio)
> > return folio->index;
> > }
> >
> > +/**
> > + * folio_next_index - Get the index of the next folio.
> > + * @folio: The current folio.
> > + *
> > + * Return: The index of the folio which follows this folio in the file.
> > + */
>
> Maybe note that index is in units of pages?
I don't think this is the place to explain that. Remember, we already
have:
* @index: Offset within the file, in units of pages. For anonymous pages,
* this is the index from the beginning of the mmap.
and I don't want to explain every term of art in every function
description. I think if you're reading this, you can follow the
link to the struct folio description and see what an index is.
Powered by blists - more mailing lists