]> git.karo-electronics.de Git - linux-beck.git/commitdiff
OMAP: DSS2: Make wait_for_go() succeed for disabled displays
authorVille Syrjälä <ville.syrjala@nokia.com>
Thu, 4 Mar 2010 14:03:56 +0000 (16:03 +0200)
committerTomi Valkeinen <tomi.valkeinen@nokia.com>
Tue, 3 Aug 2010 12:18:45 +0000 (15:18 +0300)
When the display is not active make the wait_for_go() functions return
immediately.

Signed-off-by: Ville Syrjälä <ville.syrjala@nokia.com>
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
drivers/video/omap2/dss/manager.c

index 9e1fbe531bf070312ed55ac15560d8e6a1c1ff74..7e1ec5af6c703765359cb9c8b65d2e83b8947072 100644 (file)
@@ -525,7 +525,7 @@ static int dss_mgr_wait_for_go(struct omap_overlay_manager *mgr)
        int i;
        struct omap_dss_device *dssdev = mgr->device;
 
-       if (!dssdev)
+       if (!dssdev || dssdev->state != OMAP_DSS_DISPLAY_ACTIVE)
                return 0;
 
        if (dssdev->type == OMAP_DISPLAY_TYPE_VENC) {
@@ -596,11 +596,14 @@ int dss_mgr_wait_for_go_ovl(struct omap_overlay *ovl)
        int r;
        int i;
 
-       if (!ovl->manager || !ovl->manager->device)
+       if (!ovl->manager)
                return 0;
 
        dssdev = ovl->manager->device;
 
+       if (!dssdev || dssdev->state != OMAP_DSS_DISPLAY_ACTIVE)
+               return 0;
+
        if (dssdev->type == OMAP_DISPLAY_TYPE_VENC) {
                irq = DISPC_IRQ_EVSYNC_ODD | DISPC_IRQ_EVSYNC_EVEN;
                channel = OMAP_DSS_CHANNEL_DIGIT;