Generic Linux architectural discussions
 help / color / mirror / Atom feed
From: Thomas Gleixner <tglx@linutronix.de>
To: Andi Kleen <andi@firstfloor.org>
Cc: Linus Torvalds <torvalds@osdl.org>,
	LKML <linux-kernel@vger.kernel.org>,
	linux-arch@vger.kernel.org,
	Andrew Morton <akpm@linux-foundation.org>,
	Ingo Molnar <mingo@elte.hu>,
	Peter Zijlstra <peterz@infradead.org>,
	Alan Cox <alan@lxorguk.ukuu.org.uk>,
	David Miller <davem@davemloft.net>,
	Greg Kroah-Hartman <gregkh@suse.de>,
	Arnaldo Carvalho de Melo <acme@redhat.com>
Subject: Re: [patch 1/2] genirq: Run irq handlers with interrupts disabled
Date: Fri, 26 Mar 2010 14:05:28 +0100 (CET)	[thread overview]
Message-ID: <alpine.LFD.2.00.1003261224070.3147@localhost.localdomain> (raw)
In-Reply-To: <20100326061310.GV20695@one.firstfloor.org>

On Fri, 26 Mar 2010, Andi Kleen wrote:

> > Drivers for whacky hardware still can reenable them in the handler
> > itself, if the need arises. (They do already due to lockdep)
> 
> Can you please explain that lockdep reference?
> I don't think lockdep really forces on interrupts, does it?

Lockdep forces interrupts off. It yells at anyone enabling irqs in the
handler. The ones which do that have been annotated with
local_irq_enable_in_hardirq(), which is a nop for lockdep.

> BTW the one problem I have with this patchkit is that it's clearly
> no stable candidate and I was hoping for a stable fix too.
> Any chance to at least approve my original patch for .32/.33 only?

Why not simply force IRQF_DISABLED for all MSI interrupts. That still
allows nesting for non MSI ones, but it limits the chance of throwing
up reasonably well. That's a two liner.

Can you please test whether it resolves the issue at hand ?

Thanks,

	tglx
---
diff --git a/kernel/irq/manage.c b/kernel/irq/manage.c
index eb6078c..1d55e92 100644
--- a/kernel/irq/manage.c
+++ b/kernel/irq/manage.c
@@ -735,6 +735,9 @@ __setup_irq(unsigned int irq, struct irq_desc *desc, struct irqaction *new)
 		if (new->flags & IRQF_ONESHOT)
 			desc->status |= IRQ_ONESHOT;
 
+		if (desc->msi_desc)
+			new->flags |= IRQF_DISABLED;
+
 		if (!(desc->status & IRQ_NOAUTOEN)) {
 			desc->depth = 0;
 			desc->status &= ~IRQ_DISABLED;

  reply	other threads:[~2010-03-26 13:07 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-03-26  0:06 [patch 0/2] Run interrupt handlers always with interrupts disabled Thomas Gleixner
2010-03-26  0:06 ` [patch 1/2] genirq: Run irq handlers " Thomas Gleixner
2010-03-26  6:13   ` Andi Kleen
2010-03-26 13:05     ` Thomas Gleixner [this message]
2010-03-30  5:33       ` Andi Kleen
2010-03-31 11:16         ` Thomas Gleixner
2010-04-02  9:31           ` Pavel Machek
2010-04-02 20:42             ` Thomas Gleixner
2010-04-02 21:09               ` Pavel Machek
2010-04-02 21:31                 ` Peter Zijlstra
2010-04-02 22:51                 ` Thomas Gleixner
2010-04-03  4:45                   ` Pavel Machek
2010-04-03  4:45                     ` Pavel Machek
2010-05-25 20:32   ` Venkatesh Pallipadi
2010-03-26  0:06 ` [patch 2/2] genirq: Remove IRQF_DISABLED from core code Thomas Gleixner
2010-03-26  0:06   ` Thomas Gleixner
2010-03-26  6:20   ` Andi Kleen
2010-03-26 11:19     ` Thomas Gleixner
2010-03-26 11:19       ` Thomas Gleixner
2010-03-26  3:34 ` [patch 0/2] Run interrupt handlers always with interrupts disabled David Miller
2010-03-26  8:14 ` Russell King
2010-03-26  8:14   ` Russell King
2010-03-26  9:20   ` Ingo Molnar
2010-03-26  9:20     ` Ingo Molnar
2010-03-26  9:28     ` Peter Zijlstra
2010-03-26 12:02       ` Jamie Lokier
2010-03-26  9:59     ` Alan Cox
2010-03-26 10:08       ` Peter Zijlstra
2010-03-26 10:12         ` Andi Kleen
2010-03-26 10:53         ` Ingo Molnar
2010-03-26 12:00         ` Nicolas Pitre
2010-03-26 12:06           ` Jamie Lokier

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.LFD.2.00.1003261224070.3147@localhost.localdomain \
    --to=tglx@linutronix.de \
    --cc=acme@redhat.com \
    --cc=akpm@linux-foundation.org \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=andi@firstfloor.org \
    --cc=davem@davemloft.net \
    --cc=gregkh@suse.de \
    --cc=linux-arch@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=peterz@infradead.org \
    --cc=torvalds@osdl.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