Skip to content

Commit ddb97ea

Browse files
vsyrjalarodrigovivi
authored andcommitted
drm/i915: Remove non-existent pipes from bigjoiner pipe mask
bigjoiner_pipes() doesn't consider that: - RKL only has three pipes - some pipes may be fused off This means that intel_atomic_check_bigjoiner() won't reject all configurations that would need a non-existent pipe. Instead we just keep on rolling witout actually having reserved the slave pipe we need. It's possible that we don't outright explode anywhere due to this since eg. for_each_intel_crtc_in_pipe_mask() will only walk the crtcs we've registered even though the passed in pipe_mask asks for more of them. But clearly the thing won't do what is expected of it when the required pipes are not present. Fix the problem by consulting the device info pipe_mask already in bigjoiner_pipes(). Cc: [email protected] Signed-off-by: Ville Syrjälä <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected] Reviewed-by: Arun R Murthy <[email protected]> (cherry picked from commit f1c87a9) Signed-off-by: Rodrigo Vivi <[email protected]>
1 parent eaa96d2 commit ddb97ea

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

drivers/gpu/drm/i915/display/intel_display.c

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3733,12 +3733,16 @@ static bool ilk_get_pipe_config(struct intel_crtc *crtc,
37333733

37343734
static u8 bigjoiner_pipes(struct drm_i915_private *i915)
37353735
{
3736+
u8 pipes;
3737+
37363738
if (DISPLAY_VER(i915) >= 12)
3737-
return BIT(PIPE_A) | BIT(PIPE_B) | BIT(PIPE_C) | BIT(PIPE_D);
3739+
pipes = BIT(PIPE_A) | BIT(PIPE_B) | BIT(PIPE_C) | BIT(PIPE_D);
37383740
else if (DISPLAY_VER(i915) >= 11)
3739-
return BIT(PIPE_B) | BIT(PIPE_C);
3741+
pipes = BIT(PIPE_B) | BIT(PIPE_C);
37403742
else
3741-
return 0;
3743+
pipes = 0;
3744+
3745+
return pipes & RUNTIME_INFO(i915)->pipe_mask;
37423746
}
37433747

37443748
static bool transcoder_ddi_func_is_enabled(struct drm_i915_private *dev_priv,

0 commit comments

Comments
 (0)