Commit c360824a authored by Andrzej Pietrasiewicz's avatar Andrzej Pietrasiewicz Committed by Jani Nikula

drm/i915: Provide ddc symlink in hdmi connector sysfs directory

Use the ddc pointer provided by the generic connector.
Signed-off-by: default avatarAndrzej Pietrasiewicz <andrzej.p@collabora.com>
Acked-by: default avatarSam Ravnborg <sam@ravnborg.org>
Reviewed-by: default avatarEmil Velikov <emil.velikov@collabora.com>
Signed-off-by: default avatarJani Nikula <jani.nikula@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20191128150130.26266-1-andrzej.p@collabora.com
parent d6f970f0
...@@ -3131,6 +3131,7 @@ void intel_hdmi_init_connector(struct intel_digital_port *intel_dig_port, ...@@ -3131,6 +3131,7 @@ void intel_hdmi_init_connector(struct intel_digital_port *intel_dig_port,
struct intel_encoder *intel_encoder = &intel_dig_port->base; struct intel_encoder *intel_encoder = &intel_dig_port->base;
struct drm_device *dev = intel_encoder->base.dev; struct drm_device *dev = intel_encoder->base.dev;
struct drm_i915_private *dev_priv = to_i915(dev); struct drm_i915_private *dev_priv = to_i915(dev);
struct i2c_adapter *ddc;
enum port port = intel_encoder->port; enum port port = intel_encoder->port;
struct cec_connector_info conn_info; struct cec_connector_info conn_info;
...@@ -3146,8 +3147,13 @@ void intel_hdmi_init_connector(struct intel_digital_port *intel_dig_port, ...@@ -3146,8 +3147,13 @@ void intel_hdmi_init_connector(struct intel_digital_port *intel_dig_port,
intel_encoder->base.name)) intel_encoder->base.name))
return; return;
drm_connector_init(dev, connector, &intel_hdmi_connector_funcs, intel_hdmi->ddc_bus = intel_hdmi_ddc_pin(dev_priv, port);
DRM_MODE_CONNECTOR_HDMIA); ddc = intel_gmbus_get_adapter(dev_priv, intel_hdmi->ddc_bus);
drm_connector_init_with_ddc(dev, connector,
&intel_hdmi_connector_funcs,
DRM_MODE_CONNECTOR_HDMIA,
ddc);
drm_connector_helper_add(connector, &intel_hdmi_connector_helper_funcs); drm_connector_helper_add(connector, &intel_hdmi_connector_helper_funcs);
connector->interlace_allowed = 1; connector->interlace_allowed = 1;
...@@ -3157,8 +3163,6 @@ void intel_hdmi_init_connector(struct intel_digital_port *intel_dig_port, ...@@ -3157,8 +3163,6 @@ void intel_hdmi_init_connector(struct intel_digital_port *intel_dig_port,
if (INTEL_GEN(dev_priv) >= 10 || IS_GEMINILAKE(dev_priv)) if (INTEL_GEN(dev_priv) >= 10 || IS_GEMINILAKE(dev_priv))
connector->ycbcr_420_allowed = true; connector->ycbcr_420_allowed = true;
intel_hdmi->ddc_bus = intel_hdmi_ddc_pin(dev_priv, port);
intel_encoder->hpd_pin = intel_hpd_pin_default(dev_priv, port); intel_encoder->hpd_pin = intel_hpd_pin_default(dev_priv, port);
if (HAS_DDI(dev_priv)) if (HAS_DDI(dev_priv))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment