Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

dmaengine: axi-dmac: Propagate errors from platform_get_irq()

Propagate errors returned by platform_get_irq() to the driver core. This
will enable proper probe deferring for the driver in case the IRQ provider
has not been registered yet.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>

authored by

Lars-Peter Clausen and committed by
Vinod Koul
50dc60a2 9bcfe38f

+3 -1
+3 -1
drivers/dma/dma-axi-dmac.c
··· 579 579 return -ENOMEM; 580 580 581 581 dmac->irq = platform_get_irq(pdev, 0); 582 - if (dmac->irq <= 0) 582 + if (dmac->irq < 0) 583 + return dmac->irq; 584 + if (dmac->irq == 0) 583 585 return -EINVAL; 584 586 585 587 res = platform_get_resource(pdev, IORESOURCE_MEM, 0);