[alsa-devel] What is correct way to put conditional stuff in ASoC codec driver?
broonie at opensource.wolfsonmicro.com
Tue Jul 5 21:37:11 CEST 2011
On Tue, Jul 05, 2011 at 07:55:22PM +0530, Ashish Chavan wrote:
> On Tue, 2011-07-05 at 04:04 +0530, Mark Brown wrote:
> > | You'd need to implement custom controls for the relevant enables which
> > | check to see what is currently enabled and prevents enables if there
> > | are conflicts. You should do this dynamically and I'd expect that only
> Yes, I got what you meant here and after some homework also found the
> example of this. You are trying to convey something similar to what is
> done within "outmixer_event()" function of sound/soc/codecs/wm8991.c (at
> lest the condition checking part), right?
No, that's not a user visible control that's part of the internal DAPM
power management stuff. You're looking for struct snd_kcontrol_new
> > All you're doing is trying to restrict the values that can be set on a
> > control dynamically.
> I think, it is more about restricting access to a set of controls
> dynamically based of enable/disable of some other control(s).
The state of another control is one example of a dynamic source of
More information about the Alsa-devel