[alsa-devel] alsactl adds volume controls?

Takashi Iwai tiwai at suse.de
Mon Aug 30 13:09:17 CEST 2010


At Mon, 30 Aug 2010 17:30:19 +0800,
Raymond Yau wrote:
> 
> 2010/8/30 Takashi Iwai <tiwai at suse.de>
> 
> > At Sat, 28 Aug 2010 06:58:20 +0800,
> > Raymond Yau wrote:
> > >
> > > 2010/8/28 David Henningsson <david.henningsson at canonical.com>
> > >
> > > > 2010-08-27 17:43, Clemens Ladisch skrev:
> > > > > David Henningsson wrote:
> > > > >> So I've discovered that my sound card has a "PCM Playback Volume"
> > > > >> control, but changing that control does not alter the volume.
> > > > >>
> > > > >> Interestingly enough, this control does not come from the HDA
> > parser, it
> > > > >> is added by alsactl at boot time...!
> > > > >
> > > > > This control was created by the software volume plugin.  When not
> > using
> > > > > this plugin, the control does not have any effect.
> > > > >
> > > > > To get rid of it, delete its entry from /etc/asound.state.
> > > >
> > > > Hmm, I wonder if this is an Ubuntu-specific bug then? Because when I
> > run
> > > > Maverick (the upcoming Ubuntu release) from a Live-CD, the "PCM
> > Playback
> > > > Volume" control is still there (and there is no asound.state, neither
> > in
> > > > /etc or in /var/lib/alsa).
> > > > When I use the plughw interface, the "PCM Playback Volume" does not
> > > > affect volume output. Should I use another device string to test the
> > > > softvol plugin, to see if it's there or not?
> > > >
> > >
> > > The softvol plugin it is defined in "front" device in
> > > /usr/share/alsa/cards/HDA-Intel.conf
> > >
> > > reason is some HDA codec does not has any hardware volume control
> > (analog)
> > >
> > > this user-defined control only effective when the application use "front"
> > > device
> >
> > Hm, but if PA opens the device with SND_PCM_NO_SOFTVOL flag, the
> > softvol should be skipped.
> >
> >
> AFAIK, PA did not use SND_PCM_NO_SOFTVOL and in "analog stereo duplex"
> profile , PA open "front" device for playback and capture which access the
> same "PCM Playback volume" control concurrently

OK, then the fix would be let PA use this flag.
The softvol makes really no sense for PA...


Takashi

> You can see the output of snd_pcm_dump() in the pulseraudio log still
> contain soffvol which is an indiication that PA did not use
> SND_PCM_NO_SOFTVOL
> 
> the softvol control can only be distinguished using
> snd_ctl_elem_info_is_user()  and there is no snd_mixer_* function to find
> out the softvol control since PA server use simple mixer api
> _______________________________________________
> Alsa-devel mailing list
> Alsa-devel at alsa-project.org
> http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
> 


More information about the Alsa-devel mailing list