[alsa-devel] Exporting playback and capture capability to user space

Rajeev kumar rajeev-dlh.kumar at st.com
Wed Nov 23 05:36:33 CET 2011


Hello Mark

On 11/22/2011 6:38 PM, Mark Brown wrote:
> On Tue, Nov 22, 2011 at 09:57:51AM +0530, Rajeev kumar wrote:
>
>>
>> static struct snd_soc_dai_driver sta529_dai = {
>
>> 		.rates = SPEAR_PCM_RATES,
>> 		.formats = SPEAR_PCM_FORMAT,
>
> This looks wrong...
>

Agreed, This should be STA529_RATES and STA529_FORMATS.

>> cpu dai: In case of cpu dai, we are passing the playback and capture
>> capability from the platform code and depending on the capability we
>> are filling the cpu dai structure in probe function, like
>
> Why are you doing this?  Your driver should export the capabilities of
> the hardware and let the machine driver pick any specific configuration
> that's needed.
>

This is needed because we have a single cpu driver for three different 
I2S controller having different capability(as I explained in the first 
mail.). So capabilities are passed from the platform code and get filled 
in the probe part of the i2s controller.


Best Regards
~Rajeev




More information about the Alsa-devel mailing list