[alsa-devel] [PATCH] [v2] ASoC: support all possible sample rates in the WM8776 driver

Lars-Peter Clausen lars at metafoo.de
Fri Sep 16 18:27:14 CEST 2011


On 09/16/2011 05:47 PM, Timur Tabi wrote:
> Takashi Iwai wrote:
> 
>> It's not optimal from some aspects.  Basically this should be resolved
>> in hw_constraints, not in hw_params, so that the configurator can find
>> the possible rates.  Otherwise you have no idea what rate would be
>> accepted.
> 
> Yes, I was concerned about that.  So should I be calling one of the
> snd_pcm_hw_constraint_xxx functions in the codec's .startup function?  That
> would require ASoC to call the machine driver's .startup function *before*
> calling the codec driver's .startup function, since the machine driver's
> .startup function is where I call the codec to tell it what the mclk frequency is.
> 

You mentioned in an earlyer mail that you can switch the sysclk rate at
runtime. So setting the constraints based on the current sysclk rate won't
really work. I think you need some mechanism to specify the supported rates on
a per machine driver basis.


More information about the Alsa-devel mailing list