lkml.org 
[lkml]   [2007]   [Apr]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Pagecache: find_or_create_page does not call a proper page allocator function
On Mon, 23 Apr 2007, Andrew Morton wrote:

> > +static inline struct page *page_cache_alloc_mask(struct address_space *x,
> > + gfp_t gfp)
> > +{
> > + return __page_cache_alloc(mapping_gfp_mask(x) | gfp);
> > +}
>
> Usually we use the term "mask" to imply an AND function, not an OR
> function.

Well but you pass an allocation mask.... Maybe call this
page_cache_alloc_gfp?

> There are few calls to page_cache_alloc(). Would it not be simpler to just
> add the additional argument to page_cache_alloc() (called "extra_gfp",
> please) and to update all callers? And to remove page_cache_alloc_cold()
> and replace all it callers with page_cache_alloc(mapping, __GFP_COLD)?
>
> The way we actually get rid of an API call instead of adding another one.

Ok. Give me an hour or so.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2007-04-23 23:39    [W:0.065 / U:0.180 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site