47 lines
1.5 KiB
Diff
47 lines
1.5 KiB
Diff
From: Ben Hutchings <ben@decadent.org.uk>
|
|
Date: Tue, 24 Feb 2015 20:05:05 +0000
|
|
Subject: mm: Fix pagecache_get_page() ABI change in 3.16.7-ckt6
|
|
Forwarded: not-needed
|
|
|
|
The last parameter to pagecache_get_page() was dropped, as some
|
|
callers passed the wrong value and it is really redundant.
|
|
|
|
As most filesystems need this function, we should keep the old
|
|
function signature for OOT modules. Rename the function, add a
|
|
wrapper with the old name and parameters, and add a macro to make all
|
|
new callers use the new function.
|
|
|
|
---
|
|
--- a/include/linux/pagemap.h
|
|
+++ b/include/linux/pagemap.h
|
|
@@ -267,7 +267,12 @@ pgoff_t page_cache_prev_hole(struct addr
|
|
#define FGP_NOWAIT 0x00000020
|
|
|
|
struct page *pagecache_get_page(struct address_space *mapping, pgoff_t offset,
|
|
- int fgp_flags, gfp_t cache_gfp_mask);
|
|
+ int fgp_flags, gfp_t cache_gfp_mask,
|
|
+ gfp_t radix_gfp_mask);
|
|
+struct page *
|
|
+pagecache_get_page_fixed(struct address_space *mapping, pgoff_t offset,
|
|
+ int fgp_flags, gfp_t cache_gfp_mask);
|
|
+#define pagecache_get_page pagecache_get_page_fixed
|
|
|
|
/**
|
|
* find_get_page - find and get a page reference
|
|
--- a/mm/filemap.c
|
|
+++ b/mm/filemap.c
|
|
@@ -2674,3 +2674,13 @@ int try_to_release_page(struct page *pag
|
|
}
|
|
|
|
EXPORT_SYMBOL(try_to_release_page);
|
|
+
|
|
+#undef pagecache_get_page
|
|
+struct page *pagecache_get_page(struct address_space *mapping, pgoff_t offset,
|
|
+ int fgp_flags, gfp_t cache_gfp_mask,
|
|
+ gfp_t radix_gfp_mask __always_unused)
|
|
+{
|
|
+ return pagecache_get_page_fixed(mapping, offset, fgp_flags,
|
|
+ cache_gfp_mask);
|
|
+}
|
|
+EXPORT_SYMBOL(pagecache_get_page);
|