[alsa-devel] [dapm question] About "playback_widget" power on or not

胡洪兵 huhb04 at gmail.com
Mon Apr 21 09:10:20 CEST 2014


hi  dapm developers,

I have a question about "playback_widget".

Nobody gives me right answer, so email the question to devel maillist.

I am sorry to disturb you and thanks for your explain

Question:

my machine driver export two pcm devices,  eg. "pcm0", "pcm1".

Open the "pcm0" for Playback, just active AIF3 playback_widget "AIF3
Playbck".

at same time,one path of pcm1 is also power on。

the path is “Headset Mic -> IN3R -> AIF1TX Input 1 -> AIF1TX Mixer ->
AIF1TX -> AIF1 Playbck -> AIF1RX1 -> Headphone Input 1 -> Headphone Mixer
-> Headphone”

my question is "the widgets of the path should be powered or not ?"

I guess that the path should not be powered, because  "pcm1" is not open,
all paths of it should not be actvie.

Maybe I am wrong, but let me known.

Thank you very much!

***************************************************************case
snd_soc_dapm_dai_in:
	w->power_check = dapm_dac_check_power;


/* Check to see if a DAC has power */static int
dapm_dac_check_power(struct snd_soc_dapm_widget *w){
	int out;

	DAPM_UPDATE_STAT(w, power_checks);

	if (w->active) {
		out = is_connected_output_ep(w, NULL);
		dapm_clear_walk_output(w->dapm, &w->sinks);
		return out != 0;
	} else {
		return dapm_generic_check_power(w);
	}}
***************************************************************


More information about the Alsa-devel mailing list