aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/dma
diff options
context:
space:
mode:
authorKedareswara rao Appana <appana.durga.rao@xilinx.com>2016-06-24 01:21:26 -0400
committerVinod Koul <vinod.koul@intel.com>2016-07-08 01:21:49 -0400
commite131f1ba6f6f177a5b28610dff270d67eedcadbf (patch)
tree361eb9b230a5590f962ca0e4f5904e7ed6742721 /drivers/dma
parentfde57a7c4474b2d00b7b82b94aa2dd0160b1bbee (diff)
dmaengine: xilinx: Use different channel names for each dma
Current driver assumes that child node channel name is either "xlnx,axi-vdma-mm2s-channel" or "xlnx,axi-vdma-s2mm-channel" which is confusing the users of AXI DMA and CDMA. This patch fixes this issue by using different channel names for the AXI DMA and AXI CDMA child nodes. Signed-off-by: Kedareswara rao Appana <appanad@xilinx.com> Acked-by: Rob Herring <robh@kernel.org> Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Diffstat (limited to 'drivers/dma')
-rw-r--r--drivers/dma/xilinx/xilinx_dma.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/dma/xilinx/xilinx_dma.c b/drivers/dma/xilinx/xilinx_dma.c
index 0768d9f783c9..cf47347a1bc6 100644
--- a/drivers/dma/xilinx/xilinx_dma.c
+++ b/drivers/dma/xilinx/xilinx_dma.c
@@ -2353,7 +2353,9 @@ static int xilinx_dma_chan_probe(struct xilinx_dma_device *xdev,
2353 if (!has_dre) 2353 if (!has_dre)
2354 xdev->common.copy_align = fls(width - 1); 2354 xdev->common.copy_align = fls(width - 1);
2355 2355
2356 if (of_device_is_compatible(node, "xlnx,axi-vdma-mm2s-channel")) { 2356 if (of_device_is_compatible(node, "xlnx,axi-vdma-mm2s-channel") ||
2357 of_device_is_compatible(node, "xlnx,axi-dma-mm2s-channel") ||
2358 of_device_is_compatible(node, "xlnx,axi-cdma-channel")) {
2357 chan->direction = DMA_MEM_TO_DEV; 2359 chan->direction = DMA_MEM_TO_DEV;
2358 chan->id = chan_id; 2360 chan->id = chan_id;
2359 chan->tdest = chan_id; 2361 chan->tdest = chan_id;
@@ -2367,7 +2369,9 @@ static int xilinx_dma_chan_probe(struct xilinx_dma_device *xdev,
2367 chan->flush_on_fsync = true; 2369 chan->flush_on_fsync = true;
2368 } 2370 }
2369 } else if (of_device_is_compatible(node, 2371 } else if (of_device_is_compatible(node,
2370 "xlnx,axi-vdma-s2mm-channel")) { 2372 "xlnx,axi-vdma-s2mm-channel") ||
2373 of_device_is_compatible(node,
2374 "xlnx,axi-dma-s2mm-channel")) {
2371 chan->direction = DMA_DEV_TO_MEM; 2375 chan->direction = DMA_DEV_TO_MEM;
2372 chan->id = chan_id; 2376 chan->id = chan_id;
2373 chan->tdest = chan_id - xdev->nr_channels; 2377 chan->tdest = chan_id - xdev->nr_channels;