From: David Henningsson Date: Wed, 2 Jun 2010 14:56:41 +0000 (+0200) Subject: ALSA: hda - Ensure codec patch files are checked for the correct codec ID X-Git-Tag: v2.6.36-rc1~493^2~2^2~23 X-Git-Url: https://git.kernelconcepts.de/?a=commitdiff_plain;h=2385b789f1525542396d8f6b0cc37c1eb2493b4c;p=karo-tx-linux.git ALSA: hda - Ensure codec patch files are checked for the correct codec ID Signed-off-by: David Henningsson Signed-off-by: Takashi Iwai --- diff --git a/sound/pci/hda/hda_hwdep.c b/sound/pci/hda/hda_hwdep.c index a1fc83753cc6..bf3ced51e0f8 100644 --- a/sound/pci/hda/hda_hwdep.c +++ b/sound/pci/hda/hda_hwdep.c @@ -649,7 +649,9 @@ static void parse_codec_mode(char *buf, struct hda_bus *bus, *codecp = NULL; if (sscanf(buf, "%i %i %i", &vendorid, &subid, &caddr) == 3) { list_for_each_entry(codec, &bus->codec_list, list) { - if (codec->addr == caddr) { + if (codec->vendor_id == vendorid && + codec->subsystem_id == subid && + codec->addr == caddr) { *codecp = codec; break; }