* [PATCH v1] spi: dw: Replace dma_request_slave_channel() with dma_request_chan()
@ 2020-08-28 13:58 Andy Shevchenko
2020-08-28 14:20 ` Andy Shevchenko
0 siblings, 1 reply; 2+ messages in thread
From: Andy Shevchenko @ 2020-08-28 13:58 UTC (permalink / raw)
To: Mark Brown, linux-spi; +Cc: Andy Shevchenko
Drivers should use dma_request_chan() instead of dma_request_slave_channel().
dma_request_slave_channel() is a simple wrapper for dma_request_chan() eating
up the error code for channel request failure and makes deferred probing
impossible.
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
drivers/spi/spi-dw-dma.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/spi/spi-dw-dma.c b/drivers/spi/spi-dw-dma.c
index bb390ff67d1d..afc2f11a3473 100644
--- a/drivers/spi/spi-dw-dma.c
+++ b/drivers/spi/spi-dw-dma.c
@@ -107,11 +107,11 @@ static int dw_spi_dma_init_mfld(struct device *dev, struct dw_spi *dws)
static int dw_spi_dma_init_generic(struct device *dev, struct dw_spi *dws)
{
- dws->rxchan = dma_request_slave_channel(dev, "rx");
+ dws->rxchan = dma_request_chan(dev, "rx");
if (!dws->rxchan)
return -ENODEV;
- dws->txchan = dma_request_slave_channel(dev, "tx");
+ dws->txchan = dma_request_chan(dev, "tx");
if (!dws->txchan) {
dma_release_channel(dws->rxchan);
dws->rxchan = NULL;
--
2.28.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH v1] spi: dw: Replace dma_request_slave_channel() with dma_request_chan()
2020-08-28 13:58 [PATCH v1] spi: dw: Replace dma_request_slave_channel() with dma_request_chan() Andy Shevchenko
@ 2020-08-28 14:20 ` Andy Shevchenko
0 siblings, 0 replies; 2+ messages in thread
From: Andy Shevchenko @ 2020-08-28 14:20 UTC (permalink / raw)
To: Mark Brown, linux-spi
On Fri, Aug 28, 2020 at 04:58:18PM +0300, Andy Shevchenko wrote:
> Drivers should use dma_request_chan() instead of dma_request_slave_channel().
>
> dma_request_slave_channel() is a simple wrapper for dma_request_chan() eating
> up the error code for channel request failure and makes deferred probing
> impossible.
It's not fully correct change.
--
With Best Regards,
Andy Shevchenko
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-08-28 14:20 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-28 13:58 [PATCH v1] spi: dw: Replace dma_request_slave_channel() with dma_request_chan() Andy Shevchenko
2020-08-28 14:20 ` Andy Shevchenko
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).