[Intel-gfx] [PATCH 3/3] drm/i915: get runtime PM when pinning primary plane objects
Paulo Zanoni
przanoni at gmail.com
Mon Jul 28 20:37:16 CEST 2014
From: Paulo Zanoni <paulo.r.zanoni at intel.com>
Otherwise we may get WARNs saying we're writing registers while
runtime suspended.
Testcase: igt/pm_rpm/universal-planes
Testcase: igt/pm_rpm/universal-planes-dpms
Cc: stable at vger.kernel.org
Signed-off-by: Paulo Zanoni <paulo.r.zanoni at intel.com>
---
drivers/gpu/drm/i915/intel_display.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
index f1a9b5c..5948207 100644
--- a/drivers/gpu/drm/i915/intel_display.c
+++ b/drivers/gpu/drm/i915/intel_display.c
@@ -11531,7 +11531,9 @@ intel_primary_plane_setplane(struct drm_plane *plane, struct drm_crtc *crtc,
INTEL_FRONTBUFFER_PRIMARY(intel_crtc->pipe));
/* Pin and return without programming hardware */
+ intel_runtime_pm_get(dev_priv);
ret = intel_pin_and_fence_fb_obj(dev, obj, NULL);
+ intel_runtime_pm_put(dev_priv);
mutex_unlock(&dev->struct_mutex);
return ret;
@@ -11553,7 +11555,9 @@ intel_primary_plane_setplane(struct drm_plane *plane, struct drm_crtc *crtc,
* fail.
*/
if (plane->fb != fb) {
+ intel_runtime_pm_get(dev_priv);
ret = intel_pin_and_fence_fb_obj(dev, obj, NULL);
+ intel_runtime_pm_put(dev_priv);
if (ret) {
mutex_unlock(&dev->struct_mutex);
return ret;
--
2.0.1
More information about the Intel-gfx
mailing list