lkml.org 
[lkml]   [2011]   [May]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 4/14] tmpfs: add shmem_read_mapping_page_gfp
> (shmem_read_mapping_page_gfp or shmem_read_cache_page_gfp?  Generally
> the read_mapping_page functions use the mapping's ->readpage, and the
> read_cache_page functions use the supplied filler, so I think
> read_cache_page_gfp was slightly misnamed.)

What about just shmem_read_page? It's not using the pagecache, so
no need for the mapping or cache, and the _gfp really is just a hack
because the old pagecache APIs didn't allow to pass the gfp flags.
For a new API there's no need for that.

> +static inline struct page *shmem_read_mapping_page(
> + struct address_space *mapping, pgoff_t index)
> +{
> + return shmem_read_mapping_page_gfp(mapping, index,
> + mapping_gfp_mask(mapping));
> +}

This really shouldn't be in pagemap.h. For now probably in shmem_fs.h



\
 
 \ /
  Last update: 2011-06-01 02:45    [from the cache]
©2003-2014 Jasper Spaans. Advertise on this site