summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/omapdrm/displays/panel-tpo-td043mtea1.c
diff options
context:
space:
mode:
authorLaurent Pinchart2018-03-04 22:42:36 +0100
committerTomi Valkeinen2018-09-03 15:13:27 +0200
commit511afb44d72aa7b6b871fa71f829afaaa27e84f0 (patch)
treee5c3c1fced5108a88c1bd06e0f3b98a6aa082e94 /drivers/gpu/drm/omapdrm/displays/panel-tpo-td043mtea1.c
parentdrm/omap: Group CRTC, encoder, connector and dssdev in a structure (diff)
downloadkernel-qcow2-linux-511afb44d72aa7b6b871fa71f829afaaa27e84f0.tar.gz
kernel-qcow2-linux-511afb44d72aa7b6b871fa71f829afaaa27e84f0.tar.xz
kernel-qcow2-linux-511afb44d72aa7b6b871fa71f829afaaa27e84f0.zip
drm/omap: Reverse direction of DSS device (dis)connect operations
The omapdrm and omapdss drivers are architectured based on display pipelines made of multiple components handled from sink (display) to source (DSS output). This is incompatible with the DRM bridge and panel APIs that handle components from source to sink. To reconcile the omapdrm and omapdss drivers with the DRM bridge and panel model, we need to reverse the direction of the DSS device operations. Start with the connect and disconnect operations. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Diffstat (limited to 'drivers/gpu/drm/omapdrm/displays/panel-tpo-td043mtea1.c')
-rw-r--r--drivers/gpu/drm/omapdrm/displays/panel-tpo-td043mtea1.c27
1 files changed, 4 insertions, 23 deletions
diff --git a/drivers/gpu/drm/omapdrm/displays/panel-tpo-td043mtea1.c b/drivers/gpu/drm/omapdrm/displays/panel-tpo-td043mtea1.c
index 719c298d3996..cb6f19f8a0da 100644
--- a/drivers/gpu/drm/omapdrm/displays/panel-tpo-td043mtea1.c
+++ b/drivers/gpu/drm/omapdrm/displays/panel-tpo-td043mtea1.c
@@ -336,33 +336,15 @@ static void tpo_td043_power_off(struct panel_drv_data *ddata)
ddata->powered_on = 0;
}
-static int tpo_td043_connect(struct omap_dss_device *dssdev)
+static int tpo_td043_connect(struct omap_dss_device *src,
+ struct omap_dss_device *dst)
{
- struct omap_dss_device *src;
- int r;
-
- src = omapdss_of_find_connected_device(dssdev->dev->of_node, 0);
- if (IS_ERR_OR_NULL(src)) {
- dev_err(dssdev->dev, "failed to find video source\n");
- return src ? PTR_ERR(src) : -EINVAL;
- }
-
- r = omapdss_device_connect(dssdev->dss, src, dssdev);
- if (r) {
- omapdss_device_put(src);
- return r;
- }
-
return 0;
}
-static void tpo_td043_disconnect(struct omap_dss_device *dssdev)
+static void tpo_td043_disconnect(struct omap_dss_device *src,
+ struct omap_dss_device *dst)
{
- struct omap_dss_device *src = dssdev->src;
-
- omapdss_device_disconnect(src, dssdev);
-
- omapdss_device_put(src);
}
static int tpo_td043_enable(struct omap_dss_device *dssdev)
@@ -553,7 +535,6 @@ static int tpo_td043_remove(struct spi_device *spi)
omapdss_device_unregister(dssdev);
tpo_td043_disable(dssdev);
- omapdss_device_disconnect(dssdev, NULL);
sysfs_remove_group(&spi->dev.kobj, &tpo_td043_attr_group);