From f5e1dd34561e0fb06400b378d595198918833021 Mon Sep 17 00:00:00 2001 From: Glauber Costa Date: Wed, 28 Aug 2013 10:18:18 +1000 Subject: super: fix for destroy lrus This patch adds the missing call to list_lru_destroy (spotted by Li Zhong) and moves the deletion to after the shrinker is unregistered, as correctly spotted by Dave Signed-off-by: Glauber Costa Cc: Michal Hocko Cc: Dave Chinner Signed-off-by: Andrew Morton Signed-off-by: Al Viro --- fs/super.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'fs/super.c') diff --git a/fs/super.c b/fs/super.c index 269d96857caa..3a96c9783a8b 100644 --- a/fs/super.c +++ b/fs/super.c @@ -323,6 +323,9 @@ void deactivate_locked_super(struct super_block *s) /* caches are now gone, we can safely kill the shrinker now */ unregister_shrinker(&s->s_shrink); + list_lru_destroy(&s->s_dentry_lru); + list_lru_destroy(&s->s_inode_lru); + put_filesystem(fs); put_super(s); } else { -- cgit v1.2.3-59-g8ed1b