From: John Kacur <jkacur@redhat.com>
To: Steven Rostedt <rostedt@goodmis.org>
Cc: mingo@elte.hu, Roland Dreier <rolandd@cisco.com>,
Sean Hefty <sean.hefty@intel.com>,
Hal Rosenstock <hal.rosenstock@gmail.com>,
tglx@linutronix.de, Peter Zijlstra <a.p.zijlstra@chello.nl>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] ib-release-locks-in-the-proper-order
Date: Mon, 21 Sep 2009 17:48:36 -0400 (EDT) [thread overview]
Message-ID: <688625294.427351253569716504.JavaMail.root@zmail07.collab.prod.int.phx2.redhat.com> (raw)
In-Reply-To: <1253567867.2935.4.camel@frodo>
----- "Steven Rostedt" <rostedt@goodmis.org> wrote:
> On Mon, 2009-09-21 at 21:35 +0200, John Kacur wrote:
> > Please consider the following patch - originally from Steven
> Rostedt.
> > It solves a problem for rt which is very sensitive to the lock
> ordering.
> > It should have a no impact on non-rt.
> >
> > The patch applies to current tip/master - but it is fine with me if
> it
> > would be more appropriate for one of the infiniband people to take
> it.
> >
> > Thanks
> >
> > >From e533f2b9ee9b0bd95aaa4c3369e79b350c9895d3 Mon Sep 17 00:00:00
> 2001
> > From: Steven Rostedt <srostedt@redhat.com>
> > Date: Mon, 21 Sep 2009 21:23:46 +0200
> > Subject: [PATCH] ib: release locks in the proper order
> >
> > RT is very sensitive to the order locks are taken and released
> > wrt read write locks. We must do
> >
> > lock(a);
> > lock(b);
> > lock(c);
> >
> > [...]
> >
> > unlock(c);
> > unlock(b);
> > unlock(a);
> >
> > otherwise bad things can happen.
> >
> > Signed-off-by: Ken Cox <jkc@redhat.com>
> > Signed-off-by: Clark Williams <williams@redhat.com>
> > Signed-off-by: John Kacur <jkacur@redhat.com>
>
> The -rt patch doesn't use the multi rwlock code anymore (the reason
> for
> the first patch), and the last revision of that code was able to
> handle
> that too.
>
> Linus totally ripped into this idea. A lock must be able to handle
> any
> order of unlocking. There should be no technical reason a lock must
> be
> unlocked in reverse order they were locked.
>
> What exactly is sensitive about this?
>
Thanks Steve!
I hereby withdraw this patch!!!!
prev parent reply other threads:[~2009-09-21 21:48 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-09-21 19:35 John Kacur
2009-09-21 21:17 ` Steven Rostedt
2009-09-21 21:48 ` John Kacur [this message]
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=688625294.427351253569716504.JavaMail.root@zmail07.collab.prod.int.phx2.redhat.com \
--to=jkacur@redhat.com \
--cc=a.p.zijlstra@chello.nl \
--cc=hal.rosenstock@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=rolandd@cisco.com \
--cc=rostedt@goodmis.org \
--cc=sean.hefty@intel.com \
--cc=tglx@linutronix.de \
/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®