summaryrefslogtreecommitdiffstats
path: root/fs/inode.c
diff options
context:
space:
mode:
authorGlauber Costa <glommer@gmail.com>2013-08-27 20:17:59 -0400
committerAl Viro <viro@zeniv.linux.org.uk>2013-09-10 18:56:30 -0400
commitd38fa6986e9124f827aa6ea4a9dde01e67a37be7 (patch)
treea8959a7583895330006abfa490cac57eb0fe5225 /fs/inode.c
parentbc3b14cb2d505dda969dbe3a31038dbb24aca945 (diff)
inode: move inode to a different list inside lock
When removing an element from the lru, this will be done today after the lock is released. This is a clear mistake, although we are not sure if the bugs we are seeing are related to this. All list manipulations are done inside the lock, and so should this one. Signed-off-by: Glauber Costa <glommer@openvz.org> Tested-by: Michal Hocko <mhocko@suse.cz> Cc: Dave Chinner <dchinner@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/inode.c')
-rw-r--r--fs/inode.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/inode.c b/fs/inode.c
index a973d268c157..5b1ec47c5d39 100644
--- a/fs/inode.c
+++ b/fs/inode.c
@@ -735,9 +735,9 @@ inode_lru_isolate(struct list_head *item, spinlock_t *lru_lock, void *arg)
735 735
736 WARN_ON(inode->i_state & I_NEW); 736 WARN_ON(inode->i_state & I_NEW);
737 inode->i_state |= I_FREEING; 737 inode->i_state |= I_FREEING;
738 list_move(&inode->i_lru, freeable);
738 spin_unlock(&inode->i_lock); 739 spin_unlock(&inode->i_lock);
739 740
740 list_move(&inode->i_lru, freeable);
741 this_cpu_dec(nr_unused); 741 this_cpu_dec(nr_unused);
742 return LRU_REMOVED; 742 return LRU_REMOVED;
743} 743}