Skip to content

Commit 028fd76

Browse files
cpackham-atlnzdavem330
authored andcommitted
Revert "net: mvmdio: avoid error message for optional IRQ"
This reverts commit e1f550d. platform_get_irq_optional() will still return -ENXIO when no interrupt is provided so the additional error handling caused the driver prone to fail when no interrupt was specified. Revert the change so we can apply the correct minimal fix. Signed-off-by: Chris Packham <[email protected]> Reviewed-by: Andrew Lunn <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 32ca98f commit 028fd76

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

drivers/net/ethernet/marvell/mvmdio.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -347,7 +347,7 @@ static int orion_mdio_probe(struct platform_device *pdev)
347347
}
348348

349349

350-
dev->err_interrupt = platform_get_irq_optional(pdev, 0);
350+
dev->err_interrupt = platform_get_irq(pdev, 0);
351351
if (dev->err_interrupt > 0 &&
352352
resource_size(r) < MVMDIO_ERR_INT_MASK + 4) {
353353
dev_err(&pdev->dev,
@@ -364,8 +364,8 @@ static int orion_mdio_probe(struct platform_device *pdev)
364364
writel(MVMDIO_ERR_INT_SMI_DONE,
365365
dev->regs + MVMDIO_ERR_INT_MASK);
366366

367-
} else if (dev->err_interrupt < 0) {
368-
ret = dev->err_interrupt;
367+
} else if (dev->err_interrupt == -EPROBE_DEFER) {
368+
ret = -EPROBE_DEFER;
369369
goto out_mdio;
370370
}
371371

0 commit comments

Comments
 (0)