]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
Merge remote-tracking branch 'asoc/topic/core' into asoc-next
authorMark Brown <broonie@linaro.org>
Wed, 15 Jan 2014 11:48:13 +0000 (11:48 +0000)
committerMark Brown <broonie@linaro.org>
Wed, 15 Jan 2014 11:48:13 +0000 (11:48 +0000)
1  2 
sound/soc/soc-core.c
sound/soc/soc-pcm.c

Simple merge
index 891b9a9bcbf885df92bad9007b3f23054ce68c18,d70eecd9e1683af1d9f69ebdb52a44efb9b1fe1b..e95ef95867230c408f433c15b34e75c599e8185e
@@@ -249,7 -324,11 +331,10 @@@ static int soc_pcm_open(struct snd_pcm_
                        &cpu_dai_drv->capture);
        }
  
+       if (soc_pcm_has_symmetry(substream))
+               runtime->hw.info |= SNDRV_PCM_INFO_JOINT_DUPLEX;
        ret = -EINVAL;
 -      snd_pcm_limit_hw_rates(runtime);
        if (!runtime->hw.rates) {
                printk(KERN_ERR "ASoC: %s <-> %s No matching rates\n",
                        codec_dai->name, cpu_dai->name);
@@@ -604,9 -689,21 +695,22 @@@ static int soc_pcm_hw_free(struct snd_p
  
        mutex_lock_nested(&rtd->pcm_mutex, rtd->pcm_subclass);
  
+       /* clear the corresponding DAIs parameters when going to be inactive */
+       if (cpu_dai->active == 1) {
+               cpu_dai->rate = 0;
+               cpu_dai->channels = 0;
+               cpu_dai->sample_bits = 0;
+       }
+       if (codec_dai->active == 1) {
+               codec_dai->rate = 0;
+               codec_dai->channels = 0;
+               codec_dai->sample_bits = 0;
+       }
        /* apply codec digital mute */
 -      if (!codec->active)
 +      if ((playback && codec_dai->playback_active == 1) ||
 +          (!playback && codec_dai->capture_active == 1))
                snd_soc_dai_digital_mute(codec_dai, 1, substream->stream);
  
        /* free any machine hw params */