From 4eca58d38b42ad92c71a00efb8e67061d4ede132 Mon Sep 17 00:00:00 2001 From: Will Deacon Date: Thu, 5 Apr 2012 19:42:10 +0100 Subject: [PATCH] --- yaml --- r: 299268 b: refs/heads/master c: 34af657916332e89564566bc8d35e3e06cc0c236 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/arch/arm/common/vic.c | 9 ++++----- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/[refs] b/[refs] index 2af178c1278a..9a5085347401 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: dff2aa7af8c96a11f75d858859f0e0c78b193d12 +refs/heads/master: 34af657916332e89564566bc8d35e3e06cc0c236 diff --git a/trunk/arch/arm/common/vic.c b/trunk/arch/arm/common/vic.c index 7a66311f3066..7e288f96cedf 100644 --- a/trunk/arch/arm/common/vic.c +++ b/trunk/arch/arm/common/vic.c @@ -427,19 +427,18 @@ int __init vic_of_init(struct device_node *node, struct device_node *parent) /* * Handle each interrupt in a single VIC. Returns non-zero if we've - * handled at least one interrupt. This does a single read of the - * status register and handles all interrupts in order from LSB first. + * handled at least one interrupt. This reads the status register + * before handling each interrupt, which is necessary given that + * handle_IRQ may briefly re-enable interrupts for soft IRQ handling. */ static int handle_one_vic(struct vic_device *vic, struct pt_regs *regs) { u32 stat, irq; int handled = 0; - stat = readl_relaxed(vic->base + VIC_IRQ_STATUS); - while (stat) { + while ((stat = readl_relaxed(vic->base + VIC_IRQ_STATUS))) { irq = ffs(stat) - 1; handle_IRQ(irq_find_mapping(vic->domain, irq), regs); - stat &= ~(1 << irq); handled = 1; }