drm/i915: Don't forget to mark crtc as inactive after disable
Subsystems (2)
PATCH v2 1/1 drm/i915: Don't forget to mark crtc as inactive after disable
Watermark calculations depend on the intel_crtc->active flag to be set properly. Suspend/resume is broken on SKL and we also get DDB mismatches without this patch.
The regression was introduced in:
commit eddfcbcdc27fbecb33bff098967bbdd7ca75bfa6
Author: Maarten Lankhorst <[email protected]> Date: Mon Jun 15 12:33:53 2015 +0200
drm/i915: Update less state during modeset.
No need to repeatedly call update_watermarks, or update_fbc. Down to a single call to update_watermarks in .crtc_enable
Tested-by(IVB): Matt Roper <[email protected]>
v2: Don't touch disable_shared_dpll()
--- drivers/gpu/drm/i915/intel_display.c | 9 +++++++++ 1 file changed, 9 insertions(+)
drivers/gpu/drm/i915/intel_display.c +9 -0
@@ -5046,6 +5046,9 @@ static void ironlake_crtc_disable(struct drm_crtc *crtc)ironlake_fdi_pll_disable (intel_crtc); } + + intel_crtc->active = false; +intel_update_watermarks (crtc); }static void haswell_crtc_disable (struct drm_crtc *crtc)
@@ -5091,6 +5094,9 @@ static void haswell_crtc_disable(struct drm_crtc *crtc)for_each_encoder_on_crtc (dev, crtc, encoder)if (encoder->post_disable) encoder->post_disable (encoder); + + intel_crtc->active = false; +intel_update_watermarks (crtc); }static void i9xx_pfit_enable (struct intel_crtc *crtc)
@@ -6155,6 +6161,9 @@ static void i9xx_crtc_disable(struct drm_crtc *crtc)if (!IS_GEN2 (dev))intel_set_cpu_fifo_underrun_reporting (dev_priv, pipe, false); + + intel_crtc->active = false; +intel_update_watermarks (crtc); }static void intel_crtc_disable_noatomic (struct drm_crtc *crtc)
Signature · 6 lines
2.1.4 _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Task id: 6751 -------------------------------------Summary-------------------------------------
Platform Delta drm-intel-nightly Series Applied
ILK 302/302 302/302 SNB 312/316 312/316 IVB 343/343 343/343
BYT -1 287/287 286/287
HSW 380/380 380/380
-------------------------------------Detailed-------------------------------------
Platform Test drm-intel-nightly Series Applied
*BYT igt@gem_partial_pwrite_pread@reads-display PASS(1) FAIL(1)
Note: You need to pay more attention to line start with '*'
_______________________________________________
Intel-gfx mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Hi Patrik,
Please do Cc the patch author and reviewer when finding a regression, they are superb candidates for the review, especially when they are busy rewriting the display code.
Quoted 15 lines · Patrik Jakobsson
Watermark calculations depend on the
intel_crtc->activeflag to be set properly. Suspend/resume is broken on SKL and we also get DDB mismatches without this patch.The regression was introduced in:
commit
eddfcbcdc27fbecb33bff098967bbdd7ca75bfa6Author: Maarten Lankhorst <[email protected]> Date: Mon Jun 15 12:33:53 2015 +0200drm/i915: Update less state during modeset.
No need to repeatedly call
update_watermarks, orupdate_fbc. Down to a single call toupdate_watermarksin .crtc_enable
Quoted 8 lines
Signed-off-by Maarten Lankhorst <[email protected]>Reviewed-by Matt Roper <[email protected]>Tested-by(IVB): Matt Roper <[email protected]>
Signed-off-by Daniel Vetter <[email protected]>v2: Don't touch
disable_shared_dpll()Signed-off-by Patrik Jakobsson <[email protected]>
We do need to update the watermarks in disable() as well, to repartition the DDB and update the watermarks based on the new allocation.
Maarten, Matt, I've no clue where you want the crtc state update, where the atomic WM work is at, could you comment?
Thanks,
Signature · 1 line
Damien
Quoted 45 lines
--- drivers/gpu/drm/i915/intel_display.c | 9 +++++++++ 1 file changed, 9 insertions(+)drivers/gpu/drm/i915/intel_display.c +9
-0@@ -5046,6 +5046,9 @@ static void ironlake_crtc_disable(struct drm_crtc *crtc)ironlake_fdi_pll_disable (intel_crtc); } + + intel_crtc->active = false; +intel_update_watermarks (crtc); }static void haswell_crtc_disable (struct drm_crtc *crtc)@@ -5091,6 +5094,9 @@ static void haswell_crtc_disable(struct drm_crtc *crtc)for_each_encoder_on_crtc (dev, crtc, encoder)if (encoder->post_disable) encoder->post_disable (encoder); + + intel_crtc->active = false; +intel_update_watermarks (crtc); }static void i9xx_pfit_enable (struct intel_crtc *crtc)@@ -6155,6 +6161,9 @@ static void i9xx_crtc_disable(struct drm_crtc *crtc)if (!IS_GEN2 (dev))intel_set_cpu_fifo_underrun_reporting (dev_priv, pipe, false); + + intel_crtc->active = false; +intel_update_watermarks (crtc); }static void intel_crtc_disable_noatomic (struct drm_crtc *crtc)Signature · 6 lines
2.1.4 _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
_______________________________________________
Intel-gfx mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Quoted 5 lines · Damien Lespiau
Hi Patrik,
Please do Cc the patch author and reviewer when finding a regression, they are superb candidates for the review, especially when they are busy rewriting the display code.
Hmm, I figured they would be picked up from the commit msg by git-send-email but maybe that doesn't work on indented lines.
Anyways, CCing them now.
Thanks
Patrik
Quoted 26 lines · Patrik Jakobsson
Quoted 15 lines
Watermark calculations depend on the
intel_crtc->activeflag to be set properly. Suspend/resume is broken on SKL and we also get DDB mismatches without this patch.The regression was introduced in:
commit
eddfcbcdc27fbecb33bff098967bbdd7ca75bfa6Author: Maarten Lankhorst <[email protected]> Date: Mon Jun 15 12:33:53 2015 +0200drm/i915: Update less state during modeset.
No need to repeatedly call
update_watermarks, orupdate_fbc. Down to a single call toupdate_watermarksin .crtc_enableQuoted 8 lines
Signed-off-by Maarten Lankhorst <[email protected]>Reviewed-by Matt Roper <[email protected]>Tested-by(IVB): Matt Roper <[email protected]>
Signed-off-by Daniel Vetter <[email protected]>v2: Don't touch
disable_shared_dpll()Signed-off-by Patrik Jakobsson <[email protected]>
Quoted 56 lines
We do need to update the watermarks in
disable()as well, to repartition the DDB and update the watermarks based on the new allocation.Maarten, Matt, I've no clue where you want the crtc state update, where the atomic WM work is at, could you comment?
Thanks,
Signature · 1 line
DamienQuoted 45 lines
--- drivers/gpu/drm/i915/intel_display.c | 9 +++++++++ 1 file changed, 9 insertions(+)drivers/gpu/drm/i915/intel_display.c +9
-0@@ -5046,6 +5046,9 @@ static void ironlake_crtc_disable(struct drm_crtc *crtc)ironlake_fdi_pll_disable (intel_crtc); } + + intel_crtc->active = false; +intel_update_watermarks (crtc); }static void haswell_crtc_disable (struct drm_crtc *crtc)@@ -5091,6 +5094,9 @@ static void haswell_crtc_disable(struct drm_crtc *crtc)for_each_encoder_on_crtc (dev, crtc, encoder)if (encoder->post_disable) encoder->post_disable (encoder); + + intel_crtc->active = false; +intel_update_watermarks (crtc); }static void i9xx_pfit_enable (struct intel_crtc *crtc)@@ -6155,6 +6161,9 @@ static void i9xx_crtc_disable(struct drm_crtc *crtc)if (!IS_GEN2 (dev))intel_set_cpu_fifo_underrun_reporting (dev_priv, pipe, false); + + intel_crtc->active = false; +intel_update_watermarks (crtc); }static void intel_crtc_disable_noatomic (struct drm_crtc *crtc)Signature · 6 lines
2.1.4 _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
_______________________________________________
Intel-gfx mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Maarten Lankhorst
Reviewed-byOp 10-07-15 om 13:22 schreef Damien Lespiau:
Quoted 27 lines
Hi Patrik,
Please do Cc the patch author and reviewer when finding a regression, they are superb candidates for the review, especially when they are busy rewriting the display code.
Quoted 20 lines · Patrik Jakobsson
Watermark calculations depend on the
intel_crtc->activeflag to be set properly. Suspend/resume is broken on SKL and we also get DDB mismatches without this patch.The regression was introduced in:
commit
eddfcbcdc27fbecb33bff098967bbdd7ca75bfa6Author: Maarten Lankhorst <[email protected]> Date: Mon Jun 15 12:33:53 2015 +0200drm/i915: Update less state during modeset.
No need to repeatedly call
update_watermarks, orupdate_fbc. Down to a single call toupdate_watermarksin .crtc_enableSigned-off-by Maarten Lankhorst <[email protected]>Reviewed-by Matt Roper <[email protected]>Tested-by(IVB): Matt Roper <[email protected]>
Signed-off-by Daniel Vetter <[email protected]>
Quoted 9 lines
Quoted 3 lines
v2: Don't touch
disable_shared_dpll()Signed-off-by Patrik Jakobsson <[email protected]>We do need to update the watermarks in
disable()as well, to repartition the DDB and update the watermarks based on the new allocation.Maarten, Matt, I've no clue where you want the crtc state update, where the atomic WM work is at, could you comment?
I'd rather have we had a better way of updating watermarks, but keeping it in the .crtc_disable hook looks good to me right now. Some proper atomic solution will eventually have to be done. :)
_______________________________________________
Intel-gfx mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Daniel Vetter
AppliedQuoted 6 lines · Maarten Lankhorst
Op 10-07-15 om 13:22 schreef Damien Lespiau:
Quoted 5 lines
Hi Patrik,
Please do Cc the patch author and reviewer when finding a regression, they are superb candidates for the review, especially when they are busy rewriting the display code.
Yeah you need to list everyone you want to Cc: explicitly.
Quoted 27 lines
Quoted 27 lines · Patrik Jakobsson
Quoted 15 lines
Watermark calculations depend on the
intel_crtc->activeflag to be set properly. Suspend/resume is broken on SKL and we also get DDB mismatches without this patch.The regression was introduced in:
commit
eddfcbcdc27fbecb33bff098967bbdd7ca75bfa6Author: Maarten Lankhorst <[email protected]> Date: Mon Jun 15 12:33:53 2015 +0200drm/i915: Update less state during modeset.
No need to repeatedly call
update_watermarks, orupdate_fbc. Down to a single call toupdate_watermarksin .crtc_enableQuoted 8 lines
Signed-off-by Maarten Lankhorst <[email protected]>Reviewed-by Matt Roper <[email protected]>Tested-by(IVB): Matt Roper <[email protected]>
Signed-off-by Daniel Vetter <[email protected]>v2: Don't touch
disable_shared_dpll()Signed-off-by Patrik Jakobsson <[email protected]>We do need to update the watermarks in
disable()as well, to repartition the DDB and update the watermarks based on the new allocation.
Quoted 8 lines
Quoted 3 lines
Maarten, Matt, I've no clue where you want the crtc state update, where the atomic WM work is at, could you comment?
I'd rather have we had a better way of updating watermarks, but keeping it in the .crtc_disable hook looks good to me right now. Some proper atomic solution will eventually have to be done. :)
Reviewed-by Maarten Lankhorst <[email protected]>
Queued for -next, thanks for the patch.
-Daniel
Signature · 7 lines
Daniel Vetter Software Engineer, Intel Corporation http://blog.ffwll.ch _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Quoted 9 lines · Daniel Vetter
Quoted 6 lines · Maarten Lankhorst
Op 10-07-15 om 13:22 schreef Damien Lespiau:
Quoted 5 lines
Hi Patrik,
Please do Cc the patch author and reviewer when finding a regression, they are superb candidates for the review, especially when they are busy rewriting the display code.
Yeah you need to list everyone you want to Cc: explicitly.
Also need the Bugzilla reference when fixing a bug. In this case:
https://bugs.freedesktop.org/show_bug.cgi?id=91203
Signature · 5 lines
Damien _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Quoted 9 lines · Damien Lespiau
Quoted 8 lines · Daniel Vetter
Quoted 6 lines · Maarten Lankhorst
Op 10-07-15 om 13:22 schreef Damien Lespiau:
Quoted 5 lines
Hi Patrik,
Please do Cc the patch author and reviewer when finding a regression, they are superb candidates for the review, especially when they are busy rewriting the display code.
Quoted 5 lines
Quoted 1 line
Yeah you need to list everyone you want to Cc: explicitly.
Also need the Bugzilla reference when fixing a bug. In this case:
Added, thanks for supplying the link.
-Daniel
Signature · 7 lines
Daniel Vetter Software Engineer, Intel Corporation http://blog.ffwll.ch _______________________________________________ Intel-gfx mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/intel-gfx