aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/common
diff options
context:
space:
mode:
authorJoel Fernandes <joelf@ti.com>2013-08-29 19:05:42 -0400
committerVinod Koul <vinod.koul@intel.com>2013-09-04 09:08:46 -0400
commit96874b9a241c543e2f32d7bd7100af4416522cfb (patch)
tree7980dd7cbba2c8ce6fbe729bb4a6afedade3e97c /arch/arm/common
parent534070622d2c7fbc5cc929aa93541ccd0ae52ab1 (diff)
ARM: edma: Add function to manually trigger an EDMA channel
Manual trigger for events missed as a result of splitting a scatter gather list and DMA'ing it in batches. Add a helper function to trigger a channel incase any such events are missed. Signed-off-by: Joel Fernandes <joelf@ti.com> Acked-by: Sekhar Nori <nsekhar@ti.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Diffstat (limited to 'arch/arm/common')
-rw-r--r--arch/arm/common/edma.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/arch/arm/common/edma.c b/arch/arm/common/edma.c
index 39ad030ac0c7..117f955a2a06 100644
--- a/arch/arm/common/edma.c
+++ b/arch/arm/common/edma.c
@@ -1235,6 +1235,23 @@ void edma_resume(unsigned channel)
1235} 1235}
1236EXPORT_SYMBOL(edma_resume); 1236EXPORT_SYMBOL(edma_resume);
1237 1237
1238int edma_trigger_channel(unsigned channel)
1239{
1240 unsigned ctlr;
1241 unsigned int mask;
1242
1243 ctlr = EDMA_CTLR(channel);
1244 channel = EDMA_CHAN_SLOT(channel);
1245 mask = BIT(channel & 0x1f);
1246
1247 edma_shadow0_write_array(ctlr, SH_ESR, (channel >> 5), mask);
1248
1249 pr_debug("EDMA: ESR%d %08x\n", (channel >> 5),
1250 edma_shadow0_read_array(ctlr, SH_ESR, (channel >> 5)));
1251 return 0;
1252}
1253EXPORT_SYMBOL(edma_trigger_channel);
1254
1238/** 1255/**
1239 * edma_start - start dma on a channel 1256 * edma_start - start dma on a channel
1240 * @channel: channel being activated 1257 * @channel: channel being activated