diff options
author | Christoph Hellwig <hch@lst.de> | 2011-10-28 10:03:41 +0200 |
---|---|---|
committer | root <root@serles.lst.de> | 2011-10-28 14:58:55 +0200 |
commit | 62a3ddef6181d7d932c565d97552d2f7b9ab4d28 (patch) | |
tree | fbf4c2fd154936afdea976514f5d50e94e7225da | |
parent | 948409c74d217f6cf054b8c927765a1c3fe16b53 (diff) | |
download | linux-62a3ddef6181d7d932c565d97552d2f7b9ab4d28.tar.bz2 |
vfs: fix spinning prevention in prune_icache_sb
We need to move the inode to the end of the list to actually make the
spinning prevention explained in the comment above it work. With a
plain list_move it will simply stay in place as we're always reclaiming
from the head of the list.
Signed-off-by: Christoph Hellwig <hch@lst.de>
-rw-r--r-- | fs/inode.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/inode.c b/fs/inode.c index ec7924696a13..ecbb68dc7e2a 100644 --- a/fs/inode.c +++ b/fs/inode.c @@ -634,7 +634,7 @@ void prune_icache_sb(struct super_block *sb, int nr_to_scan) * inode to the back of the list so we don't spin on it. */ if (!spin_trylock(&inode->i_lock)) { - list_move(&inode->i_lru, &sb->s_inode_lru); + list_move_tail(&inode->i_lru, &sb->s_inode_lru); continue; } |