diff options
author | Andrzej Pietrasiewicz <andrzej.p@collabora.com> | 2019-07-26 19:23:11 +0200 |
---|---|---|
committer | Neil Armstrong <narmstrong@baylibre.com> | 2019-07-31 16:33:09 +0200 |
commit | 9572ae176a10f3b2ecfd51bfcd2e949bff566786 (patch) | |
tree | d92633ecf73429a18694257613313ec3c12138b9 /drivers/gpu/drm/mgag200 | |
parent | 7058e76682d762e211e7681155c5e11709182271 (diff) | |
download | linux-stable-9572ae176a10f3b2ecfd51bfcd2e949bff566786.tar.gz linux-stable-9572ae176a10f3b2ecfd51bfcd2e949bff566786.tar.bz2 linux-stable-9572ae176a10f3b2ecfd51bfcd2e949bff566786.zip |
drm/mgag200: Provide ddc symlink in connector sysfs directory
Use the ddc pointer provided by the generic connector.
Signed-off-by: Andrzej Pietrasiewicz <andrzej.p@collabora.com>
Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de>
Acked-by: Sam Ravnborg <sam@ravnborg.org>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
Link: https://patchwork.freedesktop.org/patch/msgid/d9e8d4281f6778e5598410a44f1b29c85df1c16d.1564161140.git.andrzej.p@collabora.com
Diffstat (limited to 'drivers/gpu/drm/mgag200')
-rw-r--r-- | drivers/gpu/drm/mgag200/mgag200_mode.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/drivers/gpu/drm/mgag200/mgag200_mode.c b/drivers/gpu/drm/mgag200/mgag200_mode.c index 822f2a13748f..5e778b5f1a10 100644 --- a/drivers/gpu/drm/mgag200/mgag200_mode.c +++ b/drivers/gpu/drm/mgag200/mgag200_mode.c @@ -1678,18 +1678,19 @@ static struct drm_connector *mga_vga_init(struct drm_device *dev) return NULL; connector = &mga_connector->base; + mga_connector->i2c = mgag200_i2c_create(dev); + if (!mga_connector->i2c) + DRM_ERROR("failed to add ddc bus\n"); - drm_connector_init(dev, connector, - &mga_vga_connector_funcs, DRM_MODE_CONNECTOR_VGA); + drm_connector_init_with_ddc(dev, connector, + &mga_vga_connector_funcs, + DRM_MODE_CONNECTOR_VGA, + &mga_connector->i2c->adapter); drm_connector_helper_add(connector, &mga_vga_connector_helper_funcs); drm_connector_register(connector); - mga_connector->i2c = mgag200_i2c_create(dev); - if (!mga_connector->i2c) - DRM_ERROR("failed to add ddc bus\n"); - return connector; } |