aboutsummaryrefslogtreecommitdiffstats
path: root/sound
diff options
context:
space:
mode:
authorDavid Henningsson <david.henningsson@canonical.com>2013-01-18 15:43:02 +0100
committerTakashi Iwai <tiwai@suse.de>2013-01-18 15:49:04 +0100
commit8e8db7f123dcc4d56464fc584667c8f9ae9f4aef (patch)
tree89b25d9b3d9d29482a5a3a68d15a9d12d620d148 /sound
parentALSA: hda - make sure there are enough input labels and paths (diff)
downloadlinux-dev-8e8db7f123dcc4d56464fc584667c8f9ae9f4aef.tar.xz
linux-dev-8e8db7f123dcc4d56464fc584667c8f9ae9f4aef.zip
ALSA: hda - don't compare with yourself in fill_input_pin_labels
Just stumbled over this one while reading the code. Signed-off-by: David Henningsson <david.henningsson@canonical.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound')
-rw-r--r--sound/pci/hda/hda_generic.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/pci/hda/hda_generic.c b/sound/pci/hda/hda_generic.c
index 10b14a925ddb..e4e71fa8d87c 100644
--- a/sound/pci/hda/hda_generic.c
+++ b/sound/pci/hda/hda_generic.c
@@ -2558,7 +2558,7 @@ static int fill_input_pin_labels(struct hda_codec *codec)
label = hda_get_autocfg_input_label(codec, cfg, i);
idx = 0;
- for (j = i; j >= 0; j--) {
+ for (j = i - 1; j >= 0; j--) {
if (spec->input_labels[j] &&
!strcmp(spec->input_labels[j], label)) {
idx = spec->input_label_idxs[j] + 1;