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]
Date: Mon, 26 Feb 2024 13:44:27 -0500
From: Steven Rostedt <rostedt@...dmis.org>
To: "Masami Hiramatsu (Google)" <mhiramat@...nel.org>
Cc: Huang Yiwei <quic_hyiwei@...cinc.com>, <mark.rutland@....com>,
 <mcgrof@...nel.org>, <keescook@...omium.org>, <j.granados@...sung.com>,
 <mathieu.desnoyers@...icios.com>, <corbet@....net>,
 <linux-kernel@...r.kernel.org>, <linux-trace-kernel@...r.kernel.org>,
 <linux-fsdevel@...r.kernel.org>, <linux-doc@...r.kernel.org>,
 <quic_bjorande@...cinc.com>, <quic_tsoni@...cinc.com>,
 <quic_satyap@...cinc.com>, <quic_aiquny@...cinc.com>, <kernel@...cinc.com>,
 Ross Zwisler <zwisler@...gle.com>, Joel Fernandes <joel@...lfernandes.org>
Subject: Re: [PATCH v5] tracing: Support to dump instance traces by
 ftrace_dump_on_oops

On Mon, 26 Feb 2024 08:51:58 +0900
Masami Hiramatsu (Google) <mhiramat@...nel.org> wrote:

> On Thu, 8 Feb 2024 21:18:14 +0800
> Huang Yiwei <quic_hyiwei@...cinc.com> wrote:
> 
> > Currently ftrace only dumps the global trace buffer on an OOPs. For
> > debugging a production usecase, instance trace will be helpful to
> > check specific problems since global trace buffer may be used for
> > other purposes.
> > 
> > This patch extend the ftrace_dump_on_oops parameter to dump a specific
> > or multiple trace instances:
> > 
> >   - ftrace_dump_on_oops=0: as before -- don't dump
> >   - ftrace_dump_on_oops[=1]: as before -- dump the global trace buffer
> >   on all CPUs
> >   - ftrace_dump_on_oops=2 or =orig_cpu: as before -- dump the global
> >   trace buffer on CPU that triggered the oops
> >   - ftrace_dump_on_oops=<instance_name>: new behavior -- dump the
> >   tracing instance matching <instance_name>
> >   - ftrace_dump_on_oops[=2/orig_cpu],<instance1_name>[=2/orig_cpu],  
> 
> Would you mean "ftrace_dump_on_oops,<instance1_name>" ?

??

> As far as I can see, it doesn't work. Command line parser requires "="
> for parameter value. 

Not sure what you mean, but it does work with:

 ftrace_dump_on_oops=1,foo=2

As well as

 ftrace_dump_on_oops=foo


If you want to dump with an instance, yes you need a '=' sign.

> Also, is there any reason to limit the parameter
> to 2 or orig_cpu?

There's 3 options: 0 = off, 1 = all (default), 2 = orig_cpu

I don't see it limited.

You don't need the equal sign if you just want the top buffer.

> 
> What about this syntax?
> 
> ftrace_dump_on_oops=<0|1|2|orig_cpu>[,<instance_name>[=<1|2|orig_cpu>][,...]

That should work now. But why add the requirement of an '=' as that isn't
needed now? That is, the syntax is:

 ftrace_dump_on_oops[=[<0|1|2|orig_cpu>,][<instance_name>[=<1|2|orig_cpu>][,...]]

> 
> or
> 
> ftrace_dump_on_oops=instance_name[=<1|2|orig_cpu>][,...]

This works.

> 
> or
> 
> ftrace_dump_on_oops

This works.

> 
> e.g.
> "ftrace_dump_on_oops=0,foo=orig_cpu" is equal to "ftrace_dump_on_oops=foo=orig_cpu"
> 

And that does.

I think this patch does what you are asking for.

-- Steve

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ