[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20250821082129.f12b601c3263e2fd3324b618@kernel.org>
Date: Thu, 21 Aug 2025 08:21:29 +0900
From: Masami Hiramatsu (Google) <mhiramat@...nel.org>
To: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: Masami Hiramatsu (Google) <mhiramat@...nel.org>, Steven Rostedt
<rostedt@...dmis.org>, Masami Hiramatsu <mhiramat@...nel.org>,
linux-kernel@...r.kernel.org
Subject: [GIT PULL] probes: Fixes for v6.17-rc2
Hi Linus,
Probes fixes for v6.17-rc2:
- tracing: fprobe-event: Sanitize wildcard for fprobe event name
Fprobe event accepts wildcards for the target functions, but
unless the user specifies its event name, it makes an event with
the wildcards. Replace the wildcard '*' with the underscore '_'.
Please pull the latest probes-fixes-v6.17-rc2 tree, which can be found at:
git://git.kernel.org/pub/scm/linux/kernel/git/trace/linux-trace.git
probes-fixes-v6.17-rc2
Tag SHA1: 79f2c8d9a0956a85dadb6c8cd1c972e87777969b
Head SHA1: ec879e1a0be8007aa232ffedcf6a6445dfc1a3d7
Masami Hiramatsu (Google) (1):
tracing: fprobe-event: Sanitize wildcard for fprobe event name
----
kernel/trace/trace.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
---------------------------
commit ec879e1a0be8007aa232ffedcf6a6445dfc1a3d7
Author: Masami Hiramatsu (Google) <mhiramat@...nel.org>
Date: Sat Aug 16 23:10:51 2025 +0900
tracing: fprobe-event: Sanitize wildcard for fprobe event name
Fprobe event accepts wildcards for the target functions, but unless user
specifies its event name, it makes an event with the wildcards.
/sys/kernel/tracing # echo 'f mutex*' >> dynamic_events
/sys/kernel/tracing # cat dynamic_events
f:fprobes/mutex*__entry mutex*
/sys/kernel/tracing # ls events/fprobes/
enable filter mutex*__entry
To fix this, replace the wildcard ('*') with an underscore.
Link: https://lore.kernel.org/all/175535345114.282990.12294108192847938710.stgit@devnote2/
Fixes: 334e5519c375 ("tracing/probes: Add fprobe events for tracing function entry and exit.")
Signed-off-by: Masami Hiramatsu (Google) <mhiramat@...nel.org>
Cc: stable@...r.kernel.org
diff --git a/kernel/trace/trace.h b/kernel/trace/trace.h
index 1dbf1d3cf2f1..5a6688832da8 100644
--- a/kernel/trace/trace.h
+++ b/kernel/trace/trace.h
@@ -2204,7 +2204,7 @@ static inline bool is_good_system_name(const char *name)
static inline void sanitize_event_name(char *name)
{
while (*name++ != '\0')
- if (*name == ':' || *name == '.')
+ if (*name == ':' || *name == '.' || *name == '*')
*name = '_';
}
--
Masami Hiramatsu (Google) <mhiramat@...nel.org>
Powered by blists - more mailing lists