Skip to content

Commit 868772d

Browse files
Peter Ujfalusigregkh
authored andcommitted
ARM: OMAP2+: DMA: Add slave map entries for 24xx external request lines
The external request lines are used by tusb6010 on OMAP24xx platforms. Update the map so the driver can use dmaengine API to request the DMA channel. At the same time add temporary map containing only the external DMA request numbers for DT booted case on omap24xx since the tusb6010 stack is not yet supports DT boot. Signed-off-by: Peter Ujfalusi <[email protected]> Acked-by: Tony Lindgren <[email protected]> Signed-off-by: Bin Liu <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent 47699b0 commit 868772d

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

arch/arm/mach-omap2/dma.c

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -249,6 +249,24 @@ static const struct dma_slave_map omap24xx_sdma_map[] = {
249249
{ "omap_uart.2", "rx", SDMA_FILTER_PARAM(54) },
250250
{ "omap_hsmmc.0", "tx", SDMA_FILTER_PARAM(61) },
251251
{ "omap_hsmmc.0", "rx", SDMA_FILTER_PARAM(62) },
252+
253+
/* external DMA requests when tusb6010 is used */
254+
{ "musb-tusb", "dmareq0", SDMA_FILTER_PARAM(2) },
255+
{ "musb-tusb", "dmareq1", SDMA_FILTER_PARAM(3) },
256+
{ "musb-tusb", "dmareq2", SDMA_FILTER_PARAM(14) }, /* OMAP2420 only */
257+
{ "musb-tusb", "dmareq3", SDMA_FILTER_PARAM(15) }, /* OMAP2420 only */
258+
{ "musb-tusb", "dmareq4", SDMA_FILTER_PARAM(16) }, /* OMAP2420 only */
259+
{ "musb-tusb", "dmareq5", SDMA_FILTER_PARAM(64) }, /* OMAP2420 only */
260+
};
261+
262+
static const struct dma_slave_map omap24xx_sdma_dt_map[] = {
263+
/* external DMA requests when tusb6010 is used */
264+
{ "musb-hdrc.1.auto", "dmareq0", SDMA_FILTER_PARAM(2) },
265+
{ "musb-hdrc.1.auto", "dmareq1", SDMA_FILTER_PARAM(3) },
266+
{ "musb-hdrc.1.auto", "dmareq2", SDMA_FILTER_PARAM(14) }, /* OMAP2420 only */
267+
{ "musb-hdrc.1.auto", "dmareq3", SDMA_FILTER_PARAM(15) }, /* OMAP2420 only */
268+
{ "musb-hdrc.1.auto", "dmareq4", SDMA_FILTER_PARAM(16) }, /* OMAP2420 only */
269+
{ "musb-hdrc.1.auto", "dmareq5", SDMA_FILTER_PARAM(64) }, /* OMAP2420 only */
252270
};
253271

254272
static const struct dma_slave_map omap3xxx_sdma_map[] = {
@@ -346,6 +364,12 @@ static int __init omap2_system_dma_init_dev(struct omap_hwmod *oh, void *unused)
346364
__func__);
347365
return -ENODEV;
348366
}
367+
} else {
368+
if (soc_is_omap24xx()) {
369+
/* DMA slave map for drivers not yet converted to DT */
370+
p.slave_map = omap24xx_sdma_dt_map;
371+
p.slavecnt = ARRAY_SIZE(omap24xx_sdma_dt_map);
372+
}
349373
}
350374

351375
pdev = omap_device_build(name, 0, oh, &p, sizeof(p));

0 commit comments

Comments
 (0)