[alsa-devel] [PATCH 2/5] ASoC: Add ADAU1361/ADAU1761 audio CODEC support

Lars-Peter Clausen lars at metafoo.de
Thu Aug 29 10:02:47 CEST 2013

On 08/28/2013 07:24 PM, Mark Brown wrote:
> On Wed, Aug 28, 2013 at 05:20:10PM +0200, Lars-Peter Clausen wrote:
>> +static const char * const adau1761_bias_select_text[] = {
>> +	"Normal operation", "Enhanced performance", "Power saving",
>> +};
>> +
>> +static const char * const adau1761_bias_select_extreme_text[] = {
>> +	"Normal operation", "Extreme power saving", "Enhanced performance",
>> +	"Power saving",
>> +};
> Not a requirement and perhaps it has no effect but these seem like they
> ought to integrate with the bias level configuration - since only the
> clocks seem to be managed by set_bias_level() the driver could
> presumably save a bit of power by dropping down to the minimal power
> consumption bias while the device is idle.  This is what the STANDBY to
> ON transition is all about.

Hm, I'm not sure if it makes a difference since all the components have
individual power control bits that are managed by DAPM. I would expect the
bias current setting to only make a difference if the component is actually
powered up. I'll check with the designers, but I think this can still be
improved later on if it turns out that it saves power.

>> +static const struct snd_kcontrol_new adau1761_jack_detect_controls[] = {
>> +	SOC_SINGLE("Jack Detect Switch", ADAU1761_DIGMIC_JACKDETECT, 4, 1, 0),
>> +};
> Why is this a user visible control and not using the jack detection
> framework support?

The CODEC unfortunately does not support reporting the jack state. All it
can do is mute the speaker output in hardware if something is plugged into
the headphone jack. The switch allows the users to control whether the
output should be auto-muted or not.

More information about the Alsa-devel mailing list