From: Jiri Slaby Date: Fri, 12 Dec 2014 15:29:29 +0000 (+0100) Subject: reiserfs: destroy allocated commit workqueue X-Git-Tag: v3.19-rc1~54^2~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=fa0c5540739320258c3e3a45aaae9dae467b2504;p=platform%2Fkernel%2Flinux-exynos.git reiserfs: destroy allocated commit workqueue When resirefs is trying to mount a partition, it creates a commit workqueue (sbi->commit_wq). But when mount fails later, the workqueue is not freed. Signed-off-by: Jiri Slaby Reported-by: auxsvr@gmail.com Reported-by: BenoƮt Monin Cc: Jan Kara Cc: stable@vger.kernel.org # >= 3.16 Cc: reiserfs-devel@vger.kernel.org Fixes: 797d9016ceca69879bb273218810fa0beef46aac Signed-off-by: Jan Kara --- diff --git a/fs/reiserfs/super.c b/fs/reiserfs/super.c index ea63ab1..71fbbe3 100644 --- a/fs/reiserfs/super.c +++ b/fs/reiserfs/super.c @@ -2172,6 +2172,9 @@ error_unlocked: reiserfs_write_unlock(s); } + if (sbi->commit_wq) + destroy_workqueue(sbi->commit_wq); + cancel_delayed_work_sync(&REISERFS_SB(s)->old_work); reiserfs_free_bitmap_cache(s);