Skip to content

Commit

Permalink
RISC-V: Remove do_IRQ() function
Browse files Browse the repository at this point in the history
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 <anup.patel@wdc.com>
Reviewed-by: Atish Patra <atish.patra@wdc.com>
Signed-off-by: Palmer Dabbelt <palmerdabbelt@google.com>
  • Loading branch information
Anup Patel authored and Palmer Dabbelt committed Jun 10, 2020
1 parent 033a65d commit 24dc170
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 7 deletions.
4 changes: 3 additions & 1 deletion arch/riscv/kernel/entry.S
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,9 @@ _save_context:

/* Handle interrupts */
move a0, sp /* pt_regs */
tail do_IRQ
la a1, handle_arch_irq
REG_L a1, (a1)
jr a1
1:
/*
* Exceptions run with interrupts enabled or disabled depending on the
Expand Down
6 changes: 0 additions & 6 deletions arch/riscv/kernel/irq.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,6 @@ int arch_show_interrupts(struct seq_file *p, int prec)
return 0;
}

asmlinkage __visible void __irq_entry do_IRQ(struct pt_regs *regs)
{
if (handle_arch_irq)
handle_arch_irq(regs);
}

void __init init_IRQ(void)
{
irqchip_init();
Expand Down

0 comments on commit 24dc170

Please sign in to comment.