diff options
author | Qais Yousef <[email protected]> | 2015-12-08 13:20:26 +0000 |
---|---|---|
committer | Thomas Gleixner <[email protected]> | 2016-02-25 10:56:58 +0100 |
commit | 78930f09b9406db029c69dcebad10cd7b6e06fae (patch) | |
tree | 96e8348772a6cad8e8468837d56cbabc681887f0 | |
parent | 2a07870511829977d02609dac6450017b0419ea9 (diff) |
irqchip/mips-gic: Clear percpu_masks correctly when mapping
When setting the mapping for a hwirq, make sure we clear percpu_masks for
all other cpus in case it was set previously.
Signed-off-by: Qais Yousef <[email protected]>
Acked-by: Ralf Baechle <[email protected]>
Cc: <[email protected]>
Cc: <[email protected]>
Cc: <[email protected]>
Cc: <[email protected]>
Cc: <[email protected]>
Cc: Qais Yousef <[email protected]>
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Thomas Gleixner <[email protected]>
-rw-r--r-- | drivers/irqchip/irq-mips-gic.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/irqchip/irq-mips-gic.c b/drivers/irqchip/irq-mips-gic.c index 1fe73a191120..83395bf834c8 100644 --- a/drivers/irqchip/irq-mips-gic.c +++ b/drivers/irqchip/irq-mips-gic.c @@ -773,6 +773,7 @@ static int gic_shared_irq_domain_map(struct irq_domain *d, unsigned int virq, { int intr = GIC_HWIRQ_TO_SHARED(hw); unsigned long flags; + int i; irq_set_chip_and_handler(virq, &gic_level_irq_controller, handle_level_irq); @@ -780,6 +781,8 @@ static int gic_shared_irq_domain_map(struct irq_domain *d, unsigned int virq, spin_lock_irqsave(&gic_lock, flags); gic_map_to_pin(intr, gic_cpu_pin); gic_map_to_vpe(intr, vpe); + for (i = 0; i < gic_vpes; i++) + clear_bit(intr, pcpu_masks[i].pcpu_mask); set_bit(intr, pcpu_masks[vpe].pcpu_mask); spin_unlock_irqrestore(&gic_lock, flags); |