[PATCH 3/4] drm: bridge/dw-hdmi: detect initial connector state

Philipp Zabel p.zabel at pengutronix.de
Fri Jan 8 01:02:06 PST 2016


Allow userspace to read the initial connector state via sysfs without
having to issue a detect manually. There is no reason to keep the state
unknown during initialization.

Signed-off-by: Philipp Zabel <p.zabel at pengutronix.de>
---
 drivers/gpu/drm/bridge/dw-hdmi.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/gpu/drm/bridge/dw-hdmi.c b/drivers/gpu/drm/bridge/dw-hdmi.c
index e41ff4b..2388a55 100644
--- a/drivers/gpu/drm/bridge/dw-hdmi.c
+++ b/drivers/gpu/drm/bridge/dw-hdmi.c
@@ -1660,6 +1660,8 @@ static int dw_hdmi_register(struct drm_device *drm, struct dw_hdmi *hdmi)
 				   DRM_MODE_CONNECTOR_HDMIA);
 
 	hdmi->connector.encoder = encoder;
+	hdmi->connector.status = dw_hdmi_connector_detect(&hdmi->connector,
+							  false);
 
 	drm_mode_connector_attach_encoder(&hdmi->connector, encoder);
 
-- 
2.6.4



More information about the dri-devel mailing list