Skip to content

Commit 5b1f0e6

Browse files
lategoodbyedavem330
authored andcommitted
net: bcmgenet: Avoid touching non-existent interrupt
As platform_get_irq() now prints an error when the interrupt does not exist, we are getting a confusing error message in case the optional WOL IRQ is not defined: bcmgenet fd58000.ethernet: IRQ index 2 not found Fix this by using the platform_get_irq_optional(). Signed-off-by: Stefan Wahren <[email protected]> Acked-by: Florian Fainelli <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 2eea1fa commit 5b1f0e6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/net/ethernet/broadcom/genet/bcmgenet.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3459,7 +3459,7 @@ static int bcmgenet_probe(struct platform_device *pdev)
34593459
priv = netdev_priv(dev);
34603460
priv->irq0 = platform_get_irq(pdev, 0);
34613461
priv->irq1 = platform_get_irq(pdev, 1);
3462-
priv->wol_irq = platform_get_irq(pdev, 2);
3462+
priv->wol_irq = platform_get_irq_optional(pdev, 2);
34633463
if (!priv->irq0 || !priv->irq1) {
34643464
dev_err(&pdev->dev, "can't find IRQs\n");
34653465
err = -EINVAL;

0 commit comments

Comments
 (0)