浏览代码

ALSA: hda/realtek - Add model=fixup not to apply fix-ups

If anyone wants to debug the driver and avoid the existing fix-ups,
pass model=nofixup option.  Then the driver will skip to pick up the
fixup list.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
Takashi Iwai 13 年之前
父节点
当前提交
9155f82a6a
共有 1 个文件被更改,包括 7 次插入0 次删除
  1. 7 0
      sound/pci/hda/patch_realtek.c

+ 7 - 0
sound/pci/hda/patch_realtek.c

@@ -1556,6 +1556,13 @@ static void alc_pick_fixup(struct hda_codec *codec,
 	int id = -1;
 	int id = -1;
 	const char *name = NULL;
 	const char *name = NULL;
 
 
+	/* when model=nofixup is given, don't pick up any fixups */
+	if (codec->modelname && !strcmp(codec->modelname, "nofixup")) {
+		spec->fixup_list = NULL;
+		spec->fixup_id = -1;
+		return;
+	}
+
 	if (codec->modelname && models) {
 	if (codec->modelname && models) {
 		while (models->name) {
 		while (models->name) {
 			if (!strcmp(codec->modelname, models->name)) {
 			if (!strcmp(codec->modelname, models->name)) {