aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDave Chinner <[email protected]>2019-02-12 15:35:51 -0800
committerLinus Torvalds <[email protected]>2019-02-12 16:33:18 -0800
commit69056ee6a8a3d576ed31e38b3b14c70d6c74edcc (patch)
tree87a456e743fc8a09fd72b48c9bd05821f318e41d
parentaa0c38cf39de73bf7360a3da8f1707601261e518 (diff)
Revert "mm: don't reclaim inodes with many attached pages"
This reverts commit a76cf1a474d7d ("mm: don't reclaim inodes with many attached pages"). This change causes serious changes to page cache and inode cache behaviour and balance, resulting in major performance regressions when combining worklaods such as large file copies and kernel compiles. https://bugzilla.kernel.org/show_bug.cgi?id=202441 This change is a hack to work around the problems introduced by changing how agressive shrinkers are on small caches in commit 172b06c32b94 ("mm: slowly shrink slabs with a relatively small number of objects"). It creates more problems than it solves, wasn't adequately reviewed or tested, so it needs to be reverted. Link: http://lkml.kernel.org/r/[email protected] Fixes: a76cf1a474d7d ("mm: don't reclaim inodes with many attached pages") Signed-off-by: Dave Chinner <[email protected]> Cc: Wolfgang Walter <[email protected]> Cc: Roman Gushchin <[email protected]> Cc: Spock <[email protected]> Cc: Rik van Riel <[email protected]> Cc: Michal Hocko <[email protected]> Cc: <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
-rw-r--r--fs/inode.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/fs/inode.c b/fs/inode.c
index 0cd47fe0dbe5..73432e64f874 100644
--- a/fs/inode.c
+++ b/fs/inode.c
@@ -730,11 +730,8 @@ static enum lru_status inode_lru_isolate(struct list_head *item,
return LRU_REMOVED;
}
- /*
- * Recently referenced inodes and inodes with many attached pages
- * get one more pass.
- */
- if (inode->i_state & I_REFERENCED || inode->i_data.nrpages > 1) {
+ /* recently referenced inodes get one more pass */
+ if (inode->i_state & I_REFERENCED) {
inode->i_state &= ~I_REFERENCED;
spin_unlock(&inode->i_lock);
return LRU_ROTATE;