[Intel-gfx] [PATCH] drm/i915: Allow DSI dual link to be configured on any pipe

Ville Syrjälä ville.syrjala at linux.intel.com
Thu Sep 10 05:48:04 PDT 2015


On Mon, Aug 03, 2015 at 03:45:32PM +0530, Gaurav K Singh wrote:
> Just like single link MIPI panels, similarly for dual link panels, pipe to be
> configured is based on the DVO port from VBT Block 2. In hardware,
> Port A is mapped with Pipe A and Port C is mapped with Pipe B.
> 
> This issue got introduced in -
> 
> commit 7e9804fdcffc650515c60f524b8b2076ee59e710
> Author: Jani Nikula <jani.nikula at intel.com>
> Date:   Fri Jan 16 14:27:23 2015 +0200
> 
>     drm/i915/dsi: add drm mipi dsi host support
> 
> Signed-off-by: Gaurav K Singh <gaurav.k.singh at intel.com>
> ---
>  drivers/gpu/drm/i915/intel_dsi.c |    9 ++++-----
>  1 file changed, 4 insertions(+), 5 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/intel_dsi.c b/drivers/gpu/drm/i915/intel_dsi.c
> index 18dd7d7..8aa9c7cc 100644
> --- a/drivers/gpu/drm/i915/intel_dsi.c
> +++ b/drivers/gpu/drm/i915/intel_dsi.c
> @@ -1048,11 +1048,7 @@ void intel_dsi_init(struct drm_device *dev)
>  	intel_connector->unregister = intel_connector_unregister;
>  
>  	/* Pipe A maps to MIPI DSI port A, pipe B maps to MIPI DSI port C */
> -	if (dev_priv->vbt.dsi.config->dual_link) {
> -		/* XXX: does dual link work on either pipe? */
> -		intel_encoder->crtc_mask = (1 << PIPE_A);
> -		intel_dsi->ports = ((1 << PORT_A) | (1 << PORT_C));
> -	} else if (dev_priv->vbt.dsi.port == DVO_PORT_MIPIA) {
> +	if (dev_priv->vbt.dsi.port == DVO_PORT_MIPIA) {
>  		intel_encoder->crtc_mask = (1 << PIPE_A);
>  		intel_dsi->ports = (1 << PORT_A);
>  	} else if (dev_priv->vbt.dsi.port == DVO_PORT_MIPIC) {
> @@ -1060,6 +1056,9 @@ void intel_dsi_init(struct drm_device *dev)
>  		intel_dsi->ports = (1 << PORT_C);
>  	}
>  
> +	if (dev_priv->vbt.dsi.config->dual_link)
> +		intel_dsi->ports = ((1 << PORT_A) | (1 << PORT_C));
> +

This looks sane based on the fact that intel_dsi_port_enable() sets
up the MIPI_PORT_CTRL lane configuration bits in a different way
depending on which pipe is driving the dual link. And the spec agrees
on the meaning of those bits.

Reviewed-by: Ville Syrjälä <ville.syrjala at linux.intel.com>

>  	/* Create a DSI host (and a device) for each port. */
>  	for_each_dsi_port(port, intel_dsi->ports) {
>  		struct intel_dsi_host *host;
> -- 
> 1.7.9.5
> 
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/intel-gfx

-- 
Ville Syrjälä
Intel OTC


More information about the Intel-gfx mailing list