Home Home > GIT Browse > openSUSE-15.1
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMel Gorman <mgorman@suse.de>2019-01-11 10:43:24 +0000
committerMel Gorman <mgorman@suse.de>2019-01-11 10:43:24 +0000
commita526ecfc9f7faecc9212c0780f6915fffa31243b (patch)
tree48f6a4346feb1341e459bf81f0cb12a21087df0c
parent6f52a6674a2116fcdd84c9f84d6197c946a2d924 (diff)
mm, fault_around: do not take a reference to a locked page
(VM Performance filemap (bsc#1121581)). suse-commit: 9cb10ef9d877a214330508cebbb14f3f6059ad03
-rw-r--r--mm/filemap.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/mm/filemap.c b/mm/filemap.c
index 162c940910d4..8c42cebe54d3 100644
--- a/mm/filemap.c
+++ b/mm/filemap.c
@@ -2639,6 +2639,13 @@ repeat:
}
head = compound_head(page);
+
+ /*
+ * Check for a locked page first, as a speculative
+ * reference may adversely influence page migration.
+ */
+ if (PageLocked(head))
+ goto next;
if (!page_cache_get_speculative(head))
goto repeat;