lkml.org 
[lkml]   [2020]   [Jul]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] dynamic debug: allow printing to trace event
On Thu, 23 Jul 2020 16:08:44 +0206
John Ogness <john.ogness@linutronix.de> wrote:

> For me a trace event represents a specific point in the kernel code. But
> this new printk trace event, instead, represents general log
> redirection. I do not oppose it, but it feels like a hack to me. In
> contrast, simply setting a dynamic printk flag to write the message
> string to the trace buffer (without also activating some pseudo trace
> event) feels more natural.

I agree with your sentiment. But my experience with the kernel is, if
you create an API for one subsystem, other subsystems are destined to
(ab)use it.

Now, trace_array_vprintk() is available too, which acts just like
trace_printk(), but requires creating a separate trace buffer to write
to. I'm fine with this because it wont cause noise in the top level
buffer.


>
> Just sharing my thoughts, as requested.

Appreciated ;-)

-- Steve

\
 
 \ /
  Last update: 2020-07-23 17:40    [W:0.158 / U:0.016 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site