summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSuleiman Souhlal <suleiman@google.com>2013-04-14 01:03:06 +0200
committerLinus Torvalds <torvalds@linux-foundation.org>2013-04-14 01:13:55 +0200
commit5b55d708335a9e3e4f61f2dadf7511502205ccd1 (patch)
tree83e4687e7be804ede22f993a901264dddb001018
parentkobject: fix kset_find_obj() race with concurrent last kobject_put() (diff)
downloadlinux-5b55d708335a9e3e4f61f2dadf7511502205ccd1.tar.xz
linux-5b55d708335a9e3e4f61f2dadf7511502205ccd1.zip
vfs: Revert spurious fix to spinning prevention in prune_icache_sb
Revert commit 62a3ddef6181 ("vfs: fix spinning prevention in prune_icache_sb"). This commit doesn't look right: since we are looking at the tail of the list (sb->s_inode_lru.prev) if we want to skip an inode, we should put it back at the head of the list instead of the tail, otherwise we will keep spinning on it. Discovered when investigating why prune_icache_sb came top in perf reports of a swapping load. Signed-off-by: Suleiman Souhlal <suleiman@google.com> Signed-off-by: Hugh Dickins <hughd@google.com> Cc: stable@vger.kernel.org # v3.2+ Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r--fs/inode.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/inode.c b/fs/inode.c
index f5f7c06c36fb..a898b3d43ccf 100644
--- a/fs/inode.c
+++ b/fs/inode.c
@@ -725,7 +725,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_tail(&inode->i_lru, &sb->s_inode_lru);
+ list_move(&inode->i_lru, &sb->s_inode_lru);
continue;
}