From: Sumit Semwal <[email protected]>

The addition of the new 2lcd manager requires modifications in the
dss_recheck_connections patch, this function behaves the same if
the 2lcd manager doesn't exist

Signed-off-by: Sumit Semwal <[email protected]>
Signed-off-by: Senthilvadivu Guruswamy <[email protected]>
Signed-off-by: Mukund Mittal <[email protected]>
Signed-off-by: Archit Taneja <[email protected]>
Signed-off-by: Samreen <[email protected]>
---
 drivers/video/omap2/dss/overlay.c |   14 ++++++++++++--
 1 files changed, 12 insertions(+), 2 deletions(-)

diff --git a/drivers/video/omap2/dss/overlay.c 
b/drivers/video/omap2/dss/overlay.c
index 8233658..c7ad1d1
--- a/drivers/video/omap2/dss/overlay.c
+++ b/drivers/video/omap2/dss/overlay.c
@@ -627,12 +627,22 @@ void dss_recheck_connections(struct omap_dss_device 
*dssdev, bool force)
        int i;
        struct omap_overlay_manager *lcd_mgr;
        struct omap_overlay_manager *tv_mgr;
+       struct omap_overlay_manager *lcd2_mgr = NULL;
        struct omap_overlay_manager *mgr = NULL;
 
        lcd_mgr = omap_dss_get_overlay_manager(OMAP_DSS_OVL_MGR_LCD);
        tv_mgr = omap_dss_get_overlay_manager(OMAP_DSS_OVL_MGR_TV);
-
-       if (dssdev->type != OMAP_DISPLAY_TYPE_VENC) {
+       if (cpu_is_omap44xx())
+               lcd2_mgr = omap_dss_get_overlay_manager(OMAP_DSS_OVL_MGR_LCD2);
+
+       if (dssdev->channel == OMAP_DSS_CHANNEL_LCD2) {
+               if (!lcd2_mgr->device || force) {
+                       if (lcd2_mgr->device)
+                               lcd2_mgr->unset_device(lcd2_mgr);
+                       lcd2_mgr->set_device(lcd2_mgr, dssdev);
+                       mgr = lcd2_mgr;
+               }
+       } else if (dssdev->type != OMAP_DISPLAY_TYPE_VENC) {
                if (!lcd_mgr->device || force) {
                        if (lcd_mgr->device)
                                lcd_mgr->unset_device(lcd_mgr);
-- 
1.6.3.3

--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to