ChangeSet 1.2181.25.31, 2005/03/22 09:15:23+01:00, [EMAIL PROTECTED]

        [ALSA] use amp capabilities from afg if amp override not set
        
        HDA Codec driver
        Fix by Matt <[EMAIL PROTECTED]>:
        
        Some HDA codec nodes contain an amp, but do not provide local amp
        capabilities.  In these cases, AC_WCAP_AMP_OVRD is not set so we
        should query the AFG nid in order to get the general amp capabilities.
        
        Signed-off-by: Takashi Iwai <[EMAIL PROTECTED]>



 hda_codec.c |    2 ++
 1 files changed, 2 insertions(+)


diff -Nru a/sound/pci/hda/hda_codec.c b/sound/pci/hda/hda_codec.c
--- a/sound/pci/hda/hda_codec.c 2005-03-30 16:15:48 -08:00
+++ b/sound/pci/hda/hda_codec.c 2005-03-30 16:15:48 -08:00
@@ -611,6 +611,8 @@
        if (! info)
                return 0;
        if (! (info->status & INFO_AMP_CAPS)) {
+               if (!(snd_hda_param_read(codec, nid, AC_PAR_AUDIO_WIDGET_CAP) & 
AC_WCAP_AMP_OVRD))
+                       nid = codec->afg;
                info->amp_caps = snd_hda_param_read(codec, nid, direction == 
HDA_OUTPUT ?
                                                    AC_PAR_AMP_OUT_CAP : 
AC_PAR_AMP_IN_CAP);
                info->status |= INFO_AMP_CAPS;
-
To unsubscribe from this list: send the line "unsubscribe bk-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to