stable.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/1] reiserfs: destroy allocated commit workqueue
@ 2014-12-12 15:29 Jiri Slaby
  2014-12-12 16:02 ` Jiri Slaby
  2014-12-12 21:27 ` Jan Kara
  0 siblings, 2 replies; 3+ messages in thread
From: Jiri Slaby @ 2014-12-12 15:29 UTC (permalink / raw)
  To: reiserfs-devel; +Cc: linux-kernel, Jiri Slaby, Jan Kara, All Versions

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 <jslaby@suse.cz>
Reported-by: auxsvr@gmail.com
Reported-by: Benoît Monin <benoit.monin@gmx.fr>
Cc: Jan Kara <jack@suse.cz>
Cc: All Versions <stable@vger.kernel.org>
Cc: reiserfs-devel@vger.kernel.org
---
 fs/reiserfs/super.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/fs/reiserfs/super.c b/fs/reiserfs/super.c
index ea63ab13ef92..71fbbe3e2dab 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);
-- 
2.2.0


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH 1/1] reiserfs: destroy allocated commit workqueue
  2014-12-12 15:29 [PATCH 1/1] reiserfs: destroy allocated commit workqueue Jiri Slaby
@ 2014-12-12 16:02 ` Jiri Slaby
  2014-12-12 21:27 ` Jan Kara
  1 sibling, 0 replies; 3+ messages in thread
From: Jiri Slaby @ 2014-12-12 16:02 UTC (permalink / raw)
  To: reiserfs-devel; +Cc: linux-kernel, Jan Kara, All Versions, Jeff Mahoney

On 12/12/2014, 04:29 PM, Jiri Slaby wrote:
> 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 <jslaby@suse.cz>
> Reported-by: auxsvr@gmail.com
> Reported-by: Benoît Monin <benoit.monin@gmx.fr>
> Cc: Jan Kara <jack@suse.cz>
> Cc: All Versions <stable@vger.kernel.org>

This is not quite correct. It was introduced in commit
797d9016ceca69879bb273218810fa0beef46aac (reiserfs: use per-fs commit
workqueues), so only 3.16+ is affected.

> Cc: reiserfs-devel@vger.kernel.org
> ---
>  fs/reiserfs/super.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/fs/reiserfs/super.c b/fs/reiserfs/super.c
> index ea63ab13ef92..71fbbe3e2dab 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);
> 


-- 
js
suse labs

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH 1/1] reiserfs: destroy allocated commit workqueue
  2014-12-12 15:29 [PATCH 1/1] reiserfs: destroy allocated commit workqueue Jiri Slaby
  2014-12-12 16:02 ` Jiri Slaby
@ 2014-12-12 21:27 ` Jan Kara
  1 sibling, 0 replies; 3+ messages in thread
From: Jan Kara @ 2014-12-12 21:27 UTC (permalink / raw)
  To: Jiri Slaby; +Cc: reiserfs-devel, linux-kernel, Jan Kara, All Versions

On Fri 12-12-14 16:29:29, Jiri Slaby wrote:
> 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 <jslaby@suse.cz>
> Reported-by: auxsvr@gmail.com
> Reported-by: Beno�t Monin <benoit.monin@gmx.fr>
> Cc: Jan Kara <jack@suse.cz>
> Cc: All Versions <stable@vger.kernel.org>
> Cc: reiserfs-devel@vger.kernel.org
  Thanks, I've added the patch to my tree and will send it to Linus soon.

								Honza
> ---
>  fs/reiserfs/super.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/fs/reiserfs/super.c b/fs/reiserfs/super.c
> index ea63ab13ef92..71fbbe3e2dab 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);
> -- 
> 2.2.0
> 
-- 
Jan Kara <jack@suse.cz>
SUSE Labs, CR

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-12-12 21:27 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-12-12 15:29 [PATCH 1/1] reiserfs: destroy allocated commit workqueue Jiri Slaby
2014-12-12 16:02 ` Jiri Slaby
2014-12-12 21:27 ` Jan Kara

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).