aboutsummaryrefslogtreecommitdiffstats
path: root/sound
diff options
context:
space:
mode:
authorMark Brown <broonie@opensource.wolfsonmicro.com>2011-06-09 07:02:26 -0400
committerMark Brown <broonie@opensource.wolfsonmicro.com>2011-06-09 07:02:26 -0400
commitbf564ea99797f6e66796d0d0a24a8fe872d5f26e (patch)
treeeb39d79c3ab5d59817b7d886c584b91c1651b480 /sound
parent147dfe90f7302f2472d83c25b983420a727aec5a (diff)
parent0cd114fff9ace7014c0d3ef8ab385fc5d3cf2d2f (diff)
Merge branch 'for-3.0' into for-3.1
Diffstat (limited to 'sound')
-rw-r--r--sound/soc/codecs/wm8804.c9
-rw-r--r--sound/soc/fsl/fsl_dma.c9
2 files changed, 12 insertions, 6 deletions
diff --git a/sound/soc/codecs/wm8804.c b/sound/soc/codecs/wm8804.c
index 6785688f8806..9a5e67c5a6bd 100644
--- a/sound/soc/codecs/wm8804.c
+++ b/sound/soc/codecs/wm8804.c
@@ -680,20 +680,25 @@ static struct snd_soc_dai_ops wm8804_dai_ops = {
680#define WM8804_FORMATS (SNDRV_PCM_FMTBIT_S16_LE | SNDRV_PCM_FMTBIT_S20_3LE | \ 680#define WM8804_FORMATS (SNDRV_PCM_FMTBIT_S16_LE | SNDRV_PCM_FMTBIT_S20_3LE | \
681 SNDRV_PCM_FMTBIT_S24_LE) 681 SNDRV_PCM_FMTBIT_S24_LE)
682 682
683#define WM8804_RATES (SNDRV_PCM_RATE_32000 | SNDRV_PCM_RATE_44100 | \
684 SNDRV_PCM_RATE_48000 | SNDRV_PCM_RATE_64000 | \
685 SNDRV_PCM_RATE_88200 | SNDRV_PCM_RATE_96000 | \
686 SNDRV_PCM_RATE_176400 | SNDRV_PCM_RATE_192000)
687
683static struct snd_soc_dai_driver wm8804_dai = { 688static struct snd_soc_dai_driver wm8804_dai = {
684 .name = "wm8804-spdif", 689 .name = "wm8804-spdif",
685 .playback = { 690 .playback = {
686 .stream_name = "Playback", 691 .stream_name = "Playback",
687 .channels_min = 2, 692 .channels_min = 2,
688 .channels_max = 2, 693 .channels_max = 2,
689 .rates = SNDRV_PCM_RATE_8000_192000, 694 .rates = WM8804_RATES,
690 .formats = WM8804_FORMATS, 695 .formats = WM8804_FORMATS,
691 }, 696 },
692 .capture = { 697 .capture = {
693 .stream_name = "Capture", 698 .stream_name = "Capture",
694 .channels_min = 2, 699 .channels_min = 2,
695 .channels_max = 2, 700 .channels_max = 2,
696 .rates = SNDRV_PCM_RATE_8000_192000, 701 .rates = WM8804_RATES,
697 .formats = WM8804_FORMATS, 702 .formats = WM8804_FORMATS,
698 }, 703 },
699 .ops = &wm8804_dai_ops, 704 .ops = &wm8804_dai_ops,
diff --git a/sound/soc/fsl/fsl_dma.c b/sound/soc/fsl/fsl_dma.c
index 3872598d04aa..732208c8c0b4 100644
--- a/sound/soc/fsl/fsl_dma.c
+++ b/sound/soc/fsl/fsl_dma.c
@@ -312,7 +312,7 @@ static int fsl_dma_new(struct snd_soc_pcm_runtime *rtd)
312 * should allocate a DMA buffer only for the streams that are valid. 312 * should allocate a DMA buffer only for the streams that are valid.
313 */ 313 */
314 314
315 if (dai->driver->playback.channels_min) { 315 if (pcm->streams[0].substream) {
316 ret = snd_dma_alloc_pages(SNDRV_DMA_TYPE_DEV, card->dev, 316 ret = snd_dma_alloc_pages(SNDRV_DMA_TYPE_DEV, card->dev,
317 fsl_dma_hardware.buffer_bytes_max, 317 fsl_dma_hardware.buffer_bytes_max,
318 &pcm->streams[0].substream->dma_buffer); 318 &pcm->streams[0].substream->dma_buffer);
@@ -322,13 +322,13 @@ static int fsl_dma_new(struct snd_soc_pcm_runtime *rtd)
322 } 322 }
323 } 323 }
324 324
325 if (dai->driver->capture.channels_min) { 325 if (pcm->streams[1].substream) {
326 ret = snd_dma_alloc_pages(SNDRV_DMA_TYPE_DEV, card->dev, 326 ret = snd_dma_alloc_pages(SNDRV_DMA_TYPE_DEV, card->dev,
327 fsl_dma_hardware.buffer_bytes_max, 327 fsl_dma_hardware.buffer_bytes_max,
328 &pcm->streams[1].substream->dma_buffer); 328 &pcm->streams[1].substream->dma_buffer);
329 if (ret) { 329 if (ret) {
330 snd_dma_free_pages(&pcm->streams[0].substream->dma_buffer);
331 dev_err(card->dev, "can't alloc capture dma buffer\n"); 330 dev_err(card->dev, "can't alloc capture dma buffer\n");
331 snd_dma_free_pages(&pcm->streams[0].substream->dma_buffer);
332 return ret; 332 return ret;
333 } 333 }
334 } 334 }
@@ -451,7 +451,8 @@ static int fsl_dma_open(struct snd_pcm_substream *substream)
451 dma_private->ld_buf_phys = ld_buf_phys; 451 dma_private->ld_buf_phys = ld_buf_phys;
452 dma_private->dma_buf_phys = substream->dma_buffer.addr; 452 dma_private->dma_buf_phys = substream->dma_buffer.addr;
453 453
454 ret = request_irq(dma_private->irq, fsl_dma_isr, 0, "DMA", dma_private); 454 ret = request_irq(dma_private->irq, fsl_dma_isr, 0, "fsldma-audio",
455 dma_private);
455 if (ret) { 456 if (ret) {
456 dev_err(dev, "can't register ISR for IRQ %u (ret=%i)\n", 457 dev_err(dev, "can't register ISR for IRQ %u (ret=%i)\n",
457 dma_private->irq, ret); 458 dma_private->irq, ret);