[alsa-devel] [PATCH v3] ASoC: Add support for cs42l73 codec

Austin, Brian Brian.Austin at cirrus.com
Fri Oct 7 16:05:57 CEST 2011


On Oct 7, 2011, at 6:42 AM, Mark Brown wrote:
> On Fri, Oct 07, 2011 at 04:37:16PM +0530, Vinod Koul wrote:
> 
>> See below:
> 
>> +static const struct snd_kcontrol_new dac1_output_mixer[] = {
>> +       SOC_DAPM_SINGLE("Headphone Switch", CS42L73_PWRCTL3, 0, 1, 1),
>> +       SOC_DAPM_SINGLE("LineOut Switch", CS42L73_PWRCTL3, 1, 1, 1),
>> +};
> 
>> +static const struct snd_kcontrol_new dac2_output_mixer[] = {
>> +       SOC_DAPM_SINGLE("Speakerphone Switch", CS42L73_PWRCTL3, 2, 1,
>> 1),
>> +       SOC_DAPM_SINGLE("Speakerphone LineOut Switch", CS42L73_PWRCTL3,
>> +                       4, 1, 1),
>> +       SOC_DAPM_SINGLE("EarSpeaker Switch", CS42L73_PWRCTL3, 3, 1, 1),
>> +};
> 
>> I think naming should be slightly better :)
> 
> I'm not sure, it might be more than the naming.  The fact that we're in
> PWRCTL registers could be confusing hardware design, or the structure of
> the hardware may not actually reflect what the driver is doing.
> 

The way to enable the output is to enable the output pin.  I have no control in SW 
over the DAC's. The pins are power controlled of course. I know it looks strange, 
but without using a machine driver to enable/disable the pins for a certain route, 
this seems to be the best solution.

I am of course open to other ideas :)


-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 3917 bytes
Desc: not available
Url : http://mailman.alsa-project.org/pipermail/alsa-devel/attachments/20111007/480357db/attachment.p7s 


More information about the Alsa-devel mailing list