[alsa-devel] [PATCH] hda: Advanced power management for codecs.
tiwai at suse.de
Mon Jan 7 18:34:29 CET 2008
At Mon, 07 Jan 2008 12:31:49 -0500,
Matthew Ranostay wrote:
> >> @@ -2830,7 +2883,12 @@ static void stac92xx_hp_detect(struct hd
> >> for (i = 0; i < cfg->speaker_outs; i++)
> >> stac92xx_set_pinctl(codec, cfg->speaker_pins[i],
> >> AC_PINCTL_OUT_EN);
> >> - }
> >> + for (i = 0; i < cfg->hp_outs; i++)
> >> + pwr_state |= 1 << (cfg->hp_pins[i] - 0xa);
> >> + }
> >> +
> >> + /* power down unused ports */
> >> + snd_hda_codec_write(codec, codec->afg, 0, 0x7ec, pwr_state);
> > Is this verb available on every STAC codec? I took a look at some
> > specs but they don't show this verb at all.
> Ah no this a new one for recent codecs, probably need to some sort of
> check for this.
Or is it equivalent to power down each unused pin widget?
If so, we can do it somehow better in the common code.
More information about the Alsa-devel