<div dir="ltr">Reviewed-by: Rodrigo Vivi <<a href="mailto:rodrigo.vivi@intel.com">rodrigo.vivi@intel.com</a>><br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Jun 16, 2014 at 10:51 AM, Daniel Vetter <span dir="ltr"><<a href="mailto:daniel.vetter@ffwll.ch" target="_blank">daniel.vetter@ffwll.ch</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">We have _enable/_disable interfaces now for the modeset sequence and<br>
intel_edp_psr_exit for workarounds.<br>
<br>
The callsites in intel_display.c are all redundant with the modeset<br>
sequence enable/disable calls in intel_ddi.c. The one in<br>
intel_sprite.c is real and needs to be switched to psr_exit.<br>
<br>
If this breaks anything then we need to augment the enable/disable<br>
functions accordingly.<br>
<br>
Cc: Rodrigo Vivi <<a href="mailto:rodrigo.vivi@intel.com">rodrigo.vivi@intel.com</a>><br>
Signed-off-by: Daniel Vetter <<a href="mailto:daniel.vetter@ffwll.ch">daniel.vetter@ffwll.ch</a>><br>
---<br>
 drivers/gpu/drm/i915/intel_display.c |  5 -----<br>
 drivers/gpu/drm/i915/intel_dp.c      | 13 -------------<br>
 drivers/gpu/drm/i915/intel_drv.h     |  1 -<br>
 drivers/gpu/drm/i915/intel_sprite.c  |  2 +-<br>
 4 files changed, 1 insertion(+), 20 deletions(-)<br>
<br>
diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c<br>
index a0f4709f9479..c27dadebd0dc 100644<br>
--- a/drivers/gpu/drm/i915/intel_display.c<br>
+++ b/drivers/gpu/drm/i915/intel_display.c<br>
@@ -2763,7 +2763,6 @@ intel_pipe_set_base(struct drm_crtc *crtc, int x, int y,<br>
<br>
        mutex_lock(&dev->struct_mutex);<br>
        intel_update_fbc(dev);<br>
-       intel_edp_psr_update(dev);<br>
        mutex_unlock(&dev->struct_mutex);<br>
<br>
        return 0;<br>
@@ -3943,7 +3942,6 @@ static void intel_crtc_enable_planes(struct drm_crtc *crtc)<br>
<br>
        mutex_lock(&dev->struct_mutex);<br>
        intel_update_fbc(dev);<br>
-       intel_edp_psr_update(dev);<br>
        mutex_unlock(&dev->struct_mutex);<br>
 }<br>
<br>
@@ -4236,7 +4234,6 @@ static void ironlake_crtc_disable(struct drm_crtc *crtc)<br>
<br>
        mutex_lock(&dev->struct_mutex);<br>
        intel_update_fbc(dev);<br>
-       intel_edp_psr_update(dev);<br>
        mutex_unlock(&dev->struct_mutex);<br>
 }<br>
<br>
@@ -4284,7 +4281,6 @@ static void haswell_crtc_disable(struct drm_crtc *crtc)<br>
<br>
        mutex_lock(&dev->struct_mutex);<br>
        intel_update_fbc(dev);<br>
-       intel_edp_psr_update(dev);<br>
        mutex_unlock(&dev->struct_mutex);<br>
 }<br>
<br>
@@ -4836,7 +4832,6 @@ static void i9xx_crtc_disable(struct drm_crtc *crtc)<br>
<br>
        mutex_lock(&dev->struct_mutex);<br>
        intel_update_fbc(dev);<br>
-       intel_edp_psr_update(dev);<br>
        mutex_unlock(&dev->struct_mutex);<br>
 }<br>
<br>
diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c<br>
index 90f6f0a42d15..8717d3b9667c 100644<br>
--- a/drivers/gpu/drm/i915/intel_dp.c<br>
+++ b/drivers/gpu/drm/i915/intel_dp.c<br>
@@ -1875,19 +1875,6 @@ void intel_edp_psr_disable(struct intel_dp *intel_dp)<br>
        dev_priv->psr.enabled = false;<br>
 }<br>
<br>
-void intel_edp_psr_update(struct drm_device *dev)<br>
-{<br>
-       struct drm_i915_private *dev_priv = dev->dev_private;<br>
-<br>
-       if (!HAS_PSR(dev))<br>
-               return;<br>
-<br>
-       if (!dev_priv->psr.setup_done)<br>
-               return;<br>
-<br>
-       intel_edp_psr_exit(dev, true);<br>
-}<br>
-<br>
 static void intel_edp_psr_work(struct work_struct *work)<br>
 {<br>
        struct drm_i915_private *dev_priv =<br>
diff --git a/drivers/gpu/drm/i915/intel_drv.h b/drivers/gpu/drm/i915/intel_drv.h<br>
index 0081f79efad4..87e83c315c4b 100644<br>
--- a/drivers/gpu/drm/i915/intel_drv.h<br>
+++ b/drivers/gpu/drm/i915/intel_drv.h<br>
@@ -828,7 +828,6 @@ void intel_edp_panel_on(struct intel_dp *intel_dp);<br>
 void intel_edp_panel_off(struct intel_dp *intel_dp);<br>
 void intel_edp_psr_enable(struct intel_dp *intel_dp);<br>
 void intel_edp_psr_disable(struct intel_dp *intel_dp);<br>
-void intel_edp_psr_update(struct drm_device *dev);<br>
 void intel_dp_set_drrs_state(struct drm_device *dev, int refresh_rate);<br>
 void intel_edp_psr_exit(struct drm_device *dev, bool schedule_back);<br>
 void intel_edp_psr_init(struct drm_device *dev);<br>
diff --git a/drivers/gpu/drm/i915/intel_sprite.c b/drivers/gpu/drm/i915/intel_sprite.c<br>
index 404335d53a89..2a211c64ec8d 100644<br>
--- a/drivers/gpu/drm/i915/intel_sprite.c<br>
+++ b/drivers/gpu/drm/i915/intel_sprite.c<br>
@@ -1051,7 +1051,7 @@ intel_update_plane(struct drm_plane *plane, struct drm_crtc *crtc,<br>
                mutex_unlock(&dev->struct_mutex);<br>
        }<br>
<br>
-       intel_edp_psr_update(dev);<br>
+       intel_edp_psr_exit(dev, true);<br>
<br>
        return 0;<br>
 }<br>
<span class="HOEnZb"><font color="#888888">--<br>
2.0.0<br>
<br>
_______________________________________________<br>
Intel-gfx mailing list<br>
<a href="mailto:Intel-gfx@lists.freedesktop.org">Intel-gfx@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/intel-gfx" target="_blank">http://lists.freedesktop.org/mailman/listinfo/intel-gfx</a><br>
</font></span></blockquote></div><br><br clear="all"><div><br></div>-- <br><div>Rodrigo Vivi</div><div>Blog: <a href="http://blog.vivi.eng.br" target="_blank">http://blog.vivi.eng.br</a></div><div> </div>
</div>