diff options
author | Takashi Iwai <tiwai@suse.de> | 2013-01-21 11:43:19 +0100 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2013-01-21 11:47:07 +0100 |
commit | 1fa335b0b797811d66a5f88373edd523f947cce4 (patch) | |
tree | b15264e6d29f18889110cfc04ffc440ca76a97bd /sound/pci | |
parent | 9314a5813f62e85c8173adf7fd7e088af3b58942 (diff) | |
download | op-kernel-dev-1fa335b0b797811d66a5f88373edd523f947cce4.zip op-kernel-dev-1fa335b0b797811d66a5f88373edd523f947cce4.tar.gz |
ALSA: hda - Add missing badness evaluation for unresolved paths
When a patch couldn't be resolved in try_assign_dacs() although the
target DAC is expected, we forgot to add a proper badness value but
continued.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci')
-rw-r--r-- | sound/pci/hda/hda_generic.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/sound/pci/hda/hda_generic.c b/sound/pci/hda/hda_generic.c index 7b739b5..4e9761a 100644 --- a/sound/pci/hda/hda_generic.c +++ b/sound/pci/hda/hda_generic.c @@ -1105,14 +1105,17 @@ static int try_assign_dacs(struct hda_codec *codec, int num_outs, else badness += bad->no_dac; } + if (!dac) + continue; path = snd_hda_add_new_path(codec, dac, pin, -spec->mixer_nid); if (!path && !i && spec->mixer_nid) { /* try with aamix */ path = snd_hda_add_new_path(codec, dac, pin, 0); } - if (!path) + if (!path) { dac = dacs[i] = 0; - else { + badness += bad->no_dac; + } else { /* print_nid_path("output", path); */ path->active = true; path_idx[i] = snd_hda_get_path_idx(codec, path); |