drm/omap: add dispc_channel_connected field to omap_dss_device
We want to remove the 'struct omap_overlay_manager' from
omap_dss_device. At the moment that field is used, among some other
uses, to see if the omap_dss_device is connected to an overlay manager.
To make it possible to remove the 'struct omap_overlay_manager' field,
this patch adds 'bool dispc_channel_connected' field to track the
connected-or-not status.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
diff --git a/drivers/gpu/drm/omapdrm/omap_crtc.c b/drivers/gpu/drm/omapdrm/omap_crtc.c
index cb5a30e..3667ff1 100644
--- a/drivers/gpu/drm/omapdrm/omap_crtc.c
+++ b/drivers/gpu/drm/omapdrm/omap_crtc.c
@@ -111,6 +111,7 @@
return -EINVAL;
omap_crtc_output[channel] = dst;
+ dst->dispc_channel_connected = true;
dst->manager = mgr;
mgr->output = dst;
@@ -124,6 +125,7 @@
struct omap_overlay_manager *mgr = omap_dss_get_overlay_manager(channel);
omap_crtc_output[channel] = NULL;
+ dst->dispc_channel_connected = false;
mgr->output->manager = NULL;
mgr->output = NULL;