Thread (4 messages) 4 messages, 4 authors, 2011-11-03

[PATCHv2 02/10] ARM: vic: MULTI_IRQ_HANDLER handler

From: Jamie Iles <hidden>
Date: 2011-11-03 13:04:18
Also in: linux-devicetree

Possibly related (same subject, not in this thread)

On Thu, Nov 03, 2011 at 02:00:15PM +0100, Linus Walleij wrote:
On Thu, Nov 3, 2011 at 1:51 PM, Russell King - ARM Linux
[off-list ref] wrote:
quoted
? ? ? ?stat = readl_relaxed(vic->base + VIC_IRQ_STATUS);
? ? ? ?while (stat) {
? ? ? ? ? ? ? ?while (stat) {
? ? ? ? ? ? ? ? ? ? ? ?irq = ffs(stat) - 1;
? ? ? ? ? ? ? ? ? ? ? ?stat &= ~(1 << irq);
? ? ? ? ? ? ? ? ? ? ? ?handle_irq(irq);
? ? ? ? ? ? ? ?}
? ? ? ? ? ? ? ?stat = readl_relaxed(vic->base + VIC_IRQ_STATUS);
? ? ? ?}

This ensures that we process all interrupts found pending before we
re-check for any new interrupts pending. ?Arguably this is a much
fairer implementation (and may mean if things get irrevokably stuck,
things like sysrq via the console uart may still work.)
I really like the looks of this, Jamie can you do it like that?
Yup, I'll respin either tonight or tomorrow night and rebase ontop of 
the asm/exception.h patch.  Do we also want the behaviour so that it 
keeps looping over all VIC's until there are no pending interrupts?  I 
think that's probably worth it.
Maybe some smallish comment about what's going on can be
good for future generations reading that code...
OK, will do.

Thanks Linus and Russell!

Jamie
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help