lib: utils/irqchip: plic: Fix the off-by-one error in priority save/restore helpers
authorBin Meng <bmeng@tinylab.org>
Sun, 11 Dec 2022 06:54:20 +0000 (14:54 +0800)
committerAnup Patel <anup@brainfault.org>
Sat, 17 Dec 2022 03:12:21 +0000 (08:42 +0530)
commit34da6638ad7b3d8c1834dffe5cd2629aa748efaf
tree71cc898afbcf1b7f40532fb6524effffd9232bb9
parent7a3354ac1591201c1f2380b79c9c3c75075d312c
lib: utils/irqchip: plic: Fix the off-by-one error in priority save/restore helpers

Interrupt source 0 is reserved. Hence the irq should start from 1.

Fixes: 2b79b694a805 ("lib: irqchip/plic: Add priority save/restore helpers")
Signed-off-by: Bin Meng <bmeng@tinylab.org>
Reviewed-by: Anup Patel <anup@brainfault.org>
lib/utils/irqchip/plic.c