diff options
Diffstat (limited to 'sound/soc/at91/at91-pcm.c')
-rw-r--r-- | sound/soc/at91/at91-pcm.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/sound/soc/at91/at91-pcm.c b/sound/soc/at91/at91-pcm.c index fd9d7327b239..e88b12e7cc40 100644 --- a/sound/soc/at91/at91-pcm.c +++ b/sound/soc/at91/at91-pcm.c | |||
@@ -125,7 +125,7 @@ static int at91_pcm_hw_params(struct snd_pcm_substream *substream, | |||
125 | snd_pcm_set_runtime_buffer(substream, &substream->dma_buffer); | 125 | snd_pcm_set_runtime_buffer(substream, &substream->dma_buffer); |
126 | runtime->dma_bytes = params_buffer_bytes(params); | 126 | runtime->dma_bytes = params_buffer_bytes(params); |
127 | 127 | ||
128 | prtd->params = rtd->cpu_dai->dma_data; | 128 | prtd->params = rtd->dai->cpu_dai->dma_data; |
129 | prtd->params->dma_intr_handler = at91_pcm_dma_irq; | 129 | prtd->params->dma_intr_handler = at91_pcm_dma_irq; |
130 | 130 | ||
131 | prtd->dma_buffer = runtime->dma_addr; | 131 | prtd->dma_buffer = runtime->dma_addr; |
@@ -363,6 +363,7 @@ static void at91_pcm_free_dma_buffers(struct snd_pcm *pcm) | |||
363 | } | 363 | } |
364 | } | 364 | } |
365 | 365 | ||
366 | #ifdef CONFIG_PM | ||
366 | static int at91_pcm_suspend(struct platform_device *pdev, | 367 | static int at91_pcm_suspend(struct platform_device *pdev, |
367 | struct snd_soc_cpu_dai *dai) | 368 | struct snd_soc_cpu_dai *dai) |
368 | { | 369 | { |
@@ -410,6 +411,10 @@ static int at91_pcm_resume(struct platform_device *pdev, | |||
410 | at91_ssc_write(params->ssc_base + AT91_PDC_PTCR, params->mask->pdc_enable); | 411 | at91_ssc_write(params->ssc_base + AT91_PDC_PTCR, params->mask->pdc_enable); |
411 | return 0; | 412 | return 0; |
412 | } | 413 | } |
414 | #else | ||
415 | #define at91_pcm_suspend NULL | ||
416 | #define at91_pcm_resume NULL | ||
417 | #endif | ||
413 | 418 | ||
414 | struct snd_soc_platform at91_soc_platform = { | 419 | struct snd_soc_platform at91_soc_platform = { |
415 | .name = "at91-audio", | 420 | .name = "at91-audio", |