[alsa-devel] [PATCH 4/4] ASoC: add Component level set_bias_level

Kuninori Morimoto kuninori.morimoto.gx at renesas.com
Mon Aug 28 07:27:52 CEST 2017


Hi Mark

> > > Oops... new component want to have .idle_bias_off / .suspend_bias_off ?
> > 
> > Yes, they're different and both useful.
> 
> OK, my concern is these "default".
> Non-codec case, .idle_bias_off = true is default,
> In codec case, .idle_bias_off = codec_drv->idle_bias_off (= 0) is default.
> we can add .idle_bias_off = true on all non-codec driver, but it needs
> big-patch. but is it OK ?

In the future, it will be "Component" base framework, so, I want to
think "Component" base.
Now, codec and internal component are using .idle_bias_off for dapm
and its default is...

	On Component
		dapm->idle_bias_off = true;
	On Codec
		dapm->idle_bias_off = codec_drv->idle_bias_off;
		dapm->suspend_bias_off = codec_drv->suspend_bias_off;

Thus, default (= no settings) will be

	Component idle_bias_off    : true;
	Codec     idle_bias_off    : false;

Can I add idel_bias_on instead of idel_bias_off ?
                    ~~                      ~~~
It can keep compatibility, and reduce cost. only codec driver needs change
and anyway it needs change (= when it replace codec to component).

	Component driver
		dapm->idle_bias_off = !driver->idle_bias_on;

	Component user
		no change
	Codec user which has .idle_bias_off = true
		- .idle_bias_off = true,
	Codec user which doesn't has .idle_bias_off = true
		+ .idle_bias_on = true,

Best regards
---
Kuninori Morimoto


More information about the Alsa-devel mailing list