target/riscv: Handle Smrnmi interrupt and exception
authorTommy Wu <tommy.wu@sifive.com>
Mon, 6 Jan 2025 05:43:33 +0000 (13:43 +0800)
committerAlistair Francis <alistair.francis@wdc.com>
Sat, 18 Jan 2025 23:44:34 +0000 (09:44 +1000)
commitc1149f69ab711bf6ccdc1da492f5be47f1ebf67e
treed0bad2eca9da78b465c022ae81ea797de09bde51
parent5db557f82bff480437275d4cc9e0b5463bc04484
target/riscv: Handle Smrnmi interrupt and exception

Because the RNMI interrupt trap handler address is implementation defined.
We add the 'rnmi-interrupt-vector' and 'rnmi-exception-vector' as the property
of the harts. It’s very easy for users to set the address based on their
expectation. This patch also adds the functionality to handle the RNMI signals.

Signed-off-by: Frank Chang <frank.chang@sifive.com>
Signed-off-by: Tommy Wu <tommy.wu@sifive.com>
Reviewed-by: Daniel Henrique Barboza <dbarboza@ventanamicro.com>
Reviewed-by: Alistair Francis <alistair.francis@wdc.com>
Message-ID: <20250106054336.1878291-4-frank.chang@sifive.com>
Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
hw/riscv/riscv_hart.c
include/hw/riscv/riscv_hart.h
target/riscv/cpu.c
target/riscv/cpu.h
target/riscv/cpu_bits.h
target/riscv/cpu_helper.c