{
const struct snd_hda_pin_quirk *pq;
- if (codec->fixup_forced)
+ if (codec->fixup_id != HDA_FIXUP_ID_NOT_SET)
return;
for (pq = pin_quirk; pq->subvendor; pq++) {
const struct hda_fixup *fixlist)
{
const struct snd_pci_quirk *q;
- int id = -1;
+ int id = HDA_FIXUP_ID_NOT_SET;
const char *name = NULL;
+ if (codec->fixup_id != HDA_FIXUP_ID_NOT_SET)
+ return;
+
/* when model=nofixup is given, don't pick up any fixups */
if (codec->modelname && !strcmp(codec->modelname, "nofixup")) {
codec->fixup_list = NULL;
- codec->fixup_id = -1;
- codec->fixup_forced = 1;
+ codec->fixup_name = NULL;
+ codec->fixup_id = HDA_FIXUP_ID_NO_FIXUP;
return;
}
codec->fixup_id = models->id;
codec->fixup_name = models->name;
codec->fixup_list = fixlist;
- codec->fixup_forced = 1;
return;
}
models++;
}
}
- if (id < 0 && quirk) {
+ if (quirk) {
q = snd_pci_quirk_lookup(codec->bus->pci, quirk);
if (q) {
id = q->value;
}
}
- codec->fixup_forced = 0;
codec->fixup_id = id;
if (id >= 0) {
codec->fixup_list = fixlist;
{
if (action != HDA_FIXUP_ACT_PRE_PROBE)
return;
+
+ codec->fixup_id = HDA_FIXUP_ID_NOT_SET;
snd_hda_pick_fixup(codec, NULL, cs4208_mac_fixup_tbl, cs4208_fixups);
- if (codec->fixup_id < 0 || codec->fixup_id == CS4208_MAC_AUTO)
+ if (codec->fixup_id == HDA_FIXUP_ID_NOT_SET)
codec->fixup_id = CS4208_GPIO0; /* default fixup */
snd_hda_apply_fixup(codec, action);
}
{
if (action != HDA_FIXUP_ACT_PRE_PROBE)
return;
+
+ codec->fixup_id = HDA_FIXUP_ID_NOT_SET;
snd_hda_pick_fixup(codec, NULL, stac922x_intel_mac_fixup_tbl,
stac922x_fixups);
- if (codec->fixup_id != STAC_INTEL_MAC_AUTO)
+ if (codec->fixup_id != HDA_FIXUP_ID_NOT_SET)
snd_hda_apply_fixup(codec, action);
}