diff options
author | Kai-Heng Feng <kai.heng.feng@canonical.com> | 2021-12-02 15:33:35 +0800 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2021-12-02 09:05:21 +0100 |
commit | ce9778b7a0272f7c7e5bc33f537380a5d2aed6c7 (patch) | |
tree | 5a8e1d2750d3f42c38b8aa9fe29ffacea6dda380 /sound/pci/hda/patch_hdmi.c | |
parent | 8e7daf318d97f25e18b2fc7eb5909e34cd903575 (diff) | |
download | linux-ce9778b7a0272f7c7e5bc33f537380a5d2aed6c7.tar.bz2 |
ALSA: hda/hdmi: Consider ELD is invalid when no SAD is present
There's a system that reports a bogus HDMI audio interface:
$ cat eld#2.0
monitor_present 1
eld_valid 1
monitor_name
connection_type DisplayPort
eld_version [0x2] CEA-861D or below
edid_version [0x3] CEA-861-B, C or D
manufacture_id 0xe430
product_id 0x690
port_id 0x0
support_hdcp 0
support_ai 0
audio_sync_delay 0
speakers [0xffff] FL/FR LFE FC RL/RR RC FLC/FRC RLC/RRC FLW/FRW FLH/FRH TC FCH
sad_count 0
Since playing audio is not possible without SAD, also consider ELD is
invalid for this case.
Signed-off-by: Kai-Heng Feng <kai.heng.feng@canonical.com>
Link: https://lore.kernel.org/r/20211202073338.1384768-1-kai.heng.feng@canonical.com
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci/hda/patch_hdmi.c')
-rw-r--r-- | sound/pci/hda/patch_hdmi.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sound/pci/hda/patch_hdmi.c b/sound/pci/hda/patch_hdmi.c index 65d2c5539919..33e5f1aa24f9 100644 --- a/sound/pci/hda/patch_hdmi.c +++ b/sound/pci/hda/patch_hdmi.c @@ -1535,7 +1535,7 @@ static void update_eld(struct hda_codec *codec, } } - if (!eld->eld_valid || eld->eld_size <= 0) { + if (!eld->eld_valid || eld->eld_size <= 0 || eld->info.sad_count <= 0) { eld->eld_valid = false; eld->eld_size = 0; } |