[01/12] drm/i915: Don't mark eDP encoders as MST capable
diff mbox

Message ID 1465382507-23085-2-git-send-email-ville.syrjala@linux.intel.com
State New
Headers show

Commit Message

Ville Syrjälä June 8, 2016, 10:41 a.m. UTC
From: Ville Syrjälä <ville.syrjala@linux.intel.com>

If we've determined that the encoder is eDP, we shouldn't try to use MST
on it. Or at least the code doesn't seem to expect that since there are
some type==DP checks in the MST code.

Cc: Dave Airlie <airlied@redhat.com>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
---
 drivers/gpu/drm/i915/intel_dp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Sharma, Shashank June 16, 2016, 12:27 p.m. UTC | #1
Reviewed-by: Shashank Sharma

Regards
Shashank
On 6/8/2016 4:11 PM, ville.syrjala@linux.intel.com wrote:
> From: Ville Syrjälä <ville.syrjala@linux.intel.com>
>
> If we've determined that the encoder is eDP, we shouldn't try to use MST
> on it. Or at least the code doesn't seem to expect that since there are
> some type==DP checks in the MST code.
>
> Cc: Dave Airlie <airlied@redhat.com>
> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
> ---
>   drivers/gpu/drm/i915/intel_dp.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c
> index f97cd5305e4c..0ab4f319f88f 100644
> --- a/drivers/gpu/drm/i915/intel_dp.c
> +++ b/drivers/gpu/drm/i915/intel_dp.c
> @@ -5528,7 +5528,7 @@ intel_dp_init_connector(struct intel_digital_port *intel_dig_port,
>   		goto fail;
>
>   	/* init MST on ports that can support it */
> -	if (HAS_DP_MST(dev) &&
> +	if (HAS_DP_MST(dev) && !is_edp(intel_dp) &&
>   	    (port == PORT_B || port == PORT_C || port == PORT_D))
>   		intel_dp_mst_encoder_init(intel_dig_port,
>   					  intel_connector->base.base.id);
>
Dave Airlie June 16, 2016, 8:35 p.m. UTC | #2
On 8 June 2016 at 20:41,  <ville.syrjala@linux.intel.com> wrote:
> From: Ville Syrjälä <ville.syrjala@linux.intel.com>
>
> If we've determined that the encoder is eDP, we shouldn't try to use MST
> on it. Or at least the code doesn't seem to expect that since there are
> some type==DP checks in the MST code.
>
> Cc: Dave Airlie <airlied@redhat.com>
> Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>

How sure are we that MST eDP panels won't show up in the future?

Like the code could be buggy now, but breaking it completely is different.

I've no insight into future eDP panel development.

Dave.
Ville Syrjälä June 17, 2016, 2:25 p.m. UTC | #3
On Fri, Jun 17, 2016 at 06:35:33AM +1000, Dave Airlie wrote:
> On 8 June 2016 at 20:41,  <ville.syrjala@linux.intel.com> wrote:
> > From: Ville Syrjälä <ville.syrjala@linux.intel.com>
> >
> > If we've determined that the encoder is eDP, we shouldn't try to use MST
> > on it. Or at least the code doesn't seem to expect that since there are
> > some type==DP checks in the MST code.
> >
> > Cc: Dave Airlie <airlied@redhat.com>
> > Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
> 
> How sure are we that MST eDP panels won't show up in the future?

No clue really. The only reference to MST in the eDP spec is the
explanation of the acronym.

I did spot that there's this thing called multi-SST mode, where you feed
the panel with several SST links. But that's sort of the opposite of
MST.

> 
> Like the code could be buggy now, but breaking it completely is different.

Should be easy for someone familiar with the MST code to fix if eDP+MST
ever makes an appearance; Just revert this patch, and deal with any
fallout.

> 
> I've no insight into future eDP panel development.
> 
> Dave.

Patch
diff mbox

diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c
index f97cd5305e4c..0ab4f319f88f 100644
--- a/drivers/gpu/drm/i915/intel_dp.c
+++ b/drivers/gpu/drm/i915/intel_dp.c
@@ -5528,7 +5528,7 @@  intel_dp_init_connector(struct intel_digital_port *intel_dig_port,
 		goto fail;
 
 	/* init MST on ports that can support it */
-	if (HAS_DP_MST(dev) &&
+	if (HAS_DP_MST(dev) && !is_edp(intel_dp) &&
 	    (port == PORT_B || port == PORT_C || port == PORT_D))
 		intel_dp_mst_encoder_init(intel_dig_port,
 					  intel_connector->base.base.id);