[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <alpine.LFD.2.00.1009271953390.2416@localhost6.localdomain6>
Date: Mon, 27 Sep 2010 20:01:26 +0200 (CEST)
From: Thomas Gleixner <tglx@...utronix.de>
To: Tony Luck <tony.luck@...el.com>
cc: LKML <linux-kernel@...r.kernel.org>,
Linus Torvalds <torvalds@...ux-foundation.org>,
Andrew Morton <akpm@...ux-foundation.org>,
Ingo Molnar <mingo@...e.hu>,
Peter Zijlstra <peterz@...radead.org>,
Christoph Hellwig <hch@...radead.org>,
linux-alpha@...r.kernel.org, linux-cris-kernel@...s.com,
Haavard Skinnemoen <hskinnemoen@...el.com>,
linux-ia64@...r.kernel.org,
Yoshinori Sato <ysato@...rs.sourceforge.jp>,
Hirokazu Takata <takata@...ux-m32r.org>,
Greg Ungerer <gerg@...inux.org>, Jeff Dike <jdike@...toit.com>,
linux-parisc@...r.kernel.org, Chris Zankel <chris@...kel.net>,
linux-arch@...r.kernel.org
Subject: Re: [RFC trollpatch 1/1] genirq: Remove the fits all and nothing
__do_IRQ() code
On Mon, 27 Sep 2010, Tony Luck wrote:
> On Wed, Sep 8, 2010 at 11:14 AM, Thomas Gleixner <tglx@...utronix.de> wrote:
> > The following architectures are still using __do_IRQ():
> >
> > alpha, cris, ia64, h8300, m32r, m68knommu, parisc, um
>
> Thomas,
>
> I (belatedly) took a look at fixing ia64 ... but I've run into a small snag.
> The __do_IRQ() routine makes a call to:
>
> desc->chip->end(irq);
>
> while neither of the "handle_level_irq()" nor "handle_edge_irq()"
> functions do this.
>
> On ia64 iosapic_end_level_irq() call iosapic_eoi() for me. Without it
> my system hangs during boot (with some driver timeout complaining
> about dropped interrupts).
>
> Is the omission of desc->chip->end(irq); deliberate? In which case
> I need to find another place to call iosapic_eoi(). Or is it accidental?
No, it's deliberate. The solution is to use the correct flow handler
for your device. We have currently several flow handlers implemented:
handle_level_irq
{
if (chip->mask_ack)
chip->mask_ack()
else {
chip->mask();
if (chip->ack)
chip->ack();
}
....
chip->unmask();
}
handle_edge_irq
{
chip->ack()
...
}
handle_simple_irq
{
...
}
handle_fasteoi_irq
{
...
chip->eoi();
}
handle_percpu_irq
{
if (chip->ack)
chip->ack();
if (chip->eoi)
chip->eoi();
}
Note, that handle_percpu_irq does not take the irq_desc->lock.
So the trick is to select the matching handler and have separate irq
chip implementations if necessary.
Hope that helps.
Thanks,
tglx
Powered by blists - more mailing lists