Re: [PATCH] rcu/tree: Add a trace event for RCU stall warnings

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Sangmoon,


On 2/22/2021 1:55 PM, Sangmoon Kim wrote:


-----Original Message-----
From: Paul E. McKenney <paulmck@xxxxxxxxxx>
Sent: Friday, February 19, 2021 3:59 AM

On Thu, Feb 18, 2021 at 01:24:16PM -0500, Steven Rostedt wrote:
On Thu, 18 Feb 2021 09:00:12 -0800
"Paul E. McKenney" <paulmck@xxxxxxxxxx> wrote:

OK, I will bite.  ;-)

Do I turn into a wearwolf?

Maybe even a wash-n-wear wolf.  ;-)

Can the saving of console into trace buffers be easily enabled and
disabled within the code?

Well, we do have this for ftrace:

  echo 'enable_event:printk:console' > events/rcu/rcu_stall_warning/trigger

Would enable the printk console to be traced to the ring buffer once the
stall is triggered, and not before hand.

  If so, does enabling and disabling nest?

It has a disable as well, but unfortunately its global and does not nest.
We could always implement a percpu trigger that can nest though.

So Sangmoon could have a module react to an RCU CPU stall warning
tracepoint by turning on tracing of console messages.  If there was a
start-stop pair of RCU CPU stall warning tracepoints, he could turn it
off as well.

Not sure if that is what Sangmoon is looking for, but it is a possibility.

							Thanx, Paul

Thank you. I'm learning the new things through this review.

Copying console messages is not really necessary to me. I wanted to say
this tracepoint can also be used in such way for debugging purpose.


In case we want to use this trace event, to capture RCU stall information, which comes on console, into trace buffers; why not have these events at the start of the functions like print_other_cpu_stall(), print_cpu_stall() rather than at the end ?


Thanks
Neeraj

What I need is that a module records the stall happening and report the
stall event when kernel panic occurred. Of course, there is no detailed
information there, but it helps developers to recognize that the stall
has occurred in the system.

The usage scenario is as follows.
There is a kernel module for debugging.
The module registers a probe function using register_trace_rcu_stall_warning().
When a stall warning event occurs, the module records the event into its own buffer.
When a kernel panic occurs, the developers can see the report generated
by the module and can also see the buffer of the module directly through Ramdump.

Thanks,
Sangmoon


--
QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, hosted by The Linux Foundation



[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux