dw-dma: fix element might be used uninitialized issue

The dma_sg_elem might be used uninitialized if the callback
function forget to do that.

Here adding initialization to fix that.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
This commit is contained in:
Keyon Jie 2017-11-10 15:33:24 +08:00 committed by Liam Girdwood
parent 9155f50c03
commit 69f3029c8a
1 changed files with 1 additions and 0 deletions

View File

@ -735,6 +735,7 @@ static void dw_dma_irq_handler(void *data)
if ((status_tfr & mask) &&
(p->chan[i].cb_type & DMA_IRQ_TYPE_LLIST)) {
next.src = next.dest = DMA_RELOAD_LLI;
next.size = DMA_RELOAD_LLI; /* will reload lli by default */
if (p->chan[i].cb)
p->chan[i].cb(p->chan[i].cb_data,