Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

irqchip: mips-gic: Don't treat FDC IRQ as percpu devid

Treat the Fast Debug Channel (FDC) interrupt the same as the timer and
performance counter interrupts. Like them, the FDC IRQ is also per-VPE,
and also doesn't use a per-CPU device ID yet. Per-CPU device IDs don't
seem to work with IRQF_SHARED which is needed for compatibility with
cores which don't route the FDC IRQ through the GIC. For hardware which
routes FDC IRQs through the GIC this is something that could be added
later.

Signed-off-by: James Hogan <james.hogan@imgtec.com>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: Andrew Bresticker <abrestic@chromium.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Jason Cooper <jason@lakedaemon.net>
Cc: linux-mips@linux-mips.org
Cc: linux-kernel@vger.kernel.org
Patchwork: https://patchwork.linux-mips.org/patch/9141/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>

authored by

James Hogan and committed by
Ralf Baechle
b720fd8b 8f7ff027

+10 -5
+10 -5
drivers/irqchip/irq-mips-gic.c
··· 592 592 * of the MIPS kernel code does not use the percpu IRQ API for 593 593 * the CP0 timer and performance counter interrupts. 594 594 */ 595 - if (intr != GIC_LOCAL_INT_TIMER && intr != GIC_LOCAL_INT_PERFCTR) { 595 + switch (intr) { 596 + case GIC_LOCAL_INT_TIMER: 597 + case GIC_LOCAL_INT_PERFCTR: 598 + case GIC_LOCAL_INT_FDC: 599 + irq_set_chip_and_handler(virq, 600 + &gic_all_vpes_local_irq_controller, 601 + handle_percpu_irq); 602 + break; 603 + default: 596 604 irq_set_chip_and_handler(virq, 597 605 &gic_local_irq_controller, 598 606 handle_percpu_devid_irq); 599 607 irq_set_percpu_devid(virq); 600 - } else { 601 - irq_set_chip_and_handler(virq, 602 - &gic_all_vpes_local_irq_controller, 603 - handle_percpu_irq); 608 + break; 604 609 } 605 610 606 611 spin_lock_irqsave(&gic_lock, flags);