Skip to content

Commit 24dc170

Browse files
avpatelpalmer-dabbelt
authored andcommitted
RISC-V: Remove do_IRQ() function
The only thing do_IRQ() does is call handle_arch_irq function pointer. We can very well call handle_arch_irq function pointer directly from assembly and remove do_IRQ() function hence this patch. Signed-off-by: Anup Patel <[email protected]> Reviewed-by: Atish Patra <[email protected]> Signed-off-by: Palmer Dabbelt <[email protected]>
1 parent 033a65d commit 24dc170

File tree

2 files changed

+3
-7
lines changed

2 files changed

+3
-7
lines changed

arch/riscv/kernel/entry.S

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,9 @@ _save_context:
106106

107107
/* Handle interrupts */
108108
move a0, sp /* pt_regs */
109-
tail do_IRQ
109+
la a1, handle_arch_irq
110+
REG_L a1, (a1)
111+
jr a1
110112
1:
111113
/*
112114
* Exceptions run with interrupts enabled or disabled depending on the

arch/riscv/kernel/irq.c

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,6 @@ int arch_show_interrupts(struct seq_file *p, int prec)
1616
return 0;
1717
}
1818

19-
asmlinkage __visible void __irq_entry do_IRQ(struct pt_regs *regs)
20-
{
21-
if (handle_arch_irq)
22-
handle_arch_irq(regs);
23-
}
24-
2519
void __init init_IRQ(void)
2620
{
2721
irqchip_init();

0 commit comments

Comments
 (0)