Unverified Commit 9728fb3c authored by Clark Wang's avatar Clark Wang Committed by Mark Brown
Browse files

spi: lpspi: disable lpspi module irq in DMA mode



When all bits of IER are set to 0, we still can observe the lpspi irq events
when using DMA mode to transfer data.

So disable irq to avoid the too much irq events.

Signed-off-by: default avatarClark Wang <xiaoning.wang@nxp.com>
Link: https://lore.kernel.org/r/20230505063557.3962220-1-xiaoning.wang@nxp.com


Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent 6afe2ae8
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -910,9 +910,14 @@ static int fsl_lpspi_probe(struct platform_device *pdev)
	ret = fsl_lpspi_dma_init(&pdev->dev, fsl_lpspi, controller);
	if (ret == -EPROBE_DEFER)
		goto out_pm_get;

	if (ret < 0)
		dev_err(&pdev->dev, "dma setup error %d, use pio\n", ret);
	else
		/*
		 * disable LPSPI module IRQ when enable DMA mode successfully,
		 * to prevent the unexpected LPSPI module IRQ events.
		 */
		disable_irq(irq);

	ret = devm_spi_register_controller(&pdev->dev, controller);
	if (ret < 0) {