All of lore.kernel.org
 help / color / mirror / Atom feed
From: Masami Hiramatsu <mhiramat@kernel.org>
To: Steven Rostedt <rostedt@goodmis.org>
Cc: LKML <linux-kernel@vger.kernel.org>, Ingo Molnar <mingo@kernel.org>
Subject: Re: [PATCH v3 0/3] tracing: Show real address instead of hashed pointer
Date: Fri, 16 Oct 2020 01:00:57 +0900	[thread overview]
Message-ID: <20201016010057.ad0cbfaf4892fa26d34e8ff2@kernel.org> (raw)
In-Reply-To: <20201015114931.1c9803ae@gandalf.local.home>

On Thu, 15 Oct 2020 11:49:31 -0400
Steven Rostedt <rostedt@goodmis.org> wrote:

> On Thu, 15 Oct 2020 23:54:58 +0900
> Masami Hiramatsu <mhiramat@kernel.org> wrote:
> 
> > Hi,
> > 
> > Here is the 3rd version of the series for real address printing in trace log.
> > 
> > Here is the previous version, I've fixed [1/3] to use krealloc(), fix memory
> > allocation error check and add __printf() attribute, according to Steve's
> > comment.
> > 
> > https://lore.kernel.org/lkml/160275239876.115066.10891356497426857018.stgit@devnote2/
> > 
> > 
> > Since trace_seq_printf() use in-kernel vsprintf() at last, the %p is always
> > converted to the hash value instead of real address.
> > 
> > For the dmesg it maybe secure, but for the ftrace, I think it is
> > meaningless because
> > 
> > - tracefs is used by root user, so no need to hide it.
> > - tracefs user can access percpu/cpu*/trace_pipe_raw which stores real
> >   address on the trace buffer.
> > - external commands like perf doesn't convert to the hash value.
> > 
> > And when debugging kernel, we would like to know real address which tells
> > us the address is in which area in the kernel by comparing with kernel
> > memory mapping.
> > 
> > However, to compare the trace log with dmesg, we also need a bridging
> > information. So 3/3 gives the options/hash-ptr knob which switches
> > the output format.
> > 
> 
> Thanks Masami,
> 
> I'm going to hold off on adding this for this merge window, and look at
> applying it for the next window.

Thank you very much!
I got it, anyway I can use kernelshark or perf script to decode raw event
data, or I will use kprobe event to fetch the real address :)

-- 
Masami Hiramatsu <mhiramat@kernel.org>

      reply	other threads:[~2020-10-15 16:01 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-15 14:54 [PATCH v3 0/3] tracing: Show real address instead of hashed pointer Masami Hiramatsu
2020-10-15 14:55 ` [PATCH v3 1/3] tracing: Show real address for trace event arguments Masami Hiramatsu
2021-04-19 13:08   ` Jon Hunter
2021-04-19 18:22     ` Steven Rostedt
2021-04-20 11:16       ` Jon Hunter
2020-10-15 14:55 ` [PATCH v3 2/3] tracing: Update the stage 3 of trace event macro comment Masami Hiramatsu
2020-10-15 14:55 ` [PATCH v3 3/3] tracing: Add ptr-hash option to show the hashed pointer value Masami Hiramatsu
2021-02-12 15:33   ` Steven Rostedt
2021-02-15 14:58     ` Masami Hiramatsu
2020-10-15 15:49 ` [PATCH v3 0/3] tracing: Show real address instead of hashed pointer Steven Rostedt
2020-10-15 16:00   ` Masami Hiramatsu [this message]

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=20201016010057.ad0cbfaf4892fa26d34e8ff2@kernel.org \
    --to=mhiramat@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=rostedt@goodmis.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.