[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [xen master] xen/arm: irq: add missing spin_unlock() in init_local_irq_data() error path
commit 4c3aa6e93d3fc760bdcb9cf268f506c06c0639b2 Author: Mykola Kvach <mykola_kvach@xxxxxxxx> AuthorDate: Mon Aug 11 11:45:20 2025 +0300 Commit: Julien Grall <jgrall@xxxxxxxxxx> CommitDate: Tue Aug 12 12:04:41 2025 +0100 xen/arm: irq: add missing spin_unlock() in init_local_irq_data() error path If init_one_irq_desc() fails, init_local_irq_data() returns without releasing local_irqs_type_lock, leading to a possible deadlock. Release the lock before returning to ensure proper cleanup. Fixes: 2bb32b809250 ("xen/irq: Propagate the error from init_one_desc_irq() in init_*_irq_data()") Signed-off-by: Mykola Kvach <mykola_kvach@xxxxxxxx> Reviewed-by: Denis Mukhin <dmukhin@xxxxxxxx> Acked-by: Julien Grall <jgrall@xxxxxxxxxx> --- xen/arch/arm/irq.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/xen/arch/arm/irq.c b/xen/arch/arm/irq.c index 4bbf0b0664..02ca82c089 100644 --- a/xen/arch/arm/irq.c +++ b/xen/arch/arm/irq.c @@ -94,7 +94,10 @@ static int init_local_irq_data(unsigned int cpu) int rc = init_one_irq_desc(desc); if ( rc ) + { + spin_unlock(&local_irqs_type_lock); return rc; + } desc->irq = irq; desc->action = NULL; -- generated by git-patchbot for /home/xen/git/xen.git#master
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |