From: Jan Kara <jack@suse.cz>
To: Steven Rostedt <rostedt@goodmis.org>
Cc: linux-kernel@vger.kernel.org,
Linus Torvalds <torvalds@linux-foundation.org>,
Thomas Gleixner <tglx@linutronix.de>,
Stephen Boyd <sboyd@kernel.org>,
Guenter Roeck <linux@roeck-us.net>,
Anna-Maria Gleixner <anna-maria@linutronix.de>,
Andrew Morton <akpm@linux-foundation.org>,
Theodore Tso <tytso@mit.edu>, Jan Kara <jack@suse.com>,
linux-ext4@vger.kernel.org
Subject: Re: [RFC][PATCH v3 30/33] timers: jbd2: Use timer_shutdown() before freeing timer
Date: Mon, 7 Nov 2022 13:37:55 +0100 [thread overview]
Message-ID: <20221107123755.vrailpdu5wxrb7se@quack3> (raw)
In-Reply-To: <20221104054917.365008421@goodmis.org>
On Fri 04-11-22 01:41:23, Steven Rostedt wrote:
> From: "Steven Rostedt (Google)" <rostedt@goodmis.org>
>
> Before a timer is freed, timer_shutdown() must be called. Note that it is
> assumed that the timer is not running while being freed, so only
> timer_shutdown() is used, and not timer_shutdown_sync().
>
> Link: https://lore.kernel.org/all/20220407161745.7d6754b3@gandalf.local.home/
>
> Cc: "Theodore Ts'o" <tytso@mit.edu>
> Cc: Jan Kara <jack@suse.com>
> Cc: linux-ext4@vger.kernel.org
> Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
Looks good to me. Feel free to add:
Reviewed-by: Jan Kara <jack@suse.cz>
Honza
> ---
> fs/jbd2/journal.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/fs/jbd2/journal.c b/fs/jbd2/journal.c
> index 2696f43e7239..57d2445d8c8b 100644
> --- a/fs/jbd2/journal.c
> +++ b/fs/jbd2/journal.c
> @@ -2157,6 +2157,8 @@ int jbd2_journal_destroy(journal_t *journal)
> J_ASSERT(journal->j_checkpoint_transactions == NULL);
> spin_unlock(&journal->j_list_lock);
>
> + timer_shutdown(&journal->j_commit_timer);
> +
> /*
> * OK, all checkpoint transactions have been checked, now check the
> * write out io error flag and abort the journal if some buffer failed
> --
> 2.35.1
--
Jan Kara <jack@suse.com>
SUSE Labs, CR
next prev parent reply other threads:[~2022-11-07 12:38 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-04 5:40 [RFC][PATCH v3 00/33] timers: Use timer_shutdown*() before freeing timers Steven Rostedt
2022-11-04 5:41 ` [RFC][PATCH v3 27/33] timers: ext4: Use timer_shutdown_sync() before freeing timer Steven Rostedt
2022-11-04 5:41 ` [RFC][PATCH v3 30/33] timers: jbd2: Use timer_shutdown() " Steven Rostedt
2022-11-07 12:37 ` Jan Kara [this message]
2022-11-04 17:00 ` [RFC][PATCH v3 00/33] timers: Use timer_shutdown*() before freeing timers Linus Torvalds
2022-11-04 19:22 ` Guenter Roeck
2022-11-04 19:42 ` Steven Rostedt
2022-11-04 19:50 ` Linus Torvalds
2022-11-04 20:38 ` Steven Rostedt
2022-11-04 20:42 ` Guenter Roeck
2022-11-04 20:41 ` Guenter Roeck
2022-11-04 23:34 ` Guenter Roeck
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20221107123755.vrailpdu5wxrb7se@quack3 \
--to=jack@suse.cz \
--cc=akpm@linux-foundation.org \
--cc=anna-maria@linutronix.de \
--cc=jack@suse.com \
--cc=linux-ext4@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@roeck-us.net \
--cc=rostedt@goodmis.org \
--cc=sboyd@kernel.org \
--cc=tglx@linutronix.de \
--cc=torvalds@linux-foundation.org \
--cc=tytso@mit.edu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox