[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20241028071228.575900713@goodmis.org>
Date: Mon, 28 Oct 2024 03:12:28 -0400
From: Steven Rostedt <rostedt@...dmis.org>
To: linux-kernel@...r.kernel.org,
linux-trace-kernel@...r.kernel.org
Cc: Masami Hiramatsu <mhiramat@...nel.org>,
Mark Rutland <mark.rutland@....com>,
Mathieu Desnoyers <mathieu.desnoyers@...icios.com>,
Andrew Morton <akpm@...ux-foundation.org>,
Thomas Gleixner <tglx@...utronix.de>,
Peter Zijlstra <peterz@...radead.org>
Subject: [PATCH 0/5] ftrace: Use guard to take ftrace_lock
The ftrace infrastructure uses ftrace_lock to protect several critical
paths. But the functions have that take the ftrace_lock has error paths that
require the lock to be released. Use the guard() helper to take the
ftrace_lock in theses functions which simplify the early exit paths.
Steven Rostedt (5):
fgraph: Use guard(mutex)(&ftrace_lock) for unregister_ftrace_graph()
ftrace: Use guard for match_records()
ftrace: Use guard to lock ftrace_lock in cache_mod()
ftrace: Use guard to take the ftrace_lock in release_probe()
ftrace: Use guard to take ftrace_lock in ftrace_graph_set_hash()
----
kernel/trace/fgraph.c | 10 ++++------
kernel/trace/ftrace.c | 53 +++++++++++++++++----------------------------------
2 files changed, 21 insertions(+), 42 deletions(-)
Powered by blists - more mailing lists