can: at91_can: at91_open(): forward request_irq()'s return value in case or an error

If request_irq() fails, forward the return value.

Link: https://lore.kernel.org/all/20231005-at91_can-rx_offload-v2-15-9987d53600e0@pengutronix.de
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
This commit is contained in:
Marc Kleine-Budde
2023-05-01 18:14:41 +02:00
parent 8227088cb3
commit 99f4ff41bb

View File

@@ -1128,11 +1128,10 @@ static int at91_open(struct net_device *dev)
goto out;
/* register interrupt handler */
if (request_irq(dev->irq, at91_irq, IRQF_SHARED,
dev->name, dev)) {
err = -EAGAIN;
err = request_irq(dev->irq, at91_irq, IRQF_SHARED,
dev->name, dev);
if (err)
goto out_close;
}
/* start chip and queuing */
at91_chip_start(dev);