Skip to content
Commit a1b7b1a5 authored by Alexander Popov's avatar Alexander Popov Committed by Thomas Gleixner
Browse files

irqdomain: Fix irq_domain_alloc_irqs_recursive() error handling



If an irq_domain is auto-recursive and irq_domain_alloc_irqs_recursive()
for its parent has returned an error, then do return and avoid calling
irq_domain_free_irqs_recursive() uselessly, because:
- if domain->ops->alloc() had failed for an auto-recursive irq_domain,
   then irq_domain_free_irqs_recursive() had already been called;
- if domain->ops->alloc() had failed for a not auto-recursive irq_domain,
   then there is nothing to free at all.

Signed-off-by: default avatarAlexander Popov <alex.popov@linux.com>
Acked-by: default avatarMarc Zyngier <marc.zyngier@arm.com>
Link: http://lkml.kernel.org/r/1467505448-2850-1-git-send-email-alex.popov@linux.com


Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
parent 99e9d958
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment