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

Commit c12f9643 authored by Mark Brown's avatar Mark Brown
Browse files

spi/s3c64xx: Take runtime PM reference even if DMA is not supported



We always need the device to be runtime PM enabled to use it so just skip
the DMA initialisation not the entire prepare when polling.

Signed-off-by: default avatarMark Brown <broonie@linaro.org>
parent 3c729b43
Loading
Loading
Loading
Loading
+19 −20
Original line number Diff line number Diff line
@@ -429,9 +429,7 @@ static int s3c64xx_spi_prepare_transfer(struct spi_master *spi)
	dma_cap_mask_t mask;
	int ret;

	if (is_polling(sdd))
		return 0;

	if (!is_polling(sdd)) {
		dma_cap_zero(mask);
		dma_cap_set(DMA_SLAVE, mask);

@@ -451,6 +449,7 @@ static int s3c64xx_spi_prepare_transfer(struct spi_master *spi)
			ret = -EBUSY;
			goto out_rx;
		}
	}

	ret = pm_runtime_get_sync(&sdd->pdev->dev);
	if (ret < 0) {