From: Andrew Morton <akpm@osdl.org>
To: Zwane Mwaikambo <zwane@holomorphy.com>
Cc: piotr@larroy.com, linux-kernel@vger.kernel.org
Subject: Re: [PATCH][BUG] Badness in smp_call_function at arch/i386/kernel/smp.c:552
Date: Thu, 2 Dec 2004 23:36:11 -0800 [thread overview]
Message-ID: <20041202233611.256fcf3f.akpm@osdl.org> (raw)
In-Reply-To: <Pine.LNX.4.61.0412030005070.21568@montezuma.fsmlabs.com>
Zwane Mwaikambo <zwane@holomorphy.com> wrote:
>
> > Well, sort-of.
> >
> > If __handle_sysrq was really a normal IRQ handler then the correct thing to
> > do here is to replace spin_lock_irqsave() with spin_lock(). But
> > __handle_sysrq() can also be called via /proc/sysrq-trigger and via the
> > handlers of multiple interrupt sources. So we're stuck with using
> > spin_lock_irqsave().
> >
> > However enabling interrupts as you've done menas that theoretically we
> > could deadlock on sysrq_key_table_lock if another sysrq happens at the
> > wrong time.
> >
> > Which deadlock opportunity would you prefer? ;)
>
> Agreed, there is actually a higher chance of the smp_call_function
> deadlock occuring since the __handle_sysrq one relies on another sysrq
> event occuring via a different IRQ line interrupt handler, so
> we would have to do sysrq via serial and then sysrq via keyboard to cause
> the deadlock. Perhaps just make it a spin_trylock?
Well yeah, but it's so much fuss for such a silly problem.
How about a local_irq_enable() in sysrq_handle_reboot()?
next prev parent reply other threads:[~2004-12-03 7:36 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-12-02 21:03 [BUG] Badness in smp_call_function at arch/i386/kernel/smp.c:552 Pedro Larroy
2004-12-03 4:56 ` [PATCH][BUG] " Zwane Mwaikambo
2004-12-03 7:01 ` Andrew Morton
2004-12-03 7:29 ` Zwane Mwaikambo
2004-12-03 7:36 ` Andrew Morton [this message]
2004-12-03 7:43 ` Zwane Mwaikambo
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=20041202233611.256fcf3f.akpm@osdl.org \
--to=akpm@osdl.org \
--cc=linux-kernel@vger.kernel.org \
--cc=piotr@larroy.com \
--cc=zwane@holomorphy.com \
/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