Commit 738987a1 authored by Peter Ujfalusi's avatar Peter Ujfalusi Committed by Ulf Hansson

mmc: bcm2835: 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: default avatarPeter Ujfalusi <peter.ujfalusi@ti.com>
Reviewed-by: default avatarNicolas Saenz Julienne <nsaenzjulienne@suse.de>
Link: https://lore.kernel.org/r/20191217122254.7103-1-peter.ujfalusi@ti.comSigned-off-by: default avatarUlf Hansson <ulf.hansson@linaro.org>
parent e6d82a7b
......@@ -1393,7 +1393,17 @@ static int bcm2835_probe(struct platform_device *pdev)
host->dma_chan = NULL;
host->dma_desc = NULL;
host->dma_chan_rxtx = dma_request_slave_channel(dev, "rx-tx");
host->dma_chan_rxtx = dma_request_chan(dev, "rx-tx");
if (IS_ERR(host->dma_chan_rxtx)) {
ret = PTR_ERR(host->dma_chan_rxtx);
host->dma_chan_rxtx = NULL;
if (ret == -EPROBE_DEFER)
goto err;
/* Ignore errors to fall back to PIO mode */
}
clk = devm_clk_get(dev, NULL);
if (IS_ERR(clk)) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment