From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Peter Zijlstra <peterz@infradead.org>
Cc: Linux-Kernel List <linux-kernel@vger.kernel.org>,
Steven Rostedt <rostedt@goodmis.org>,
linuxppc-dev list <linuxppc-dev@ozlabs.org>,
Thomas Gleixner <tglx@linutronix.de>, Ingo Molnar <mingo@elte.hu>
Subject: Re: spin_is_locked() broken for uniprocessor?
Date: Thu, 27 Aug 2009 19:32:34 +1000 [thread overview]
Message-ID: <1251365554.20467.51.camel@pasglop> (raw)
In-Reply-To: <1250674870.7583.334.camel@twins>
On Wed, 2009-08-19 at 11:41 +0200, Peter Zijlstra wrote:
> > > > which implies to me that spin_is_locked() will always return
> false. Is this
> > > > expected behavior.
> > >
> > > That's wrong. spin_is_locked should always return true on UP.
> >
> > Surely it's not that simple? Maybe spin_is_lock() should be
> undefined on UP.
>
> #define spin_is_locked(l) panic()
>
> should sort things out quickly ;-)
Not defining it would sort things out even faster and avoid nasty case
of system panic'ing when a module is loaded :-)
Cheers,
Ben.
WARNING: multiple messages have this Message-ID (diff)
From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Peter Zijlstra <peterz@infradead.org>
Cc: David Howells <dhowells@redhat.com>,
Steven Rostedt <rostedt@goodmis.org>,
Linux-Kernel List <linux-kernel@vger.kernel.org>,
linuxppc-dev list <linuxppc-dev@ozlabs.org>,
Thomas Gleixner <tglx@linutronix.de>, Ingo Molnar <mingo@elte.hu>
Subject: Re: spin_is_locked() broken for uniprocessor?
Date: Thu, 27 Aug 2009 19:32:34 +1000 [thread overview]
Message-ID: <1251365554.20467.51.camel@pasglop> (raw)
In-Reply-To: <1250674870.7583.334.camel@twins>
On Wed, 2009-08-19 at 11:41 +0200, Peter Zijlstra wrote:
> > > > which implies to me that spin_is_locked() will always return
> false. Is this
> > > > expected behavior.
> > >
> > > That's wrong. spin_is_locked should always return true on UP.
> >
> > Surely it's not that simple? Maybe spin_is_lock() should be
> undefined on UP.
>
> #define spin_is_locked(l) panic()
>
> should sort things out quickly ;-)
Not defining it would sort things out even faster and avoid nasty case
of system panic'ing when a module is loaded :-)
Cheers,
Ben.
next prev parent reply other threads:[~2009-08-27 9:33 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-08-18 22:09 spin_is_locked() broken for uniprocessor? Kumar Gala
2009-08-18 22:09 ` Kumar Gala
2009-08-18 22:24 ` Thomas Gleixner
2009-08-18 22:24 ` Thomas Gleixner
2009-08-19 9:38 ` David Howells
2009-08-19 9:38 ` David Howells
2009-08-19 9:41 ` Peter Zijlstra
2009-08-19 9:41 ` Peter Zijlstra
2009-08-27 9:32 ` Benjamin Herrenschmidt [this message]
2009-08-27 9:32 ` Benjamin Herrenschmidt
2009-08-19 10:53 ` Alan Cox
2009-08-19 10:53 ` Alan Cox
2009-08-19 11:16 ` Leon Woestenberg
2009-08-19 11:16 ` Leon Woestenberg
2009-08-19 11:23 ` Peter Zijlstra
2009-08-19 11:23 ` 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=1251365554.20467.51.camel@pasglop \
--to=benh@kernel.crashing.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxppc-dev@ozlabs.org \
--cc=mingo@elte.hu \
--cc=peterz@infradead.org \
--cc=rostedt@goodmis.org \
--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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.