[Sound-open-firmware] [PATCH] dma: dw: write back linked list descriptors

Liam Girdwood liam.r.girdwood at linux.intel.com
Sun Dec 10 21:48:11 CET 2017


The DMA linked list descriptors must be written back from cache so that
the DMA engine can read them.

Signed-off-by: Liam Girdwood <liam.r.girdwood at linux.intel.com>
---
 src/drivers/dw-dma.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/drivers/dw-dma.c b/src/drivers/dw-dma.c
index b288049..a28281a 100644
--- a/src/drivers/dw-dma.c
+++ b/src/drivers/dw-dma.c
@@ -611,6 +611,10 @@ static int dw_dma_set_config(struct dma *dma, int channel,
 #endif
 	}
 
+	/* write back descriptors so DMA engine can read them directly */
+	dcache_writeback_region(p->chan[channel].lli,
+			sizeof(struct dw_lli2) * p->chan[channel].desc_count);
+
 	p->chan[channel].status = COMP_STATE_PREPARE;
 out:
 	spin_unlock_irq(&dma->lock, flags);
-- 
2.14.1



More information about the Sound-open-firmware mailing list