Skip to content

Commit 14473a1

Browse files
nick650823KAGA-KOKO
authored andcommitted
irqchip/riscv-intc: Add missing free() callback in riscv_intc_domain_ops
The irq_domain_free_irqs() helper requires that the irq_domain_ops->free callback is implemented. Otherwise, the kernel reports the warning message "NULL pointer, cannot free irq" when irq_dispose_mapping() is invoked to release the per-HART local interrupts. Set irq_domain_ops->free to irq_domain_free_irqs_top() to cure that. Fixes: 832f15f ("RISC-V: Treat IPIs as normal Linux IRQs") Signed-off-by: Nick Hu <nick.hu@sifive.com> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Link: https://patch.msgid.link/20251114-rv-intc-fix-v1-1-a3edd1c1a868@sifive.com
1 parent e9a6fb0 commit 14473a1

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

drivers/irqchip/irq-riscv-intc.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,8 @@ static int riscv_intc_domain_alloc(struct irq_domain *domain,
166166
static const struct irq_domain_ops riscv_intc_domain_ops = {
167167
.map = riscv_intc_domain_map,
168168
.xlate = irq_domain_xlate_onecell,
169-
.alloc = riscv_intc_domain_alloc
169+
.alloc = riscv_intc_domain_alloc,
170+
.free = irq_domain_free_irqs_top,
170171
};
171172

172173
static struct fwnode_handle *riscv_intc_hwnode(void)

0 commit comments

Comments
 (0)