From: Fabian Frederick Date: Sat, 27 Dec 2014 15:01:22 +0000 (+0100) Subject: ext3: destroy sbi mutexes in put_super X-Git-Tag: v5.15~16383^2~22 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=6744e90b0fa1fc6a908fa26935a5ed9e63413063;p=platform%2Fkernel%2Flinux-starfive.git ext3: destroy sbi mutexes in put_super Call mutex_destroy() on superblock mutexes in ext3_put_super(). Otherwise mutex debugging code isn't able to detect that mutex is used after being freed. Signed-off-by: Fabian Frederick Signed-off-by: Jan Kara --- diff --git a/fs/ext3/super.c b/fs/ext3/super.c index 9b4e7d7..d4dbf3c 100644 --- a/fs/ext3/super.c +++ b/fs/ext3/super.c @@ -466,6 +466,8 @@ static void ext3_put_super (struct super_block * sb) } sb->s_fs_info = NULL; kfree(sbi->s_blockgroup_lock); + mutex_destroy(&sbi->s_orphan_lock); + mutex_destroy(&sbi->s_resize_lock); kfree(sbi); }