ALSA: hda - Allow capture-only configuration
authorTakashi Iwai <tiwai@suse.de>
Fri, 6 Dec 2013 08:30:14 +0000 (09:30 +0100)
committerJaroslav Kysela <perex@perex.cz>
Mon, 16 Dec 2013 09:56:19 +0000 (10:56 +0100)
We have blindly assumed that all valid configurations should have
either analog or digital playback, but there can be capture-only
configurations.  The parser shouldn't escape in such a case.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>

sound/pci/hda/hda_generic.c

index ceecad1..aea8e4d 100644 (file)
@@ -4375,7 +4375,8 @@ int snd_hda_gen_parse_auto_config(struct hda_codec *codec,
                        spec->no_analog = 1;
                        goto dig_only;
                }
-               return 0; /* can't find valid BIOS pin config */
+               if (!cfg->num_inputs && !cfg->dig_in_pin)
+                       return 0; /* can't find valid BIOS pin config */
        }
 
        if (!spec->no_primary_hp &&