LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: Peter Zijlstra <peterz@infradead.org>
To: David Brownell <david-b@pacbell.net>
Cc: Pierre Ossman <drzeus-mmc@drzeus.cx>,
	lkml <linux-kernel@vger.kernel.org>, Ingo Molnar <mingo@elte.hu>,
	Russell King <rmk@arm.linux.org.uk>,
	Nicolas Ferre <nicolas.ferre@rfo.atmel.com>,
	Andrew Victor <linux@maxim.org.za>,
	Thomas Gleixner <tglx@linutronix.de>
Subject: Re: [patch 2.6.28-rc2] at91_mci: workaround lockdep
Date: Tue, 28 Oct 2008 18:04:02 +0100	[thread overview]
Message-ID: <1225213442.15763.20.camel@lappy.programming.kicks-ass.net> (raw)
In-Reply-To: <200810271426.27110.david-b@pacbell.net>

On Mon, 2008-10-27 at 14:26 -0700, David Brownell wrote:
> From: David Brownell <dbrownell@users.sourceforge.net>
> 
> Lockdep reported a problem in the at91_mci driver ... in this case, the
> issue is with lockdep, not with the driver.  A trimmed stack dump, from
> trying to boot with root on MMC, shows:
> 
>   WARNING: at kernel/lockdep.c:2195 trace_hardirqs_on_caller+0xf4/0x170()
>   Modules linked in:
>   [<c005bc98>] (trace_hardirqs_on+0x0/0x18) from [<c0213bf4>] (_spin_unlock_irq+0x2c/0x3c)
>   [<c0213bc8>] (_spin_unlock_irq+0x0/0x3c) from [<c0029a88>] (flush_dcache_page+0x114/0x144)
>   [<c0029974>] (flush_dcache_page+0x0/0x144) from [<c019b034>] (at91_mci_irq+0x150/0x414)
>   [<c019aee4>] (at91_mci_irq+0x0/0x414) from [<c0066c5c>] (handle_IRQ_event+0x2c/0x6c)
>   [<c0066c30>] (handle_IRQ_event+0x0/0x6c) from [<c0068a60>] (handle_level_irq+0x108/0x124)
>   [<c0068958>] (handle_level_irq+0x0/0x124) from [<c0022064>] (__exception_text_start+0x64/0x90)
> 
> When __flush_dcache_aliases() returns -- inlined into flush_dcache_page(),
> above -- it re-enables IRQs ... since that evidently may only be called with
> IRQs enabled.  That's OK since the (unshared) IRQ handler doesn't ask for IRQs
> to be disabled.   Except ... that lockdep went and disabled them, then went on
> to complains about the breakage *it* caused!
> 
> Workaround: depend on LOCKDEP=n ... and for paranoia, disable IRQF_SHARED
> for this interrupt.  (At the hardware level, this is dedicated to MCI, so
> there's never a need for multiple handlers.)

In all previous such cases it was deemed the IRQ handler should deal
with whatever it gets.


  reply	other threads:[~2008-10-28 17:04 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-27 21:26 David Brownell
2008-10-28 17:04 ` Peter Zijlstra [this message]
2008-10-28 17:22   ` David Brownell
2008-10-28 17:36     ` Peter Zijlstra
2008-10-28 19:41       ` David Brownell
2008-10-29  7:20     ` David Brownell
2008-11-03 13:47     ` Nicolas Ferre
2008-11-17  9:28 ` Nicolas Ferre
2008-11-19 18:45   ` Pierre Ossman
2008-11-20 15:02     ` Nicolas Ferre
2008-11-20 15:42       ` Pierre Ossman
2008-11-23 14:26   ` 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=1225213442.15763.20.camel@lappy.programming.kicks-ass.net \
    --to=peterz@infradead.org \
    --cc=david-b@pacbell.net \
    --cc=drzeus-mmc@drzeus.cx \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@maxim.org.za \
    --cc=mingo@elte.hu \
    --cc=nicolas.ferre@rfo.atmel.com \
    --cc=rmk@arm.linux.org.uk \
    --cc=tglx@linutronix.de \
    --subject='Re: [patch 2.6.28-rc2] at91_mci: workaround lockdep' \
    /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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).