Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 19626946 authored by Alexander Aring's avatar Alexander Aring Committed by David S. Miller
Browse files

at86rf230: reset irq line before irq request



This patch resets the irq line before we are requesting the irq. This
avoids pending interrupts before requesting.

Signed-off-by: default avatarAlexander Aring <alex.aring@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent ee69559b
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -1172,13 +1172,13 @@ static int at86rf230_probe(struct spi_device *spi)
	if (rc)
		goto err_hw_init;

	rc = devm_request_irq(&spi->dev, spi->irq, irq_handler, IRQF_SHARED,
			      dev_name(&spi->dev), lp);
	/* Read irq status register to reset irq line */
	rc = at86rf230_read_subreg(lp, RG_IRQ_STATUS, 0xff, 0, &status);
	if (rc)
		goto err_hw_init;

	/* Read irq status register to reset irq line */
	rc = at86rf230_read_subreg(lp, RG_IRQ_STATUS, 0xff, 0, &status);
	rc = devm_request_irq(&spi->dev, spi->irq, irq_handler, IRQF_SHARED,
			      dev_name(&spi->dev), lp);
	if (rc)
		goto err_hw_init;