[Intel-gfx] [PATCH 22/22] drm/i915/mst: Do not hardcoded the crtcs that encoder can connect

James Ausmus james.ausmus at intel.com
Thu Aug 15 17:41:22 UTC 2019


On Thu, Jul 18, 2019 at 04:10:13PM +0300, Ville Syrjälä wrote:
> On Fri, Jul 12, 2019 at 06:09:40PM -0700, Lucas De Marchi wrote:
> > From: José Roberto de Souza <jose.souza at intel.com>
> > 
> > Tiger Lake has up to 4 pipes so the mask would need to be 0xf instead of
> > 0x7. Do not hardcode the mask so it allows the fake MST encoders to
> > connect to all pipes no matter how many the platform has.
> > 
> > Iterating over all pipes to keep consistent with intel_ddi_init().
> > 
> > Cc: Lucas De Marchi <lucas.demarchi at intel.com>
> > Cc: Ville Syrjälä <ville.syrjala at linux.intel.com>
> > Signed-off-by: José Roberto de Souza <jose.souza at intel.com>
> > Signed-off-by: Lucas De Marchi <lucas.demarchi at intel.com>
> > ---
> >  drivers/gpu/drm/i915/display/intel_dp_mst.c | 5 ++++-
> >  1 file changed, 4 insertions(+), 1 deletion(-)
> > 
> > diff --git a/drivers/gpu/drm/i915/display/intel_dp_mst.c b/drivers/gpu/drm/i915/display/intel_dp_mst.c
> > index 60652ebbdf61..1b79b6befa92 100644
> > --- a/drivers/gpu/drm/i915/display/intel_dp_mst.c
> > +++ b/drivers/gpu/drm/i915/display/intel_dp_mst.c
> > @@ -586,6 +586,8 @@ intel_dp_create_fake_mst_encoder(struct intel_digital_port *intel_dig_port, enum
> >  	struct intel_dp_mst_encoder *intel_mst;
> >  	struct intel_encoder *intel_encoder;
> >  	struct drm_device *dev = intel_dig_port->base.base.dev;
> > +	struct drm_i915_private *dev_priv = to_i915(dev);
> > +	enum pipe pipe_iter;
> >  
> >  	intel_mst = kzalloc(sizeof(*intel_mst), GFP_KERNEL);
> >  
> > @@ -602,8 +604,9 @@ intel_dp_create_fake_mst_encoder(struct intel_digital_port *intel_dig_port, enum
> >  	intel_encoder->type = INTEL_OUTPUT_DP_MST;
> >  	intel_encoder->power_domain = intel_dig_port->base.power_domain;
> >  	intel_encoder->port = intel_dig_port->base.port;
> > -	intel_encoder->crtc_mask = 0x7;
> >  	intel_encoder->cloneable = 0;
> > +	for_each_pipe(dev_priv, pipe_iter)
> > +		intel_encoder->crtc_mask |= BIT(pipe_iter);
> 
> https://patchwork.freedesktop.org/patch/316555/?series=63399&rev=1

Would it make sense to bring this patch in for now for TGL MST, until
that larger series can land?

-James

> 
> >  
> >  	intel_encoder->compute_config = intel_dp_mst_compute_config;
> >  	intel_encoder->disable = intel_mst_disable_dp;
> > -- 
> > 2.21.0
> 
> -- 
> Ville Syrjälä
> Intel
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx


More information about the Intel-gfx mailing list