summarylogtreecommitdiffstats
path: root/0001-Linux-use-plain-page_cache_alloc.patch
diff options
context:
space:
mode:
Diffstat (limited to '0001-Linux-use-plain-page_cache_alloc.patch')
-rw-r--r--0001-Linux-use-plain-page_cache_alloc.patch42
1 files changed, 42 insertions, 0 deletions
diff --git a/0001-Linux-use-plain-page_cache_alloc.patch b/0001-Linux-use-plain-page_cache_alloc.patch
new file mode 100644
index 000000000000..338b6cc1f500
--- /dev/null
+++ b/0001-Linux-use-plain-page_cache_alloc.patch
@@ -0,0 +1,42 @@
+From 9958cc449c99b2098eb13b2e061c5a981cc1de84 Mon Sep 17 00:00:00 2001
+From: Stephan Wiesand <stephan.wiesand@desy.de>
+Date: Fri, 22 Dec 2017 14:17:09 +0100
+Subject: [PATCH 1/2] Linux: use plain page_cache_alloc
+
+Linux 4.15 removes the distinction between "hot" and "cold" cache
+pages, and no longer provides page_cache_alloc_cold(). Simply use
+page_cache_alloc() instead, rather than adding yet another test.
+
+Reviewed-on: https://gerrit.openafs.org/12823
+Tested-by: BuildBot <buildbot@rampaginggeek.com>
+Reviewed-by: Marcio Brito Barbosa <mbarbosa@sinenomine.net>
+Tested-by: Marcio Brito Barbosa <mbarbosa@sinenomine.net>
+Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
+(cherry picked from commit be5f5b2aff2d59986dd8e7dd7dd531be24c27cb2)
+
+Reviewed-on: https://gerrit.openafs.org/12828
+Tested-by: BuildBot <buildbot@rampaginggeek.com>
+Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
+(cherry picked from commit 2ff3ef2ec6f217195dc50c04ba4e3409c23e6a4d)
+
+Change-Id: Iec018dd6591c0cd477a026efd8817ccea7924dce
+---
+ src/afs/LINUX/osi_vnodeops.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/afs/LINUX/osi_vnodeops.c b/src/afs/LINUX/osi_vnodeops.c
+index 051452b34..c2cd4f742 100644
+--- a/src/afs/LINUX/osi_vnodeops.c
++++ b/src/afs/LINUX/osi_vnodeops.c
+@@ -2033,7 +2033,7 @@ afs_linux_read_cache(struct file *cachefp, struct page *page,
+ cachepage = find_get_page(cachemapping, pageindex);
+ if (!cachepage) {
+ if (!newpage)
+- newpage = page_cache_alloc_cold(cachemapping);
++ newpage = page_cache_alloc(cachemapping);
+ if (!newpage) {
+ code = -ENOMEM;
+ goto out;
+--
+2.16.1
+