aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/dma/omap-dma.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2014-04-10 11:55:08 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2014-04-10 11:55:08 -0400
commit6c61403a446b5ee54c21cecabdc821acf06f96bf (patch)
tree26423d750d6e0d793ac1751b92025250461e9a4e /drivers/dma/omap-dma.c
parentedf2377c4776ce20ae990f27f0248e88a37e25c4 (diff)
parent8673bcef8c1b07b83e9ee02d5e7f4b66507b03cd (diff)
Merge branch 'for-linus' of git://git.infradead.org/users/vkoul/slave-dma
Pull slave-dmaengine updates from Vinod Koul: - New driver for Qcom bam dma - New driver for RCAR peri-peri - New driver for FSL eDMA - Various odd fixes and updates thru the subsystem * 'for-linus' of git://git.infradead.org/users/vkoul/slave-dma: (29 commits) dmaengine: add Qualcomm BAM dma driver shdma: add R-Car Audio DMAC peri peri driver dmaengine: sirf: enable generic dt binding for dma channels dma: omap-dma: Implement device_slave_caps callback dmaengine: qcom_bam_dma: Add device tree binding dma: dw: Add suspend and resume handling for PCI mode DW_DMAC. dma: dw: allocate memory in two stages in probe Add new line to test result strings produced in verbose mode dmaengine: pch_dma: use tasklet_kill in teardown dmaengine: at_hdmac: use tasklet_kill in teardown dma: cppi41: start tear down only if channel is busy usb: musb: musb_cppi41: Dont reprogram DMA if tear down is initiated dmaengine: s3c24xx-dma: make phy->irq signed for error handling dma: imx-dma: Add missing module owner field dma: imx-dma: Replace printk with dev_* dma: fsl-edma: fix static checker warning of NULL dereference dma: Remove comment about embedding dma_slave_config into custom structs dma: mmp_tdma: move to generic device tree binding dma: mmp_pdma: add IRQF_SHARED when request irq dma: edma: Fix memory leak in edma_prep_dma_cyclic() ...
Diffstat (limited to 'drivers/dma/omap-dma.c')
-rw-r--r--drivers/dma/omap-dma.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/drivers/dma/omap-dma.c b/drivers/dma/omap-dma.c
index 64ceca2920b8..b19f04f4390b 100644
--- a/drivers/dma/omap-dma.c
+++ b/drivers/dma/omap-dma.c
@@ -1088,6 +1088,23 @@ static void omap_dma_free(struct omap_dmadev *od)
1088 } 1088 }
1089} 1089}
1090 1090
1091#define OMAP_DMA_BUSWIDTHS (BIT(DMA_SLAVE_BUSWIDTH_1_BYTE) | \
1092 BIT(DMA_SLAVE_BUSWIDTH_2_BYTES) | \
1093 BIT(DMA_SLAVE_BUSWIDTH_4_BYTES))
1094
1095static int omap_dma_device_slave_caps(struct dma_chan *dchan,
1096 struct dma_slave_caps *caps)
1097{
1098 caps->src_addr_widths = OMAP_DMA_BUSWIDTHS;
1099 caps->dstn_addr_widths = OMAP_DMA_BUSWIDTHS;
1100 caps->directions = BIT(DMA_DEV_TO_MEM) | BIT(DMA_MEM_TO_DEV);
1101 caps->cmd_pause = true;
1102 caps->cmd_terminate = true;
1103 caps->residue_granularity = DMA_RESIDUE_GRANULARITY_BURST;
1104
1105 return 0;
1106}
1107
1091static int omap_dma_probe(struct platform_device *pdev) 1108static int omap_dma_probe(struct platform_device *pdev)
1092{ 1109{
1093 struct omap_dmadev *od; 1110 struct omap_dmadev *od;
@@ -1118,6 +1135,7 @@ static int omap_dma_probe(struct platform_device *pdev)
1118 od->ddev.device_prep_slave_sg = omap_dma_prep_slave_sg; 1135 od->ddev.device_prep_slave_sg = omap_dma_prep_slave_sg;
1119 od->ddev.device_prep_dma_cyclic = omap_dma_prep_dma_cyclic; 1136 od->ddev.device_prep_dma_cyclic = omap_dma_prep_dma_cyclic;
1120 od->ddev.device_control = omap_dma_control; 1137 od->ddev.device_control = omap_dma_control;
1138 od->ddev.device_slave_caps = omap_dma_device_slave_caps;
1121 od->ddev.dev = &pdev->dev; 1139 od->ddev.dev = &pdev->dev;
1122 INIT_LIST_HEAD(&od->ddev.channels); 1140 INIT_LIST_HEAD(&od->ddev.channels);
1123 INIT_LIST_HEAD(&od->pending); 1141 INIT_LIST_HEAD(&od->pending);