From: Greg KH <gregkh@linuxfoundation.org>
To: Zheng Yejian <zhengyejian1@huawei.com>
Cc: rostedt@goodmis.org, mhiramat@kernel.org,
linux-kernel@vger.kernel.org, linux-trace-kernel@vger.kernel.org,
stable@vger.kernel.org
Subject: Re: [PATCH 5.15] tracing: Add tracing_reset_all_online_cpus_unlocked() function
Date: Wed, 21 Jun 2023 20:41:10 +0200 [thread overview]
Message-ID: <2023062102-catchable-obituary-934c@gregkh> (raw)
In-Reply-To: <20230620013052.1127047-1-zhengyejian1@huawei.com>
On Tue, Jun 20, 2023 at 09:30:52AM +0800, Zheng Yejian wrote:
> From: "Steven Rostedt (Google)" <rostedt@goodmis.org>
>
> commit e18eb8783ec4949adebc7d7b0fdb65f65bfeefd9 upstream.
>
> Currently the tracing_reset_all_online_cpus() requires the
> trace_types_lock held. But only one caller of this function actually has
> that lock held before calling it, and the other just takes the lock so
> that it can call it. More users of this function is needed where the lock
> is not held.
>
> Add a tracing_reset_all_online_cpus_unlocked() function for the one use
> case that calls it without being held, and also add a lockdep_assert to
> make sure it is held when called.
>
> Then have tracing_reset_all_online_cpus() take the lock internally, such
> that callers do not need to worry about taking it.
>
> Link: https://lkml.kernel.org/r/20221123192741.658273220@goodmis.org
>
> Cc: Masami Hiramatsu <mhiramat@kernel.org>
> Cc: Andrew Morton <akpm@linux-foundation.org>
> Cc: Zheng Yejian <zhengyejian1@huawei.com>
> Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
>
> [Refers to commit message of 417d5ea6e735e5d88ffb6c436cf2938f3f476dd1,
> this patch is pre-depended, and tracing_reset_all_online_cpus() should
> be called after trace_types_lock is held as its comment describes.]
> Fixes: 417d5ea6e735 ("tracing: Free buffers when a used dynamic event is removed")
> Signed-off-by: Zheng Yejian <zhengyejian1@huawei.com>
All now queued up, thanks.
greg k-h
prev parent reply other threads:[~2023-06-21 18:41 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-20 1:30 [PATCH 5.15] tracing: Add tracing_reset_all_online_cpus_unlocked() function Zheng Yejian
2023-06-21 18:41 ` Greg KH [this message]
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=2023062102-catchable-obituary-934c@gregkh \
--to=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-trace-kernel@vger.kernel.org \
--cc=mhiramat@kernel.org \
--cc=rostedt@goodmis.org \
--cc=stable@vger.kernel.org \
--cc=zhengyejian1@huawei.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.