udf: destroy sbi mutex in put_super
authorFabian Frederick <fabf@skynet.be>
Sat, 10 Jan 2015 18:13:32 +0000 (19:13 +0100)
committerJan Kara <jack@suse.cz>
Mon, 12 Jan 2015 09:56:04 +0000 (10:56 +0100)
Call mutex_destroy() on superblock mutex in udf_put_super()
otherwise mutex debugging code isn't able to detect that
mutex is used after being freed.
(thanks to Jan Kara for complete definition).

Signed-off-by: Fabian Frederick <fabf@skynet.be>
Signed-off-by: Jan Kara <jack@suse.cz>
fs/udf/super.c

index 3ccb2f11fc767bb4948ec526fa50107468511ded..3d35a754293a594b7c1a1a25f540058123e3917b 100644 (file)
@@ -2300,6 +2300,7 @@ static void udf_put_super(struct super_block *sb)
                udf_close_lvid(sb);
        brelse(sbi->s_lvid_bh);
        udf_sb_free_partitions(sb);
+       mutex_destroy(&sbi->s_alloc_mutex);
        kfree(sb->s_fs_info);
        sb->s_fs_info = NULL;
 }