mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-01-19 11:43:40 +00:00
ALSA: hda - Don't refer ELD when unplugged
When unplugged, we shouldn't refer to ELD information for PCM open any more. Signed-off-by: Takashi Iwai <tiwai@suse.de> Cc: <stable@kernel.org>
This commit is contained in:
parent
bcb2f0f517
commit
6661702f2e
@ -827,7 +827,7 @@ static int hdmi_pcm_open(struct hda_pcm_stream *hinfo,
|
|||||||
*codec_pars = *hinfo;
|
*codec_pars = *hinfo;
|
||||||
|
|
||||||
eld = &spec->sink_eld[idx];
|
eld = &spec->sink_eld[idx];
|
||||||
if (eld->sad_count > 0) {
|
if (eld->eld_valid && eld->sad_count > 0) {
|
||||||
hdmi_eld_update_pcm_info(eld, hinfo, codec_pars);
|
hdmi_eld_update_pcm_info(eld, hinfo, codec_pars);
|
||||||
if (hinfo->channels_min > hinfo->channels_max ||
|
if (hinfo->channels_min > hinfo->channels_max ||
|
||||||
!hinfo->rates || !hinfo->formats)
|
!hinfo->rates || !hinfo->formats)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user