diff --git a/fs/inode.c b/fs/inode.c index d6353b8d1e63..f63535ee3629 100644 --- a/fs/inode.c +++ b/fs/inode.c @@ -941,6 +941,12 @@ static enum lru_status inode_lru_isolate(struct list_head *item, if (!spin_trylock(&inode->i_lock)) return LRU_SKIP; + /* Another walker is dropping its page cache, leave it to that one */ + if (inode_state_read(inode) & I_LRU_ISOLATING) { + spin_unlock(&inode->i_lock); + return LRU_SKIP; + } + /* * Inodes can get referenced, redirtied, or repopulated while * they're already on the LRU, and this can make them