The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Steven Rostedt <rostedt@kernel.org>
To: Yury Norov <yury.norov@gmail.com>
Cc: linux-kernel@vger.kernel.org, linux-trace-kernel@vger.kernel.org,
	Masami Hiramatsu <mhiramat@kernel.org>,
	Mark Rutland <mark.rutland@arm.com>,
	Mathieu Desnoyers <mathieu.desnoyers@efficios.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	Linus Torvalds <torvalds@linux-foundation.org>,
	Sebastian Andrzej Siewior <bigeasy@linutronix.de>,
	John Ogness <john.ogness@linutronix.de>,
	Thomas Gleixner <tglx@kernel.org>,
	Peter Zijlstra <peterz@infradead.org>,
	Julia Lawall <julia.lawall@inria.fr>
Subject: Re: [PATCH v2 1/2] tracing: Move non-trace_printk prototypes into trace_controls.h
Date: Tue, 23 Jun 2026 04:22:48 -0400	[thread overview]
Message-ID: <20260623042248.7e564b70@fedora> (raw)
In-Reply-To: <ajk7fN5v31kCfGVp@yury>

On Mon, 22 Jun 2026 09:41:16 -0400
Yury Norov <yury.norov@gmail.com> wrote:

> > +void trace_dump_stack(int skip);  
> 
> The function description says:
> 
>   record a stack back trace in the trace buffer
> 
> So, to me it sounds like it should go to the trace_printk.h.

The main reason I don't want these in trace_printk.h is because they
are not the same as trace_printk(). These are usually called when
things go wrong, and are usually called along with tracing_off(), to
stop the trace to make sure you don't lose the trace of the bug that
triggered the dump.

These can also be in production with no problem, as they are triggered
when things go wrong. trace_printk() should *not* be used in production.

The uses of these are fundamentally different than the use of
trace_printk(). They are not just for development environments.

I'll update the change log to note this.

-- Steve

  parent reply	other threads:[~2026-06-23  8:22 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-22 13:07 [PATCH v2 0/2] tracing: Remove trace_printk.h from kernel.h Steven Rostedt
2026-06-22 13:07 ` [PATCH v2 1/2] tracing: Move non-trace_printk prototypes into trace_controls.h Steven Rostedt
2026-06-22 13:41   ` Yury Norov
2026-06-22 15:21     ` Steven Rostedt
2026-06-22 16:02       ` Yury Norov
2026-06-23  8:09         ` Steven Rostedt
2026-06-23  8:22     ` Steven Rostedt [this message]
2026-06-22 13:07 ` [PATCH v2 2/2] tracing: Remove trace_printk.h from kernel.h Steven Rostedt
2026-06-22 16:01   ` Yury Norov
2026-06-23  8:29     ` Steven Rostedt
2026-06-22 14:44 ` [PATCH v2 0/2] " Masami Hiramatsu
2026-06-22 15:21   ` 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=20260623042248.7e564b70@fedora \
    --to=rostedt@kernel.org \
    --cc=akpm@linux-foundation.org \
    --cc=bigeasy@linutronix.de \
    --cc=john.ogness@linutronix.de \
    --cc=julia.lawall@inria.fr \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-trace-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=mathieu.desnoyers@efficios.com \
    --cc=mhiramat@kernel.org \
    --cc=peterz@infradead.org \
    --cc=tglx@kernel.org \
    --cc=torvalds@linux-foundation.org \
    --cc=yury.norov@gmail.com \
    /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