mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2025-01-17 02:36:21 +00:00
spi: mxs: Use dma_request_chan() instead dma_request_slave_channel()
dma_request_slave_channel() is a wrapper on top of dma_request_chan() eating up the error code. By using dma_request_chan() directly the driver can support deferred probing against DMA. Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Link: https://lore.kernel.org/r/20191212135550.4634-6-peter.ujfalusi@ti.com Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
6bfbf4d0aa
commit
7ccffd41b2
@ -590,10 +590,10 @@ static int mxs_spi_probe(struct platform_device *pdev)
|
|||||||
if (ret)
|
if (ret)
|
||||||
goto out_master_free;
|
goto out_master_free;
|
||||||
|
|
||||||
ssp->dmach = dma_request_slave_channel(&pdev->dev, "rx-tx");
|
ssp->dmach = dma_request_chan(&pdev->dev, "rx-tx");
|
||||||
if (!ssp->dmach) {
|
if (IS_ERR(ssp->dmach)) {
|
||||||
dev_err(ssp->dev, "Failed to request DMA\n");
|
dev_err(ssp->dev, "Failed to request DMA\n");
|
||||||
ret = -ENODEV;
|
ret = PTR_ERR(ssp->dmach);
|
||||||
goto out_master_free;
|
goto out_master_free;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user