Skip to content

Commit

Permalink
hw/intc: Add RISC-V AIA APLIC device emulation
Browse files Browse the repository at this point in the history
The RISC-V AIA (Advanced Interrupt Architecture) defines a new
interrupt controller for wired interrupts called APLIC (Advanced
Platform Level Interrupt Controller). The APLIC is capabable of
forwarding wired interupts to RISC-V HARTs directly or as MSIs
(Message Signaled Interupts).

This patch adds device emulation for RISC-V AIA APLIC.

Signed-off-by: Anup Patel <anup.patel@wdc.com>
Signed-off-by: Anup Patel <anup@brainfault.org>
Reviewed-by: Frank Chang <frank.chang@sifive.com>
Message-id: 20220204174700.534953-19-anup@brainfault.org
Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
  • Loading branch information
avpatel authored and alistair23 committed Feb 11, 2022
1 parent 76e8396 commit f1849f1
Show file tree
Hide file tree
Showing 4 changed files with 1,061 additions and 0 deletions.
3 changes: 3 additions & 0 deletions hw/intc/Kconfig
Expand Up @@ -70,6 +70,9 @@ config LOONGSON_LIOINTC
config RISCV_ACLINT
bool

config RISCV_APLIC
bool

config SIFIVE_PLIC
bool

Expand Down
1 change: 1 addition & 0 deletions hw/intc/meson.build
Expand Up @@ -50,6 +50,7 @@ specific_ss.add(when: 'CONFIG_S390_FLIC', if_true: files('s390_flic.c'))
specific_ss.add(when: 'CONFIG_S390_FLIC_KVM', if_true: files('s390_flic_kvm.c'))
specific_ss.add(when: 'CONFIG_SH_INTC', if_true: files('sh_intc.c'))
specific_ss.add(when: 'CONFIG_RISCV_ACLINT', if_true: files('riscv_aclint.c'))
specific_ss.add(when: 'CONFIG_RISCV_APLIC', if_true: files('riscv_aplic.c'))
specific_ss.add(when: 'CONFIG_SIFIVE_PLIC', if_true: files('sifive_plic.c'))
specific_ss.add(when: 'CONFIG_XICS', if_true: files('xics.c'))
specific_ss.add(when: ['CONFIG_KVM', 'CONFIG_XICS'],
Expand Down

0 comments on commit f1849f1

Please sign in to comment.