summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorAlexander Smirnov <asmirnov@ilbers.de>2017-08-24 17:02:59 +0300
committerVinod Koul <vinod.koul@intel.com>2017-08-28 22:02:05 +0530
commita2f6721b42bd503e2cced065f7dfbe8e79d59a09 (patch)
treeba38a87e6b0b3cd220c09ffcc4798f75061b26e7 /drivers
parentb753351ec8f4c6a25c6d9b5c4eccce62e448a571 (diff)
downloadlinux-a2f6721b42bd503e2cced065f7dfbe8e79d59a09.tar.gz
linux-a2f6721b42bd503e2cced065f7dfbe8e79d59a09.tar.bz2
linux-a2f6721b42bd503e2cced065f7dfbe8e79d59a09.zip
dmaengine: ti-dma-crossbar: Fix dra7 reserve function
DMA crossbar uses 'xbar->dma_inuse' variable to manage allocated routes. Each bit represents respective DMA channel. If the channel is free, bit is set to '0', if channel is allocated, bit should be set to '1'. In reserve function, the bits for requested DMA channels are cleared, so they are not really reserved, but freed and become ready for allocation. Signed-off-by: Alexander Smirnov <asmirnov@ilbers.de> Acked-by: Peter Ujfalusi <peter.ujfalusi@ti.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/dma/ti-dma-crossbar.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/dma/ti-dma-crossbar.c b/drivers/dma/ti-dma-crossbar.c
index 2403475a37cf..2f65a8fde21d 100644
--- a/drivers/dma/ti-dma-crossbar.c
+++ b/drivers/dma/ti-dma-crossbar.c
@@ -308,7 +308,7 @@ static const struct of_device_id ti_dra7_master_match[] = {
static inline void ti_dra7_xbar_reserve(int offset, int len, unsigned long *p)
{
for (; len > 0; len--)
- clear_bit(offset + (len - 1), p);
+ set_bit(offset + (len - 1), p);
}
static int ti_dra7_xbar_probe(struct platform_device *pdev)