From: Steven Rostedt <rostedt@goodmis.org>
To: Peter Zijlstra <peterz@infradead.org>
Cc: Ingo Molnar <mingo@elte.hu>, LKML <linux-kernel@vger.kernel.org>,
Andrew Morton <akpm@linux-foundation.org>,
Frederic Weisbecker <fweisbec@gmail.com>
Subject: Re: [PATCH 0/5] [GIP PULL] tracing/events/trace_stack: various fixes
Date: Mon, 8 Jun 2009 12:22:21 -0400 (EDT) [thread overview]
Message-ID: <alpine.DEB.2.00.0906081220040.9522@gandalf.stny.rr.com> (raw)
In-Reply-To: <1244477919.13761.9042.camel@twins>
On Mon, 8 Jun 2009, Peter Zijlstra wrote:
> On Mon, 2009-06-08 at 11:37 -0400, Steven Rostedt wrote:
> > [ Added Peter ]
> >
> > On Sun, 7 Jun 2009, Ingo Molnar wrote:
> > > Testing tracer sched_switch: <6>Starting ring buffer hammer
> > > PASSED
> > > Testing tracer sysprof: PASSED
> > > Testing tracer function: PASSED
> > > Testing tracer irqsoff:
> > > =============================================
> > > PASSED
> > > Testing tracer preemptoff: PASSED
> > > Testing tracer preemptirqsoff: [ INFO: possible recursive locking detected ]
> > > PASSED
> > > Testing tracer branch: 2.6.30-rc8-tip-01972-ge5b9078-dirty #5760
> > > ---------------------------------------------
> > > rb_consumer/431 is trying to acquire lock:
> > > (&cpu_buffer->reader_lock){......}, at: [<c109eef7>] ring_buffer_reset_cpu+0x37/0x70
> > >
> > > but task is already holding lock:
> > > (&cpu_buffer->reader_lock){......}, at: [<c10a019e>] ring_buffer_consume+0x7e/0xc0
> > >
> > > other info that might help us debug this:
> > > 1 lock held by rb_consumer/431:
> > > #0: (&cpu_buffer->reader_lock){......}, at: [<c10a019e>] ring_buffer_consume+0x7e/0xc0
> >
> > Yes this definitely looks like ftrace is tracing the ring buffer benchmark
> > test.
> >
> > OK, how do I go about teaching lockdep that this reader lock is not the
> > same reader lock as the one being taken?
>
> Something like this will put each ring-buffer user in its own lock
> class.
Thanks a lot Peter. I'll see if I can get this to work and then push it
off to Ingo to see if it fixes his lockdep bugs.
>
> Patch utterly uncompiled and broken since hotplug would need some care
> (you could probably store the key pointer in the rb object and reuse it
> on hotplug).
I could also save the key in the ring buffer itself. Each of the per cpu
reader locks will share the same key, and then when it is created by the
hotplug, it will use the key of the ring buffer.
-- Steve
next prev parent reply other threads:[~2009-06-08 16:22 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-06-03 15:17 Steven Rostedt
2009-06-03 15:17 ` [PATCH 1/5] tracing/trace_stack: fix the number of entries in the header Steven Rostedt
2009-06-03 15:17 ` [PATCH 2/5] tracing/events: fix output format of kernel stack Steven Rostedt
2009-06-03 15:17 ` [PATCH 3/5] tracing/events: fix output format of user stack Steven Rostedt
2009-06-03 15:17 ` [PATCH 4/5] tracing: fix multiple use of __print_flags and __print_symbolic Steven Rostedt
2009-06-03 15:17 ` [PATCH 5/5] tracing: add annotation to what type of stack trace is recorded Steven Rostedt
2009-06-05 14:52 ` [PATCH 0/5] [GIP PULL] tracing/events/trace_stack: various fixes Ingo Molnar
2009-06-07 8:22 ` Ingo Molnar
2009-06-08 15:37 ` Steven Rostedt
2009-06-08 16:18 ` Peter Zijlstra
2009-06-08 16:22 ` Steven Rostedt [this message]
2009-06-08 23:00 ` [PATCH][GIT PULL] ring-buffer: pass in lockdep class key for reader_lock Steven Rostedt
2009-06-09 11:20 ` Ingo Molnar
2009-06-09 11:44 ` Steven Rostedt
2009-06-09 12:03 ` Ingo Molnar
2009-06-09 14:52 ` [tip:tracing/core] " tip-bot for Peter Zijlstra
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=alpine.DEB.2.00.0906081220040.9522@gandalf.stny.rr.com \
--to=rostedt@goodmis.org \
--cc=akpm@linux-foundation.org \
--cc=fweisbec@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=peterz@infradead.org \
/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
all inboxes | Powered by JetHome®