This patch allows host to try to use DMA on tusb6010.
Please note that until tusb6010 DMA size limitations
are fixed, DMA happens with host side rarely.
Signed-off-by: Tony Lindgren <tony@atomide.com>
#define is_cppi_enabled() 0
#endif
+#ifdef CONFIG_USB_TUSB_OMAP_DMA
+#define tusb_dma_omap() 1
+#else
+#define tusb_dma_omap() 0
+#endif
/*
* DMA channel status ... updated by the dma controller driver whenever that
if (!pEnd->tx_channel)
musb_h_tx_start(pEnd);
- else if (is_cppi_enabled())
+ else if (is_cppi_enabled() || tusb_dma_omap())
cppi_host_txdma_start(pEnd);
}
}
#endif
/* candidate for DMA */
- if (is_cppi_enabled() && pDmaChannel) {
+ if ((is_cppi_enabled() || tusb_dma_omap()) && pDmaChannel) {
/* program endpoint CSRs first, then setup DMA.
* assume CPPI setup succeeds.
/* kick things off */
- if (is_cppi_enabled()) {
+ if ((is_cppi_enabled() || tusb_dma_omap()) && pDmaChannel) {
/* candidate for DMA */
if (pDmaChannel) {
pDmaChannel->dwActualLength = 0L;