mirror of
https://github.com/adulau/aha.git
synced 2024-12-27 19:26:25 +00:00
ALSA: hda - Set mixer name after codec patch
Postpone the mixer name setup after the codec patch since the codec patch may change the codec name string in itself. Signed-off-by: Takashi Iwai <tiwai@suse.de>
This commit is contained in:
parent
9dc8398bab
commit
f62faedbed
1 changed files with 5 additions and 5 deletions
|
@ -1086,11 +1086,6 @@ int snd_hda_codec_configure(struct hda_codec *codec)
|
||||||
if (err < 0)
|
if (err < 0)
|
||||||
return err;
|
return err;
|
||||||
}
|
}
|
||||||
/* audio codec should override the mixer name */
|
|
||||||
if (codec->afg || !*codec->bus->card->mixername)
|
|
||||||
snprintf(codec->bus->card->mixername,
|
|
||||||
sizeof(codec->bus->card->mixername),
|
|
||||||
"%s %s", codec->vendor_name, codec->chip_name);
|
|
||||||
|
|
||||||
if (is_generic_config(codec)) {
|
if (is_generic_config(codec)) {
|
||||||
err = snd_hda_parse_generic_codec(codec);
|
err = snd_hda_parse_generic_codec(codec);
|
||||||
|
@ -1109,6 +1104,11 @@ int snd_hda_codec_configure(struct hda_codec *codec)
|
||||||
patched:
|
patched:
|
||||||
if (!err && codec->patch_ops.unsol_event)
|
if (!err && codec->patch_ops.unsol_event)
|
||||||
err = init_unsol_queue(codec->bus);
|
err = init_unsol_queue(codec->bus);
|
||||||
|
/* audio codec should override the mixer name */
|
||||||
|
if (!err && (codec->afg || !*codec->bus->card->mixername))
|
||||||
|
snprintf(codec->bus->card->mixername,
|
||||||
|
sizeof(codec->bus->card->mixername),
|
||||||
|
"%s %s", codec->vendor_name, codec->chip_name);
|
||||||
return err;
|
return err;
|
||||||
}
|
}
|
||||||
EXPORT_SYMBOL_HDA(snd_hda_codec_configure);
|
EXPORT_SYMBOL_HDA(snd_hda_codec_configure);
|
||||||
|
|
Loading…
Reference in a new issue