Re: [PATCH] tracing: Do not synchronize freeing of trigger filter on boot up

From: Steven Rostedt
Date: Tue Dec 13 2022 - 19:03:59 EST


On Wed, 14 Dec 2022 08:49:54 +0900
Masami Hiramatsu (Google) <mhiramat@xxxxxxxxxx> wrote:

> > Avoid calling the synchronization function when system_state is
> > SYSTEM_BOOTING.
>
> Shouldn't this be done inside tracepoint_synchronize_unregister()?
> Then, it will prevent similar warnings if we expand boot time feature.

I thought about that, but because this is a special case, I was thinking
that we don't just gloss over it and have something call this when it
shouldn't be in early boot up. I was surprised when it was called, and then
had to debug it a bit to figure out why it was. When I discovered the path
it took to get there, I realized it was legitimate.

Right now, I only see this one case as an exception. If more pop up that
are correct, then we can switch it over. But right now, I still want
calling tracepoint_synchronize_unregister() to warn if it is called in
early boot up, because that could be a sign that something went wrong.

-- Steve