RE: [PATCH] ASoC: SAMSUNG: Add SND_SOC_DAIFMT_CONT option for snd_soc_set_fmt()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, Aug 26, 2012 at 05:45:54PM +0900, Mark Brown wrote:
> On Sun, Aug 26, 2012 at 05:45:54PM +0900,  ڻ    wrote:
> > SND_SOC_DAIFMT_CONT option is now needed because of below commit:
> >
> > ASoC: Allow DAI formats to be specified in the dai_link
> 
> Clearly it's not a direct consequence of this commit, that just introduces a new optional facility
> which...
OK, I'll change it.
> 
> >  	/* Set the cpu DAI configuration */
> >  	ret = snd_soc_dai_set_fmt(cpu_dai, SND_SOC_DAIFMT_DSP_B
> > +				| SND_SOC_DAIFMT_CONT
> >  				| SND_SOC_DAIFMT_IB_NF
> >  				| SND_SOC_DAIFMT_CBS_CFS);
> 
> ...isn't being used by the driver.
> 
> Looking at the above it looks like the PCM driver is doing something very odd - _CONT doesn't make
> a whole lot of sense on the slave side, it's related to the clock generation so should have no
> effect at all on the slave side.  The driver code looks reasonably sensible though.
You mean cpu side is slave? 
And I think that pcm driver can be changed to solve this issue.
> 
> What specifically is going wrong here?
SND_SOC_DAIFMT_CONT is used sound/soc/Samsung/pcm.c (s3c_pcm_set_fmt()) like below.

switch (fmt & SND_SOC_DAIFMT_CLOCK_MASK) {
        case SND_SOC_DAIFMT_CONT:
                pcm->idleclk = 1;
                break;
        case SND_SOC_DAIFMT_GATED:
                pcm->idleclk = 0;
                break;
        default:
                dev_err(pcm->dev, "Invalid Clock gating request!\n");
                ret = -EINVAL;
                goto exit;
        }

If fmt argument has no SND_SOC_DAIFMT_ option, s3c_pcm_set_fmt() return -EINVAL.

> 
> _______________________________________________
> linux-arm-kernel mailing list
> linux-arm-kernel@xxxxxxxxxxxxxxxxxxx
> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

--
To unsubscribe from this list: send the line "unsubscribe linux-samsung-soc" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux SoC Development]     [Linux Rockchip Development]     [Linux USB Development]     [Video for Linux]     [Linux Audio Users]     [Linux SCSI]     [Yosemite News]

  Powered by Linux