From 24f767bfbeca2db33e3514707c908a06a576fba0 Mon Sep 17 00:00:00 2001 From: Sean Paul Date: Mon, 24 Feb 2014 19:15:38 +0900 Subject: [PATCH] drm/exynos: Add create_connector callback This creates a new display hook called create_connector. The purpose is to allow the display driver to create its own drm_connector instead of using the exynos_drm_connector. This moves things closer to completely removing the exynos_drm_connector abstraction. Signed-off-by: Sean Paul Signed-off-by: Inki Dae --- drivers/gpu/drm/exynos/exynos_drm_core.c | 3 +++ drivers/gpu/drm/exynos/exynos_drm_drv.h | 2 ++ 2 files changed, 5 insertions(+) diff --git a/drivers/gpu/drm/exynos/exynos_drm_core.c b/drivers/gpu/drm/exynos/exynos_drm_core.c index e23611e..eeb5e4e 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_core.c +++ b/drivers/gpu/drm/exynos/exynos_drm_core.c @@ -44,6 +44,9 @@ static int exynos_drm_create_enc_conn(struct drm_device *dev, return -EFAULT; } + if (display->ops->create_connector) + return display->ops->create_connector(display, encoder); + /* * create and initialize a connector for this sub driver and * attach the encoder created above to the connector. diff --git a/drivers/gpu/drm/exynos/exynos_drm_drv.h b/drivers/gpu/drm/exynos/exynos_drm_drv.h index 97bdfcc..06aa27e 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_drv.h +++ b/drivers/gpu/drm/exynos/exynos_drm_drv.h @@ -139,6 +139,8 @@ struct exynos_drm_display; struct exynos_drm_display_ops { int (*initialize)(struct exynos_drm_display *display, struct drm_device *drm_dev); + int (*create_connector)(struct exynos_drm_display *display, + struct drm_encoder *encoder); void (*remove)(struct exynos_drm_display *display); bool (*is_connected)(struct exynos_drm_display *display); void (*get_max_resol)(struct exynos_drm_display *display, -- 2.7.4