Patchwork [2/2] ASoC: OMAP: reconfigure DMA to resume audio

login
register
mail settings
Submitter Jane Wang
Date Nov. 13, 2009, 6:02 p.m.
Message ID <1258135323-20523-1-git-send-email-jwang@ti.com>
Download mbox | patch
Permalink /patch/59897/
State Changes Requested, archived
Delegated to: Tony Lindgren
Headers show

Comments

Patch

diff --git a/sound/soc/omap/omap-pcm.c b/sound/soc/omap/omap-pcm.c
index 6a829ee..5e04390 100644
--- a/sound/soc/omap/omap-pcm.c
+++ b/sound/soc/omap/omap-pcm.c
@@ -215,8 +215,13 @@  static int omap_pcm_trigger(struct snd_pcm_substream *substream, int cmd)
 
 	spin_lock_irqsave(&prtd->lock, flags);
 	switch (cmd) {
-	case SNDRV_PCM_TRIGGER_START:
 	case SNDRV_PCM_TRIGGER_RESUME:
+		/* Reconfigure DMA transfer parameters
+		 * in order to come back from OFF mode
+		 */
+		omap_pcm_prepare(substream);
+		/* fall through */
+	case SNDRV_PCM_TRIGGER_START:
 	case SNDRV_PCM_TRIGGER_PAUSE_RELEASE:
 		prtd->period_index = 0;
 		/* Configure McBSP internal buffer usage */