summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/omapdrm/dss
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2018-03-02 02:15:36 +0200
committerTomi Valkeinen <tomi.valkeinen@ti.com>2018-09-03 16:13:26 +0300
commit4e0bb06c0b9a025a5a52f93ecef7658d8f8c3c06 (patch)
treedf530ac06e9d47d0afb66e10007b50d6c24fa563 /drivers/gpu/drm/omapdrm/dss
parentb9f4d2ebf641d157be89a68227a5feb00c961d10 (diff)
downloadlinux-4e0bb06c0b9a025a5a52f93ecef7658d8f8c3c06.tar.bz2
drm/omap: dss: Split omapdss_register_display()
Split the function into omapdss_display_init() to perform display-specific initialization of the omap_dss_device, and omapdss_register_display() to register the device. The latter will then be replaced by more generic registration. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Sebastian Reichel <sebastian.reichel@collabora.co.uk> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Diffstat (limited to 'drivers/gpu/drm/omapdrm/dss')
-rw-r--r--drivers/gpu/drm/omapdrm/dss/display.c6
-rw-r--r--drivers/gpu/drm/omapdrm/dss/omapdss.h1
2 files changed, 6 insertions, 1 deletions
diff --git a/drivers/gpu/drm/omapdrm/dss/display.c b/drivers/gpu/drm/omapdrm/dss/display.c
index 5df73cd76153..c641993c7d17 100644
--- a/drivers/gpu/drm/omapdrm/dss/display.c
+++ b/drivers/gpu/drm/omapdrm/dss/display.c
@@ -32,7 +32,7 @@ static LIST_HEAD(panel_list);
static DEFINE_MUTEX(panel_list_mutex);
static int disp_num_counter;
-int omapdss_register_display(struct omap_dss_device *dssdev)
+void omapdss_display_init(struct omap_dss_device *dssdev)
{
int id;
@@ -52,7 +52,11 @@ int omapdss_register_display(struct omap_dss_device *dssdev)
if (dssdev->name == NULL)
dssdev->name = devm_kasprintf(dssdev->dev, GFP_KERNEL,
"display%u", id);
+}
+EXPORT_SYMBOL_GPL(omapdss_display_init);
+int omapdss_register_display(struct omap_dss_device *dssdev)
+{
mutex_lock(&panel_list_mutex);
list_add_tail(&dssdev->panel_list, &panel_list);
mutex_unlock(&panel_list_mutex);
diff --git a/drivers/gpu/drm/omapdrm/dss/omapdss.h b/drivers/gpu/drm/omapdrm/dss/omapdss.h
index 94a3f98bdd3d..e42821583b91 100644
--- a/drivers/gpu/drm/omapdrm/dss/omapdss.h
+++ b/drivers/gpu/drm/omapdrm/dss/omapdss.h
@@ -487,6 +487,7 @@ static inline bool omapdss_is_initialized(void)
return !!omapdss_get_dss();
}
+void omapdss_display_init(struct omap_dss_device *dssdev);
int omapdss_register_display(struct omap_dss_device *dssdev);
void omapdss_unregister_display(struct omap_dss_device *dssdev);
#define for_each_dss_display(d) \