From: Roel Kluin <roel.kluin@xxxxxxxxx> platform_get_irq() can return -ENXIO, but since 'irq' is an unsigned int, it does not show when the IRQ resource wasn't found. Signed-off-by: Roel Kluin <roel.kluin@xxxxxxxxx> Cc: Jeff Garzik <jeff@xxxxxxxxxx> Cc: Alan Cox <alan@xxxxxxxxxxxxxxxxxxx> Acked-by: Phil Sutter <n0-1@xxxxxxxxxxx> Cc: Florian Fainelli <florian@xxxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- drivers/ata/pata_rb532_cf.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff -puN drivers/ata/pata_rb532_cf.c~pata-rb532-cf-platform_get_irq-failure-ignored drivers/ata/pata_rb532_cf.c --- a/drivers/ata/pata_rb532_cf.c~pata-rb532-cf-platform_get_irq-failure-ignored +++ a/drivers/ata/pata_rb532_cf.c @@ -117,11 +117,12 @@ static __devinit int rb532_pata_driver_p return -EINVAL; } - irq = platform_get_irq(pdev, 0); - if (irq <= 0) { + ret = platform_get_irq(pdev, 0); + if (ret <= 0) { dev_err(&pdev->dev, "no IRQ resource found\n"); return -ENOENT; } + irq = ret; gpio = irq_to_gpio(irq); if (gpio < 0) { _ -- To unsubscribe from this list: send the line "unsubscribe linux-ide" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html