Messages in this thread | | | Date | Mon, 19 Jun 2023 10:26:51 +0200 | From | Greg KH <> | Subject | Re: [PATCH 5.10] tracing: Add tracing_reset_all_online_cpus_unlocked() function |
| |
On Fri, Jun 16, 2023 at 04:49:31AM +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> > [this patch is pre-depended by be111ebd8868d4b7c041cb3c6102e1ae27d6dc1d > due to tracing_reset_all_online_cpus() should be called after taking lock] > Fixes: be111ebd8868 ("tracing: Free buffers when a used dynamic event is removed") > Signed-off-by: Zheng Yejian <zhengyejian1@huawei.com> > ---
What about for 5.15.y? You can't apply a fix to just an older tree as you will then have a regression when you update.
I'll drop this one from my queue, please resend a backport for all relevent stable releases.
thanks,
greg k-h
| |