linux-trace-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Masami Hiramatsu (Google) <mhiramat@kernel.org>
To: Steven Rostedt <rostedt@goodmis.org>
Cc: linux-kernel@vger.kernel.org, linux-trace-kernel@vger.kernel.org,
	Mark Rutland <mark.rutland@arm.com>,
	Mathieu Desnoyers <mathieu.desnoyers@efficios.com>,
	Andrew Morton <akpm@linux-foundation.org>
Subject: Re: [RFC PATCH v2 1/3] tracing: Show last module text symbols in the stacktrace
Date: Mon, 10 Mar 2025 17:59:46 +0900	[thread overview]
Message-ID: <20250310175946.c317afa1ae89540cb1076940@kernel.org> (raw)
In-Reply-To: <20250306194627.59452513@gandalf.local.home>

On Thu, 6 Mar 2025 19:46:27 -0500
Steven Rostedt <rostedt@goodmis.org> wrote:

> On Tue, 11 Feb 2025 00:43:57 +0900
> "Masami Hiramatsu (Google)" <mhiramat@kernel.org> wrote:
> 
> > From: Masami Hiramatsu (Google) <mhiramat@kernel.org>
> > 
> > Since the previous boot trace buffer can include module text address in
> > the stacktrace. As same as the kernel text address, convert the module
> > text address using the module address information.
> > 
> > Signed-off-by: Masami Hiramatsu (Google) <mhiramat@kernel.org>
> > ---
> >  Changes in v2:
> >   - Add LRU based removed module information override.
> 
> I don't think we should bother supporting removal of modules yet.
> 
> It also makes this patch way too complex for what it should do.
> 
> >   - Fix to move module_delta initialization after tr->scratch check.
> 
> >   - Fix to make mod_delta on all loaded modules correctly.
> 
> Should be a separate patch.
> 
> >   - (Note, I don't add uname check yet)
> >   - Fix mod_addr_comp() overflow issue.
> >   - Add pr_info() when failed to allocate module_delta.
> 
> So basically this patch should just add the code to handle finding the
> module for stack traces. Not to mention, I have code that depends on that,
> but this patch currently does way to much.
> 
> Can you just send a patch that adds the trace_adjust_address() (although, I
> would shorten it to "trace_addr_adjust()").
> 
> And add what is needed to update the trace_stack_print().
> 
> You can base it off of the ring-buffer/for-next branch.

OK, BTW, if we always need tscratch, we can move module_delta in it.
Let's reimplement it.

Thanks,

> 
> Thanks,
> 
> -- Steve
> 
> 
> > ---
> >  kernel/trace/trace.c        |  173 ++++++++++++++++++++++++++++++++++++++++---
> >  kernel/trace/trace.h        |    4 +
> >  kernel/trace/trace_output.c |    3 -
> >  3 files changed, 167 insertions(+), 13 deletions(-)
> > 


-- 
Masami Hiramatsu (Google) <mhiramat@kernel.org>

  reply	other threads:[~2025-03-10  8:59 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-10 15:43 [RFC PATCH v2 0/3] tracing: Improve persistent ring buffer Masami Hiramatsu (Google)
2025-02-10 15:43 ` [RFC PATCH v2 1/3] tracing: Show last module text symbols in the stacktrace Masami Hiramatsu (Google)
2025-03-07  0:46   ` Steven Rostedt
2025-03-10  8:59     ` Masami Hiramatsu [this message]
2025-02-10 15:44 ` [RFC PATCH v2 2/3] mm/memblock: Add reserved memory release function Masami Hiramatsu (Google)
2025-02-11  0:03   ` Steven Rostedt
2025-02-11  1:43     ` Masami Hiramatsu
2025-02-10 15:44 ` [RFC PATCH v2 3/3] tracing: Freeable reserved ring buffer Masami Hiramatsu (Google)
2025-02-11  0:13   ` Steven Rostedt
2025-02-11  1:41     ` Masami Hiramatsu
2025-02-11 14:57       ` Steven Rostedt

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=20250310175946.c317afa1ae89540cb1076940@kernel.org \
    --to=mhiramat@kernel.org \
    --cc=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-trace-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=mathieu.desnoyers@efficios.com \
    --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 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).