[PATCH 6/6] drm/i915/display: Add early pipe_src initialisation for gmch
Nemesa Garg
nemesa.garg at intel.com
Wed Oct 30 08:32:29 UTC 2024
Signed-off-by: Nemesa Garg <nemesa.garg at intel.com>
---
drivers/gpu/drm/i915/display/intel_display.c | 13 +++++++++++--
1 file changed, 11 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/i915/display/intel_display.c b/drivers/gpu/drm/i915/display/intel_display.c
index fa0e1911bb3c..1012f9c4c819 100644
--- a/drivers/gpu/drm/i915/display/intel_display.c
+++ b/drivers/gpu/drm/i915/display/intel_display.c
@@ -2534,6 +2534,13 @@ static int intel_crtc_compute_pipe_src(struct intel_crtc_state *crtc_state)
{
struct intel_crtc *crtc = to_intel_crtc(crtc_state->uapi.crtc);
struct drm_i915_private *i915 = to_i915(crtc->base.dev);
+ int pipe_src_w, pipe_src_h;
+
+ drm_mode_get_hv_timing(&crtc_state->hw.mode,
+ &pipe_src_w, &pipe_src_h);
+
+ drm_rect_init(&crtc_state->pipe_src, 0, 0,
+ pipe_src_w, pipe_src_h);
intel_joiner_compute_pipe_src(crtc_state);
@@ -4989,10 +4996,12 @@ intel_modeset_pipe_config(struct intel_atomic_state *state,
* computation to clearly distinguish it from the adjusted mode, which
* can be changed by the connectors in the below retry loop.
*/
- drm_mode_get_hv_timing(&crtc_state->hw.mode,
+ if (HAS_GMCH(i915)) {
+ drm_mode_get_hv_timing(&crtc_state->hw.mode,
&pipe_src_w, &pipe_src_h);
- drm_rect_init(&crtc_state->pipe_src, 0, 0,
+ drm_rect_init(&crtc_state->pipe_src, 0, 0,
pipe_src_w, pipe_src_h);
+ }
for_each_new_connector_in_state(&state->base, connector, connector_state, i) {
struct intel_encoder *encoder =
--
2.25.1
More information about the Intel-gfx-trybot
mailing list