Re: [PATCH 03/15] mm: Add file_offset_of_ helpers
From: Matthew Wilcox
Date: Fri Oct 04 2019 - 15:33:05 EST
Your mail program is still broken. This shows up as a reply to the 0/15
email instead of as a reply to the 3/15 email.
On Wed, Oct 02, 2019 at 09:07:53PM +0800, Hillf Danton wrote:
> On Tue, 24 Sep 2019 17:52:02 -0700 From: Matthew Wilcox (Oracle)
> > +/**
> > + * file_offset_of_page - File offset of this page.
> > + * @page: Page cache page.
> > + *
> > + * Context: Any context.
> > + * Return: The offset of the first byte of this page.
> > */
> > -static inline loff_t page_offset(struct page *page)
> > +static inline loff_t file_offset_of_page(struct page *page)
> > {
> > return ((loff_t)page->index) << PAGE_SHIFT;
> > }
> >
> > static inline loff_t page_file_offset(struct page *page)
> > {
> > return ((loff_t)page_index(page)) << PAGE_SHIFT;
>
> Would you like to specify the need to build a moon on the moon,
> with another name though?
I have no idea what you mean. Is this an idiom in your native language,
perhaps?