]> Pileus Git - ~andy/linux/blobdiff - sound/soc/soc-dmaengine-pcm.c
Merge branch 'for-3.7-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tj...
[~andy/linux] / sound / soc / soc-dmaengine-pcm.c
index 5df529eda251abdda685de949747050cc3e066a0..bbc125748a3843decc6ffd04d171fcf6f6b9fc5c 100644 (file)
@@ -140,14 +140,18 @@ static int dmaengine_pcm_prepare_and_submit(struct snd_pcm_substream *substream)
        struct dma_chan *chan = prtd->dma_chan;
        struct dma_async_tx_descriptor *desc;
        enum dma_transfer_direction direction;
+       unsigned long flags = DMA_CTRL_ACK;
 
        direction = snd_pcm_substream_to_dma_direction(substream);
 
+       if (!substream->runtime->no_period_wakeup)
+               flags |= DMA_PREP_INTERRUPT;
+
        prtd->pos = 0;
        desc = dmaengine_prep_dma_cyclic(chan,
                substream->runtime->dma_addr,
                snd_pcm_lib_buffer_bytes(substream),
-               snd_pcm_lib_period_bytes(substream), direction);
+               snd_pcm_lib_period_bytes(substream), direction, flags);
 
        if (!desc)
                return -ENOMEM;