Skip to contentSkip to conversation

hda: dinput_mux check

PATCH Applied Matthew Ranostay 2 participants 3 messages Dec 20, 2008

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 hda: dinput_mux check

Add check to determine if dinput_mux is set by any of patch_stac*() functions, otherwise a invalid pointer my be referenced causing gibberish to mixer values.

---

pci/hda/patch_sigmatel.c +2 -1
index 70181d5..fa87893 100644
@@ -3601,7 +3601,8 @@ static int stac92xx_parse_auto_config(struct hda_codec *codec, hda_nid_t dig_out
 		spec->mixers[spec->num_mixers++] = spec->kctls.list;
 
 	spec->input_mux = &spec->private_imux;
-	spec->dinput_mux = &spec->private_dimux;
+	if (!spec->dinput_mux)
+		spec->dinput_mux = &spec->private_dimux;
 	spec->sinput_mux = &spec->private_smux;
 	spec->mono_mux = &spec->private_mono_mux;
 	spec->amp_mux = &spec->private_amp_mux;
Applied
#1 lore raw

At Sat, 20 Dec 2008 17:36:28 -0500,

Quoted 3 lines · Matthew Ranostay

Add check to determine if dinput_mux is set by any of patch_stac*() functions, otherwise a invalid pointer my be referenced causing gibberish to mixer values.

Thanks, applied now.

BTW, which git tree are you checking?
For the latest STAC/IDT code, always check
git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6.git

Takashi

#2 lore raw
Quoted 11 lines · Takashi Iwai

At Sat, 20 Dec 2008 17:36:28 -0500,

Quoted 2 lines · Matthew Ranostay

Add check to determine if dinput_mux is set by any of patch_stac*() functions, otherwise a invalid pointer my be referenced causing gibberish to mixer values.

Thanks, applied now.

BTW, which git tree are you checking?
For the latest STAC/IDT code, always check
git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6.git

OK, will do.

I was using the alsa-kmirror.git tree.

Thanks,

Matt Ranostay

Quoted 3 lines

Takashi