summaryrefslogtreecommitdiffstats
path: root/include/linux/pagemap.h
diff options
context:
space:
mode:
authorMatthew Wilcox (Oracle) <willy@infradead.org>2022-05-01 21:39:29 -0400
committerMatthew Wilcox (Oracle) <willy@infradead.org>2022-05-09 16:36:48 -0400
commite9b5b23e957ef9260fec811d8d8081125889308a (patch)
treec44ca0b4efda7b78ddbb1ebb4b7ce7736704e6c6 /include/linux/pagemap.h
parent6ece0a0452c97fe6cbdce1ff3069248d99f1b4aa (diff)
downloadlinux-stable-e9b5b23e957ef9260fec811d8d8081125889308a.tar.gz
linux-stable-e9b5b23e957ef9260fec811d8d8081125889308a.tar.bz2
linux-stable-e9b5b23e957ef9260fec811d8d8081125889308a.zip
fs: Change the type of filler_t
By making filler_t the same as read_folio, we can use the same function for both in gfs2. We can push the use of folios down one more level in jffs2 and nfs. We also increase type safety for future users of the various read_cache_page() family of functions by forcing the parameter to be a pointer to struct file (or NULL). Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Andreas Gruenbacher <agruenba@redhat.com>
Diffstat (limited to 'include/linux/pagemap.h')
-rw-r--r--include/linux/pagemap.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/include/linux/pagemap.h b/include/linux/pagemap.h
index b70192f56454..831b28dab01a 100644
--- a/include/linux/pagemap.h
+++ b/include/linux/pagemap.h
@@ -492,7 +492,7 @@ static inline gfp_t readahead_gfp_mask(struct address_space *x)
return mapping_gfp_mask(x) | __GFP_NORETRY | __GFP_NOWARN;
}
-typedef int filler_t(void *, struct page *);
+typedef int filler_t(struct file *, struct folio *);
pgoff_t page_cache_next_miss(struct address_space *mapping,
pgoff_t index, unsigned long max_scan);
@@ -747,9 +747,9 @@ static inline struct page *grab_cache_page(struct address_space *mapping,
}
struct folio *read_cache_folio(struct address_space *, pgoff_t index,
- filler_t *filler, void *data);
+ filler_t *filler, struct file *file);
struct page *read_cache_page(struct address_space *, pgoff_t index,
- filler_t *filler, void *data);
+ filler_t *filler, struct file *file);
extern struct page * read_cache_page_gfp(struct address_space *mapping,
pgoff_t index, gfp_t gfp_mask);