drm/i2c: tda998x: only enable audio if supported by sink
authorRussell King <rmk+kernel@armlinux.org.uk>
Wed, 2 Nov 2016 21:15:04 +0000 (21:15 +0000)
committerRussell King <rmk+kernel@armlinux.org.uk>
Fri, 18 Nov 2016 00:00:40 +0000 (00:00 +0000)
commit8f3f21f63c3625165a1a1a6d2978f65df9652d26
treeeba542a415a63985c4482e0d8ff1de2c96ce4f8e
parent896a4130b8e60cbdc92cfdc5b56da1fc2a03f4ad
drm/i2c: tda998x: only enable audio if supported by sink

Check for audio support by the attached sink by consulting the EDID
prior to enabling audio over the TMDS link.  We must consult the EDID
after calling drm_helper_probe_single_connector_modes(), as this can
use an override EDID, or load a replacement EDID.

Tested-by: Jon Medhurst <tixy@linaro.org>
Acked-by: Jon Medhurst <tixy@linaro.org>
Tested-by: Jyri Sarha <jsarha@ti.com>
Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
drivers/gpu/drm/i2c/tda998x_drv.c