ALSA: hda - fix array indexing while creating inputs for Cirrus codecs

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Linux Kernel Mailing List
Date: Wednesday, May 5, 2010 - 8:59 am

Gitweb:     http://git.kernel.org/linus/8dd34ab111dc6ccb35a1a7a59222cb9bb0160e6f
Commit:     8dd34ab111dc6ccb35a1a7a59222cb9bb0160e6f
Parent:     5c1bccf645d4ab65e4c7502acb42e8b9afdb5bdc
Author:     Brian J. Tarricone <brian@tarricone.org>
AuthorDate: Sun May 2 17:32:10 2010 -0700
Committer:  Takashi Iwai <tiwai@suse.de>
CommitDate: Wed May 5 09:45:33 2010 +0200

    ALSA: hda - fix array indexing while creating inputs for Cirrus codecs
    
    This fixes a problem where cards show up as only having a single mixer
    element, suppressing all sound output.
    
    Signed-off-by: Brian J. Tarricone <brian@tarricone.org>
    Signed-off-by: Takashi Iwai <tiwai@suse.de>
---
 sound/pci/hda/patch_cirrus.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/sound/pci/hda/patch_cirrus.c b/sound/pci/hda/patch_cirrus.c
index 7de782a..350ee8a 100644
--- a/sound/pci/hda/patch_cirrus.c
+++ b/sound/pci/hda/patch_cirrus.c
@@ -766,7 +766,7 @@ static int build_input(struct hda_codec *codec)
 		for (n = 0; n < AUTO_PIN_LAST; n++) {
 			if (!spec->adc_nid[n])
 				continue;
-			err = snd_hda_add_nid(codec, kctl, 0, spec->adc_nid[i]);
+			err = snd_hda_add_nid(codec, kctl, 0, spec->adc_nid[n]);
 			if (err < 0)
 				return err;
 		}
--
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
ALSA: hda - fix array indexing while creating inputs for C ..., Linux Kernel Mailing ..., (Wed May 5, 8:59 am)