]> rtime.felk.cvut.cz Git - linux-imx.git/commitdiff
drm/i915: only disable enabled planes on intel_fb_restore_mode
authorPaulo Zanoni <paulo.r.zanoni@intel.com>
Fri, 25 Jan 2013 18:59:13 +0000 (16:59 -0200)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Sat, 26 Jan 2013 16:56:16 +0000 (17:56 +0100)
We should avoid touching registers that are on the power down well
when we don't need to, because if we touch these registers when the
power well is disabled we'll get tons of "unclaimed register"
messages. This commit fixes some of these messages.

Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/i915/intel_fb.c

index ce5f54498426eb62266054245623abddd9fbadec..6591029ac0d70f0250f695a8143b79c1e567bf3e 100644 (file)
@@ -304,7 +304,8 @@ void intel_fb_restore_mode(struct drm_device *dev)
 
        /* Be sure to shut off any planes that may be active */
        list_for_each_entry(plane, &config->plane_list, head)
-               plane->funcs->disable_plane(plane);
+               if (plane->enabled)
+                       plane->funcs->disable_plane(plane);
 
        mutex_unlock(&dev->mode_config.mutex);
 }