diff options
Diffstat (limited to 'sound/pci/oxygen/oxygen_mixer.c')
-rw-r--r-- | sound/pci/oxygen/oxygen_mixer.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/sound/pci/oxygen/oxygen_mixer.c b/sound/pci/oxygen/oxygen_mixer.c index 4ca12665ff73..81af21ac1439 100644 --- a/sound/pci/oxygen/oxygen_mixer.c +++ b/sound/pci/oxygen/oxygen_mixer.c | |||
@@ -1052,10 +1052,10 @@ static int add_controls(struct oxygen *chip, | |||
1052 | [CONTROL_CD_CAPTURE_SWITCH] = "CD Capture Switch", | 1052 | [CONTROL_CD_CAPTURE_SWITCH] = "CD Capture Switch", |
1053 | [CONTROL_AUX_CAPTURE_SWITCH] = "Aux Capture Switch", | 1053 | [CONTROL_AUX_CAPTURE_SWITCH] = "Aux Capture Switch", |
1054 | }; | 1054 | }; |
1055 | unsigned int i, j; | 1055 | unsigned int i; |
1056 | struct snd_kcontrol_new template; | 1056 | struct snd_kcontrol_new template; |
1057 | struct snd_kcontrol *ctl; | 1057 | struct snd_kcontrol *ctl; |
1058 | int err; | 1058 | int j, err; |
1059 | 1059 | ||
1060 | for (i = 0; i < count; ++i) { | 1060 | for (i = 0; i < count; ++i) { |
1061 | template = controls[i]; | 1061 | template = controls[i]; |
@@ -1086,11 +1086,11 @@ static int add_controls(struct oxygen *chip, | |||
1086 | err = snd_ctl_add(chip->card, ctl); | 1086 | err = snd_ctl_add(chip->card, ctl); |
1087 | if (err < 0) | 1087 | if (err < 0) |
1088 | return err; | 1088 | return err; |
1089 | for (j = 0; j < CONTROL_COUNT; ++j) | 1089 | j = match_string(known_ctl_names, CONTROL_COUNT, ctl->id.name); |
1090 | if (!strcmp(ctl->id.name, known_ctl_names[j])) { | 1090 | if (j >= 0) { |
1091 | chip->controls[j] = ctl; | 1091 | chip->controls[j] = ctl; |
1092 | ctl->private_free = oxygen_any_ctl_free; | 1092 | ctl->private_free = oxygen_any_ctl_free; |
1093 | } | 1093 | } |
1094 | } | 1094 | } |
1095 | return 0; | 1095 | return 0; |
1096 | } | 1096 | } |