lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <alpine.DEB.1.10.0812141200230.20467@gandalf.stny.rr.com>
Date:	Sun, 14 Dec 2008 12:04:26 -0500 (EST)
From:	Steven Rostedt <rostedt@...dmis.org>
To:	Frederic Weisbecker <fweisbec@...il.com>
cc:	Ingo Molnar <mingo@...e.hu>,
	Linux Kernel <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] tracing/ftrace: add the printk-msg-only option


On Sat, 13 Dec 2008, Frederic Weisbecker wrote:

> Impact: display ftrace_printk messages "as is"
> 
> By default, ftrace_printk() messages find their output with some other
> informations like pid, caller, ...
> Sometimes a developer just want to have the ftrace_printk left "as is", without
> other information.
> 
> This is done by providing a default-off option called printk-msg-only.
> To enable it, just do `echo printk-msg-only > /debugfs/tracing/trace_options`
> 
> Before the patch:
> 
>            <...>-2739  [000]   145.692153: __might_sleep: I'm an ftrace_printk msg in __might_sleep
>            <...>-2739  [000]   145.692155: __might_sleep: I'm another ftrace_printk msg in __might_sleep
> 
> After the patch and the printk-msg-only option enabled:
> 
> I'm an ftrace_printk msg in __might_sleep
> I'm another ftrace_printk msg in __might_sleep
> 
> Cc: Steven Rostedt <rostedt@...dmis.org>
> Signed-off-by: Frederic Weisbecker <fweisbec@...il.com>
> ---
> diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c
> index 8fd3c5a..cd4dbf2 100644
> --- a/kernel/trace/trace.c
> +++ b/kernel/trace/trace.c
> @@ -287,6 +287,7 @@ static const char *trace_options[] = {
>  	"annotate",
>  	"userstacktrace",
>  	"sym-userobj",
> +	"printk-msg-only",

Hmm, I'm a bit apprehensive about this approach. We are adding a lot of 
options that I'm not sure will be used. Is this needed because you added a 
ftrace printk that you want to not have the header, or because there are 
ftrace printks that exist that you want to turn on and off. Or perhaps, 
you want to see the header sometimes and sometimes you do not?

If it is the later two, then sure we could have this option. But if it is 
the former, then we probably should have another type of ftrace_printk 
that takes an option to make another event type to tell the output not to 
print?

Oh well, I have patches in mind to clean up the output code anyway.

-- Steve
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ