// SPDX-License-Identifier: GPL-2.0-only1/*2* Copyright (C) 2011-12 Synopsys, Inc. (www.synopsys.com)3*/45#include <linux/interrupt.h>6#include <linux/irqchip.h>7#include <asm/mach_desc.h>89#include <asm/irq_regs.h>10#include <asm/smp.h>1112/*13* Late Interrupt system init called from start_kernel for Boot CPU only14*15* Since slab must already be initialized, platforms can start doing any16* needed request_irq( )s17*/18void __init init_IRQ(void)19{20/*21* process the entire interrupt tree in one go22* Any external intc will be setup provided DT chains them23* properly24*/25irqchip_init();2627#ifdef CONFIG_SMP28/* a SMP H/w block could do IPI IRQ request here */29if (plat_smp_ops.init_per_cpu)30plat_smp_ops.init_per_cpu(smp_processor_id());31#endif3233if (machine_desc->init_per_cpu)34machine_desc->init_per_cpu(smp_processor_id());35}3637/*38* "C" Entry point for any ARC ISR, called from low level vector handler39* @irq is the vector number read from ICAUSE reg of on-chip intc40*/41void arch_do_IRQ(unsigned int hwirq, struct pt_regs *regs)42{43struct pt_regs *old_regs;4445irq_enter();46old_regs = set_irq_regs(regs);47generic_handle_domain_irq(NULL, hwirq);48set_irq_regs(old_regs);49irq_exit();50}515253