drm/i915: fix up the edp power well check
Subsystems (2)
PATCH 1/1 drm/i915: fix up the edp power well check
Now that we track the cpu transcoder we need accurately in the pipe config we can finally fix up the transcoder check. With the current code eDP on port D will be broken since we'd errornously cut the power.
For reference see
commit 2124b72e6283c4e84a55e71077fee91793f4c801
Author: Paulo Zanoni <[email protected]> Date: Fri Mar 22 14:07:23 2013 -0300
drm/i915: don't disable the power well yet
--- drivers/gpu/drm/i915/intel_display.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-)
drivers/gpu/drm/i915/intel_display.c +1 -5
@@ -5809,12 +5809,8 @@ static void haswell_modeset_global_resources(struct drm_device *dev)/* Even the eDP panel fitter is outside the always-on well. */ if (crtc->config.pch_pfit.size && crtc->base.enabled) enable = true; - } -list_for_each_entry (encoder, &dev->mode_config.encoder_list, - base.head) { -if (encoder->type !=INTEL_OUTPUT_EDP && - encoder->connectors_active) +if (crtc->config.cpu_transcoder !=TRANSCODER_EDP ) enable = true; }
Signature · 1 line
1.7.10.4
Quoted 8 lines · Daniel Vetter
Now that we track the cpu transcoder we need accurately in the pipe config we can finally fix up the transcoder check. With the current code eDP on port D will be broken since we'd errornously cut the power.
For reference see
commit
2124b72e6283c4e84a55e71077fee91793f4c801
Quoted 8 lines
Author: Paulo Zanoni <[email protected]> Date: Fri Mar 22 14:07:23 2013 -0300drm/i915: don't disable the power well yet
Cc Takashi Iwai <[email protected]>Cc Paulo Zanoni <[email protected]>Signed-off-by Daniel Vetter <[email protected]>
Adding imre since he smashed his r-b onto the regressing commit. -Daniel
Quoted 25 lines
--- drivers/gpu/drm/i915/intel_display.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-)drivers/gpu/drm/i915/intel_display.c +1
-5@@ -5809,12 +5809,8 @@ static void haswell_modeset_global_resources(struct drm_device *dev)/* Even the eDP panel fitter is outside the always-on well. */ if (crtc->config.pch_pfit.size && crtc->base.enabled) enable = true; - } -list_for_each_entry (encoder, &dev->mode_config.encoder_list, - base.head) { -if (encoder->type !=INTEL_OUTPUT_EDP && - encoder->connectors_active) +if (crtc->config.cpu_transcoder !=TRANSCODER_EDP ) enable = true; }Signature · 1 line
1.7.10.4
Signature · 3 lines
Daniel Vetter Software Engineer, Intel Corporation +41 (0) 79 365 57 48 - http://blog.ffwll.ch
Quoted 12 lines · Daniel Vetter
Quoted 11 lines · Daniel Vetter
Now that we track the cpu transcoder we need accurately in the pipe config we can finally fix up the transcoder check. With the current code eDP on port D will be broken since we'd errornously cut the power.
For reference see
commit
2124b72e6283c4e84a55e71077fee91793f4c801Author: Paulo Zanoni <[email protected]> Date: Fri Mar 22 14:07:23 2013 -0300
Quoted 7 lines
Quoted 5 lines
drm/i915: don't disable the power well yet
Cc Takashi Iwai <[email protected]>Cc Paulo Zanoni <[email protected]>Signed-off-by Daniel Vetter <[email protected]>Adding imre since he smashed his r-b onto the regressing commit.
Meh, replied to the wrong patch, never mind.
-Daniel
Signature · 3 lines
Daniel Vetter Software Engineer, Intel Corporation +41 (0) 79 365 57 48 - http://blog.ffwll.ch
At Wed, 29 May 2013 19:56:11 +0200,
Quoted 8 lines · Daniel Vetter
Now that we track the cpu transcoder we need accurately in the pipe config we can finally fix up the transcoder check. With the current code eDP on port D will be broken since we'd errornously cut the power.
For reference see
Quoted 7 lines
commit
2124b72e6283c4e84a55e71077fee91793f4c801Author: Paulo Zanoni <[email protected]> Date: Fri Mar 22 14:07:23 2013 -0300drm/i915: don't disable the power well yet
Cc Takashi Iwai <[email protected]>
Sorry, I have no hardware that showed the problem around here for testing now, unfortunately.
Takashi
Quoted 27 lines
Cc Paulo Zanoni <[email protected]>Signed-off-by Daniel Vetter <[email protected]>--- drivers/gpu/drm/i915/intel_display.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-)drivers/gpu/drm/i915/intel_display.c +1
-5@@ -5809,12 +5809,8 @@ static void haswell_modeset_global_resources(struct drm_device *dev)/* Even the eDP panel fitter is outside the always-on well. */ if (crtc->config.pch_pfit.size && crtc->base.enabled) enable = true; - } -list_for_each_entry (encoder, &dev->mode_config.encoder_list, - base.head) { -if (encoder->type !=INTEL_OUTPUT_EDP && - encoder->connectors_active) +if (crtc->config.cpu_transcoder !=TRANSCODER_EDP ) enable = true; }Signature · 1 line
1.7.10.4
Quoted 14 lines · Takashi Iwai
At Wed, 29 May 2013 19:56:11 +0200,
Quoted 12 lines · Daniel Vetter
Now that we track the cpu transcoder we need accurately in the pipe config we can finally fix up the transcoder check. With the current code eDP on port D will be broken since we'd errornously cut the power.
For reference see
commit
2124b72e6283c4e84a55e71077fee91793f4c801Author: Paulo Zanoni <[email protected]> Date: Fri Mar 22 14:07:23 2013 -0300
Quoted 6 lines
Quoted 3 lines
drm/i915: don't disable the power well yet
Cc Takashi Iwai <[email protected]>Sorry, I have no hardware that showed the problem around here for testing now, unfortunately.
Np, that was just an fyi cc ;-)
-Daniel
Signature · 3 lines
Daniel Vetter Software Engineer, Intel Corporation +41 (0) 79 365 57 48 - http://blog.ffwll.ch
2013/5/29 Daniel Vetter <[email protected]>:
Quoted 25 lines
Now that we track the cpu transcoder we need accurately in the pipe config we can finally fix up the transcoder check. With the current code eDP on port D will be broken since we'd errornously cut the power.
For reference see
commit
2124b72e6283c4e84a55e71077fee91793f4c801Author: Paulo Zanoni <[email protected]> Date: Fri Mar 22 14:07:23 2013 -0300drm/i915: don't disable the power well yet
Cc Takashi Iwai <[email protected]>Cc Paulo Zanoni <[email protected]>Signed-off-by Daniel Vetter <[email protected]>--- drivers/gpu/drm/i915/intel_display.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-)drivers/gpu/drm/i915/intel_display.c +0
-0
drivers/gpu/drm/i915/intel_display.c static void haswell_modeset_global_resources(struct drm_device *dev) · line 5813
Quoted 10 lines
drivers/gpu/drm/i915/intel_display.c +1
-5@@ -5809,12 +5809,8 @@ static void haswell_modeset_global_resources(struct drm_device *dev)/* Even the eDP panel fitter is outside the always-on well. */ if (crtc->config.pch_pfit.size && crtc->base.enabled) enable = true; - } -list_for_each_entry (encoder, &dev->mode_config.encoder_list, - base.head) { -if (encoder->type !=INTEL_OUTPUT_EDP && - encoder->connectors_active) +if (crtc->config.cpu_transcoder !=TRANSCODER_EDP )
Don't you also need to check for crtc->base.enabled here? If you do this, please notice that all 3 checks inside the loop will have a check for crtc->base.enabled inside, so you might want to move that to a "if (!crtc->base.enabled) continue;" or something similar.
Please also update/remove the comment that has an "XXX" tag.
Quoted 10 lines
drivers/gpu/drm/i915/intel_display.c +0
-1enable = true; } --1.7.10.4
_______________________________________________
Intel-gfx mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Signature · 1 line
Paulo Zanoni
PATCH 1/1 drm/i915: fix up the edp power well check
Now that we track the cpu transcoder we need accurately in the pipe config we can finally fix up the transcoder check. With the current code eDP on port D will be broken since we'd errornously cut the power.
For reference see
commit 2124b72e6283c4e84a55e71077fee91793f4c801
Author: Paulo Zanoni <[email protected]> Date: Fri Mar 22 14:07:23 2013 -0300
drm/i915: don't disable the power well yet
v2:
- Kill the now outdated comment (Paulo)
- Add the missing crtc->base.enabled check and consolidate it (Paulo)
- Smash all checks together, looks neater that way.
--- drivers/gpu/drm/i915/intel_display.c | 17 ++++------------- 1 file changed, 4 insertions(+), 13 deletions(-)
drivers/gpu/drm/i915/intel_display.c +4 -13
@@ -5801,20 +5801,11 @@ static void haswell_modeset_global_resources(struct drm_device *dev)struct intel_encoder *encoder;list_for_each_entry (crtc, &dev->mode_config.crtc_list, base.head) { -if (crtc->pipe !=PIPE_A && crtc->base.enabled) - enable = true; -/* XXX: Should check for edp transcoder here, but thanks to init -* sequence that's not yet available. Just in case desktop eDP -* on PORT D is possible on haswell, too. */ -/* Even the eDP panel fitter is outside the always-on well. */ -if (crtc->config.pch_pfit.size && crtc->base.enabled) - enable = true; - } +if (!crtc->base.enabled) +continue ; -list_for_each_entry (encoder, &dev->mode_config.encoder_list, - base.head) { -if (encoder->type !=INTEL_OUTPUT_EDP && - encoder->connectors_active) +if (crtc->pipe !=PIPE_A || crtc->config.pch_pfit.size || + crtc->config.cpu_transcoder !=TRANSCODER_EDP ) enable = true; }
Signature · 1 line
1.7.10.4
PATCH 1/1 drm/i915: fix up the edp power well check
In reply to Paulo ZanoniNow that we track the cpu transcoder we need accurately in the pipe config we can finally fix up the transcoder check. With the current code eDP on port D will be broken since we'd errornously cut the power.
For reference see
commit 2124b72e6283c4e84a55e71077fee91793f4c801
Author: Paulo Zanoni <[email protected]> Date: Fri Mar 22 14:07:23 2013 -0300
drm/i915: don't disable the power well yet
v2:
- Kill the now outdated comment (Paulo)
- Add the missing crtc->base.enabled check and consolidate it (Paulo)
- Smash all checks together, looks neater that way.
v3: Kill the unused encoder variable.
--- drivers/gpu/drm/i915/intel_display.c | 18 ++++-------------- 1 file changed, 4 insertions(+), 14 deletions(-)
drivers/gpu/drm/i915/intel_display.c +4 -14
@@ -5798,23 +5798,13 @@ static void haswell_modeset_global_resources(struct drm_device *dev) {bool enable = false;struct intel_crtc *crtc; -struct intel_encoder *encoder;list_for_each_entry (crtc, &dev->mode_config.crtc_list, base.head) { -if (crtc->pipe !=PIPE_A && crtc->base.enabled) - enable = true; -/* XXX: Should check for edp transcoder here, but thanks to init -* sequence that's not yet available. Just in case desktop eDP -* on PORT D is possible on haswell, too. */ -/* Even the eDP panel fitter is outside the always-on well. */ -if (crtc->config.pch_pfit.size && crtc->base.enabled) - enable = true; - } +if (!crtc->base.enabled) +continue ; -list_for_each_entry (encoder, &dev->mode_config.encoder_list, - base.head) { -if (encoder->type !=INTEL_OUTPUT_EDP && - encoder->connectors_active) +if (crtc->pipe !=PIPE_A || crtc->config.pch_pfit.size || + crtc->config.cpu_transcoder !=TRANSCODER_EDP ) enable = true; }
Signature · 1 line
1.7.10.4
2013/5/31 Daniel Vetter <[email protected]>:
Quoted 18 lines
Now that we track the cpu transcoder we need accurately in the pipe config we can finally fix up the transcoder check. With the current code eDP on port D will be broken since we'd errornously cut the power.
For reference see
commit
2124b72e6283c4e84a55e71077fee91793f4c801Author: Paulo Zanoni <[email protected]> Date: Fri Mar 22 14:07:23 2013 -0300drm/i915: don't disable the power well yet
v2:
- Kill the now outdated comment (Paulo)
- Add the missingcrtc->base.enabledcheck and consolidate it (Paulo)
- Smash all checks together, looks neater that way.
Quoted 5 lines
v3: Kill the unused encoder variable.
Cc Takashi Iwai <[email protected]>Cc Paulo Zanoni <[email protected]>Signed-off-by Daniel Vetter <[email protected]>
Quoted 43 lines
--- drivers/gpu/drm/i915/intel_display.c | 18 ++++-------------- 1 file changed, 4 insertions(+), 14 deletions(-)drivers/gpu/drm/i915/intel_display.c +4
-15@@ -5798,23 +5798,13 @@ static void haswell_modeset_global_resources(struct drm_device *dev) {bool enable = false;struct intel_crtc *crtc; -struct intel_encoder *encoder;list_for_each_entry (crtc, &dev->mode_config.crtc_list, base.head) { -if (crtc->pipe !=PIPE_A && crtc->base.enabled) - enable = true; -/* XXX: Should check for edp transcoder here, but thanks to init -* sequence that's not yet available. Just in case desktop eDP -* on PORT D is possible on haswell, too. */ -/* Even the eDP panel fitter is outside the always-on well. */ -if (crtc->config.pch_pfit.size && crtc->base.enabled) - enable = true; - } +if (!crtc->base.enabled) +continue ; -list_for_each_entry (encoder, &dev->mode_config.encoder_list, - base.head) { -if (encoder->type !=INTEL_OUTPUT_EDP && - encoder->connectors_active) +if (crtc->pipe !=PIPE_A || crtc->config.pch_pfit.size || + crtc->config.cpu_transcoder !=TRANSCODER_EDP ) enable = true; } --1.7.10.4
_______________________________________________
Intel-gfx mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Signature · 1 line
Paulo Zanoni
Daniel Vetter
AppliedQuoted 19 lines · Paulo Zanoni
2013/5/31 Daniel Vetter <[email protected]>:
Quoted 18 lines
Now that we track the cpu transcoder we need accurately in the pipe config we can finally fix up the transcoder check. With the current code eDP on port D will be broken since we'd errornously cut the power.
For reference see
commit
2124b72e6283c4e84a55e71077fee91793f4c801Author: Paulo Zanoni <[email protected]> Date: Fri Mar 22 14:07:23 2013 -0300drm/i915: don't disable the power well yet
v2:
- Kill the now outdated comment (Paulo)
- Add the missingcrtc->base.enabledcheck and consolidate it (Paulo)
- Smash all checks together, looks neater that way.
Quoted 7 lines
Quoted 5 lines
v3: Kill the unused encoder variable.
Cc Takashi Iwai <[email protected]>Cc Paulo Zanoni <[email protected]>Signed-off-by Daniel Vetter <[email protected]>Reviewed-by Paulo Zanoni <[email protected]>
Queued for -next, thanks for the review.
-Daniel
Signature · 3 lines
Daniel Vetter Software Engineer, Intel Corporation +41 (0) 79 365 57 48 - http://blog.ffwll.ch