diff options
author | Heikki Krogerus <heikki.krogerus@linux.intel.com> | 2013-04-10 09:58:26 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-04-11 16:19:26 -0400 |
commit | e4fb3b88ebf21e6127ed0e91336752352ba0931e (patch) | |
tree | dea1621d148121e5e8110efbbf53b4ecf5c4325f /drivers/tty | |
parent | 75df022b5f8982a375adb04e9e4c0a34a9689ed9 (diff) |
serial: 8250_dma: Use dmaengine helpers to get the slave channels
The helper functions in dmaengine API allow the drivers to
request slave channels without the filter parameters. They
will attempt to extract the needed DMA client information
from DT or ACPI, but if such information is not available
the filter parameters can still be used.
Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty')
-rw-r--r-- | drivers/tty/serial/8250/8250_dma.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/tty/serial/8250/8250_dma.c b/drivers/tty/serial/8250/8250_dma.c index 66430614510a..fdb6139e8c17 100644 --- a/drivers/tty/serial/8250/8250_dma.c +++ b/drivers/tty/serial/8250/8250_dma.c | |||
@@ -156,14 +156,18 @@ int serial8250_request_dma(struct uart_8250_port *p) | |||
156 | dma_cap_set(DMA_SLAVE, mask); | 156 | dma_cap_set(DMA_SLAVE, mask); |
157 | 157 | ||
158 | /* Get a channel for RX */ | 158 | /* Get a channel for RX */ |
159 | dma->rxchan = dma_request_channel(mask, dma->fn, dma->rx_param); | 159 | dma->rxchan = dma_request_slave_channel_compat(mask, |
160 | dma->fn, dma->rx_param, | ||
161 | p->port.dev, "rx"); | ||
160 | if (!dma->rxchan) | 162 | if (!dma->rxchan) |
161 | return -ENODEV; | 163 | return -ENODEV; |
162 | 164 | ||
163 | dmaengine_slave_config(dma->rxchan, &dma->rxconf); | 165 | dmaengine_slave_config(dma->rxchan, &dma->rxconf); |
164 | 166 | ||
165 | /* Get a channel for TX */ | 167 | /* Get a channel for TX */ |
166 | dma->txchan = dma_request_channel(mask, dma->fn, dma->tx_param); | 168 | dma->txchan = dma_request_slave_channel_compat(mask, |
169 | dma->fn, dma->tx_param, | ||
170 | p->port.dev, "tx"); | ||
167 | if (!dma->txchan) { | 171 | if (!dma->txchan) { |
168 | dma_release_channel(dma->rxchan); | 172 | dma_release_channel(dma->rxchan); |
169 | return -ENODEV; | 173 | return -ENODEV; |