diff options
author | Takashi Iwai <tiwai@suse.de> | 2009-04-06 22:17:31 -0400 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2009-04-06 22:17:31 -0400 |
commit | e50a96e7c2aa523175b7b5642641327e2c587151 (patch) | |
tree | 244922976724696050db8c3705fd5f40a08bf714 /sound/soc | |
parent | 8c941de17679345a52fe53ac32d8aa53ebea369d (diff) | |
parent | 5c15a6869a75000fecea61e9985f4753311ec534 (diff) |
Merge branch 'topic/asoc' into for-linus
Diffstat (limited to 'sound/soc')
-rw-r--r-- | sound/soc/codecs/ak4535.c | 3 | ||||
-rw-r--r-- | sound/soc/fsl/fsl_dma.c | 12 |
2 files changed, 8 insertions, 7 deletions
diff --git a/sound/soc/codecs/ak4535.c b/sound/soc/codecs/ak4535.c index 1f63d387a2f4..dd3380202766 100644 --- a/sound/soc/codecs/ak4535.c +++ b/sound/soc/codecs/ak4535.c | |||
@@ -659,7 +659,8 @@ static int ak4535_remove(struct platform_device *pdev) | |||
659 | snd_soc_free_pcms(socdev); | 659 | snd_soc_free_pcms(socdev); |
660 | snd_soc_dapm_free(socdev); | 660 | snd_soc_dapm_free(socdev); |
661 | #if defined(CONFIG_I2C) || defined(CONFIG_I2C_MODULE) | 661 | #if defined(CONFIG_I2C) || defined(CONFIG_I2C_MODULE) |
662 | i2c_unregister_device(codec->control_data); | 662 | if (codec->control_data) |
663 | i2c_unregister_device(codec->control_data); | ||
663 | i2c_del_driver(&ak4535_i2c_driver); | 664 | i2c_del_driver(&ak4535_i2c_driver); |
664 | #endif | 665 | #endif |
665 | kfree(codec->private_data); | 666 | kfree(codec->private_data); |
diff --git a/sound/soc/fsl/fsl_dma.c b/sound/soc/fsl/fsl_dma.c index 2c4892c853cf..b1a3a278819f 100644 --- a/sound/soc/fsl/fsl_dma.c +++ b/sound/soc/fsl/fsl_dma.c | |||
@@ -300,7 +300,7 @@ static int fsl_dma_new(struct snd_card *card, struct snd_soc_dai *dai, | |||
300 | if (!card->dev->coherent_dma_mask) | 300 | if (!card->dev->coherent_dma_mask) |
301 | card->dev->coherent_dma_mask = fsl_dma_dmamask; | 301 | card->dev->coherent_dma_mask = fsl_dma_dmamask; |
302 | 302 | ||
303 | ret = snd_dma_alloc_pages(SNDRV_DMA_TYPE_DEV, pcm->dev, | 303 | ret = snd_dma_alloc_pages(SNDRV_DMA_TYPE_DEV, card->dev, |
304 | fsl_dma_hardware.buffer_bytes_max, | 304 | fsl_dma_hardware.buffer_bytes_max, |
305 | &pcm->streams[0].substream->dma_buffer); | 305 | &pcm->streams[0].substream->dma_buffer); |
306 | if (ret) { | 306 | if (ret) { |
@@ -310,7 +310,7 @@ static int fsl_dma_new(struct snd_card *card, struct snd_soc_dai *dai, | |||
310 | return -ENOMEM; | 310 | return -ENOMEM; |
311 | } | 311 | } |
312 | 312 | ||
313 | ret = snd_dma_alloc_pages(SNDRV_DMA_TYPE_DEV, pcm->dev, | 313 | ret = snd_dma_alloc_pages(SNDRV_DMA_TYPE_DEV, card->dev, |
314 | fsl_dma_hardware.buffer_bytes_max, | 314 | fsl_dma_hardware.buffer_bytes_max, |
315 | &pcm->streams[1].substream->dma_buffer); | 315 | &pcm->streams[1].substream->dma_buffer); |
316 | if (ret) { | 316 | if (ret) { |
@@ -418,7 +418,7 @@ static int fsl_dma_open(struct snd_pcm_substream *substream) | |||
418 | return -EBUSY; | 418 | return -EBUSY; |
419 | } | 419 | } |
420 | 420 | ||
421 | dma_private = dma_alloc_coherent(substream->pcm->dev, | 421 | dma_private = dma_alloc_coherent(substream->pcm->card->dev, |
422 | sizeof(struct fsl_dma_private), &ld_buf_phys, GFP_KERNEL); | 422 | sizeof(struct fsl_dma_private), &ld_buf_phys, GFP_KERNEL); |
423 | if (!dma_private) { | 423 | if (!dma_private) { |
424 | dev_err(substream->pcm->card->dev, | 424 | dev_err(substream->pcm->card->dev, |
@@ -445,7 +445,7 @@ static int fsl_dma_open(struct snd_pcm_substream *substream) | |||
445 | dev_err(substream->pcm->card->dev, | 445 | dev_err(substream->pcm->card->dev, |
446 | "can't register ISR for IRQ %u (ret=%i)\n", | 446 | "can't register ISR for IRQ %u (ret=%i)\n", |
447 | dma_private->irq, ret); | 447 | dma_private->irq, ret); |
448 | dma_free_coherent(substream->pcm->dev, | 448 | dma_free_coherent(substream->pcm->card->dev, |
449 | sizeof(struct fsl_dma_private), | 449 | sizeof(struct fsl_dma_private), |
450 | dma_private, dma_private->ld_buf_phys); | 450 | dma_private, dma_private->ld_buf_phys); |
451 | return ret; | 451 | return ret; |
@@ -778,13 +778,13 @@ static int fsl_dma_close(struct snd_pcm_substream *substream) | |||
778 | free_irq(dma_private->irq, dma_private); | 778 | free_irq(dma_private->irq, dma_private); |
779 | 779 | ||
780 | if (dma_private->ld_buf_phys) { | 780 | if (dma_private->ld_buf_phys) { |
781 | dma_unmap_single(substream->pcm->dev, | 781 | dma_unmap_single(substream->pcm->card->dev, |
782 | dma_private->ld_buf_phys, | 782 | dma_private->ld_buf_phys, |
783 | sizeof(dma_private->link), DMA_TO_DEVICE); | 783 | sizeof(dma_private->link), DMA_TO_DEVICE); |
784 | } | 784 | } |
785 | 785 | ||
786 | /* Deallocate the fsl_dma_private structure */ | 786 | /* Deallocate the fsl_dma_private structure */ |
787 | dma_free_coherent(substream->pcm->dev, | 787 | dma_free_coherent(substream->pcm->card->dev, |
788 | sizeof(struct fsl_dma_private), | 788 | sizeof(struct fsl_dma_private), |
789 | dma_private, dma_private->ld_buf_phys); | 789 | dma_private, dma_private->ld_buf_phys); |
790 | substream->runtime->private_data = NULL; | 790 | substream->runtime->private_data = NULL; |