Skip to content

Commit

Permalink
ALSA: hda - Check bit mask for codec SSID in snd_hda_pick_fixup()
Browse files Browse the repository at this point in the history
snd_hda_pick_fixup() didn't check the case where the device mask bits
are set, typically used for SND_PCI_QUIRK_VENDOR() entries.  Fix this.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
  • Loading branch information
Takashi Iwai committed Sep 11, 2012
1 parent 915bf29 commit a33b7b0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion sound/pci/hda/hda_auto_parser.c
Original file line number Diff line number Diff line change
Expand Up @@ -735,7 +735,8 @@ void snd_hda_pick_fixup(struct hda_codec *codec,
for (q = quirk; q->subvendor; q++) {
unsigned int vendorid =
q->subdevice | (q->subvendor << 16);
if (vendorid == codec->subsystem_id) {
unsigned int mask = 0xffff0000 | q->subdevice_mask;
if ((codec->subsystem_id & mask) == (vendorid & mask)) {
id = q->value;
#ifdef CONFIG_SND_DEBUG_VERBOSE
name = q->name;
Expand Down

0 comments on commit a33b7b0

Please sign in to comment.