From: Steven Rostedt <rostedt@goodmis.org>
To: linux-kernel@vger.kernel.org
Cc: Ingo Molnar <mingo@kernel.org>,
Andrew Morton <akpm@linux-foundation.org>,
Masami Hiramatsu <mhiramat@kernel.org>,
Tzvetomir Stoyanov <tz.stoyanov@gmail.com>,
Tom Zanussi <zanussi@kernel.org>
Subject: [PATCH v2 0/6] tracing/eprobes: Fixes for unexpected arguments
Date: Sat, 20 Aug 2022 09:43:16 -0400 [thread overview]
Message-ID: <20220820134316.156058831@goodmis.org> (raw)
While using eprobes, I decided to entertain the thougth of what would
happen if I tried to get the instruction pointer "%rip", knowing full
well that eprobes do not have access to pt_regs. Well, I found out, and
it led me down a rabbit hole of bugs.
This series fixes those bugs, by not allowing register access for eprobes,
and also filling the holes of @symbol and @immediate argument.
Changes since v1: https://lore.kernel.org/all/20220820014035.531145719@goodmis.org/
- Fixed parenthesis warning
- Fixed comment about comm arguments
- Made kprobes and eprobes process "$COMM" as well as "$comm"
- Made filters consistent with histograms with "common_cpu"
Steven Rostedt (Google) (6):
tracing/eprobes: Do not allow eprobes to use $stack, or % for regs
tracing/eprobes: Do not hardcode $comm as a string
tracing/eprobes: Fix reading of string fields
tracing/eprobes: Have event probes be consistent with kprobes and uprobes
tracing/probes: Have kprobes and uprobes use $COMM too
tracing: Have filter accept "common_cpu" to be consistent
----
kernel/trace/trace_eprobe.c | 91 ++++++++++++++++++++++++++++++++++++++++++---
kernel/trace/trace_events.c | 1 +
kernel/trace/trace_probe.c | 29 +++++++++------
3 files changed, 104 insertions(+), 17 deletions(-)
next reply other threads:[~2022-08-20 13:43 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-08-20 13:43 Steven Rostedt [this message]
2022-08-20 13:43 ` [PATCH v2 1/6] tracing/eprobes: Do not allow eprobes to use $stack, or % for regs Steven Rostedt
2022-08-20 13:43 ` [PATCH v2 2/6] tracing/eprobes: Do not hardcode $comm as a string Steven Rostedt
2022-08-20 13:43 ` [PATCH v2 3/6] tracing/eprobes: Fix reading of string fields Steven Rostedt
2022-08-20 13:43 ` [PATCH v2 4/6] tracing/eprobes: Have event probes be consistent with kprobes and uprobes Steven Rostedt
2022-08-20 13:43 ` [PATCH v2 5/6] tracing/probes: Have kprobes and uprobes use $COMM too Steven Rostedt
2022-08-21 15:19 ` Masami Hiramatsu
2022-08-21 15:40 ` Steven Rostedt
2022-08-20 13:43 ` [PATCH v2 6/6] tracing: Have filter accept "common_cpu" to be consistent Steven Rostedt
2022-08-21 15:14 ` Masami Hiramatsu
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=20220820134316.156058831@goodmis.org \
--to=rostedt@goodmis.org \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mhiramat@kernel.org \
--cc=mingo@kernel.org \
--cc=tz.stoyanov@gmail.com \
--cc=zanussi@kernel.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).