diff options
author | Samuel Holland <samuel@sholland.org> | 2022-06-13 04:03:50 +0300 |
---|---|---|
committer | Anup Patel <anup@brainfault.org> | 2022-06-13 09:24:06 +0300 |
commit | 8c362e7d065eaf4d55da23a190a464ba870f89aa (patch) | |
tree | 0e329ebde4ba12c1119e7dfc299d63bcf33b0588 /COPYING.BSD | |
parent | 2ea7799d563ed9bbaf3b677728e928a6cd8f580c (diff) | |
download | opensbi-8c362e7d065eaf4d55da23a190a464ba870f89aa.tar.xz |
lib: irqchip/plic: Factor out a context init function
This simplifies both the callers and the callees by removing duplicated
code and consolidating the error handling. It also fixes two bugs in the
process:
1) ie_words was one too large when plic->num_src was a multiple of 32.
2) plic_set_ie takes a 32-bit mask, not a Boolean value, so the FPGA
platforms previously only enabled one out of every 32 interrupts.
Reviewed-by: Anup Patel <anup@brainfault.org>
Signed-off-by: Samuel Holland <samuel@sholland.org>
Diffstat (limited to 'COPYING.BSD')
0 files changed, 0 insertions, 0 deletions