public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
From: "Lisovskiy, Stanislav" <stanislav.lisovskiy@intel.com>
To: Jani Nikula <jani.nikula@intel.com>
Cc: intel-gfx@lists.freedesktop.org, stable@vger.kernel.org
Subject: Re: [Intel-gfx] [RESEND 2/3] drm/i915/dsi: fix dual-link DSI backlight and CABC ports for display 11+
Date: Wed, 17 Aug 2022 11:13:59 +0300	[thread overview]
Message-ID: <YvyjR3x5kNAEfBOk@intel.com> (raw)
In-Reply-To: <8c462718bcc7b36a83e09d0a5eef058b6bc8b1a2.1660664162.git.jani.nikula@intel.com>

On Tue, Aug 16, 2022 at 06:37:21PM +0300, Jani Nikula wrote:
> The VBT dual-link DSI backlight and CABC still use ports A and C, both
> in Bspec and code, while display 11+ DSI only supports ports A and
> B. Assume port C actually means port B for display 11+ when parsing VBT.
> 
> Bspec: 20154
> Closes: https://gitlab.freedesktop.org/drm/intel/-/issues/6476
> Cc: stable@vger.kernel.org
> Signed-off-by: Jani Nikula <jani.nikula@intel.com>

Reviewed-by: Stanislav Lisovskiy <stanislav.lisovskiy@intel.com>

> ---
>  drivers/gpu/drm/i915/display/intel_bios.c | 10 ++++++----
>  1 file changed, 6 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/display/intel_bios.c b/drivers/gpu/drm/i915/display/intel_bios.c
> index 51dde5bfd956..198a2f4920cc 100644
> --- a/drivers/gpu/drm/i915/display/intel_bios.c
> +++ b/drivers/gpu/drm/i915/display/intel_bios.c
> @@ -1596,6 +1596,8 @@ static void parse_dsi_backlight_ports(struct drm_i915_private *i915,
>  				      struct intel_panel *panel,
>  				      enum port port)
>  {
> +	enum port port_bc = DISPLAY_VER(i915) >= 11 ? PORT_B : PORT_C;
> +
>  	if (!panel->vbt.dsi.config->dual_link || i915->vbt.version < 197) {
>  		panel->vbt.dsi.bl_ports = BIT(port);
>  		if (panel->vbt.dsi.config->cabc_supported)
> @@ -1609,11 +1611,11 @@ static void parse_dsi_backlight_ports(struct drm_i915_private *i915,
>  		panel->vbt.dsi.bl_ports = BIT(PORT_A);
>  		break;
>  	case DL_DCS_PORT_C:
> -		panel->vbt.dsi.bl_ports = BIT(PORT_C);
> +		panel->vbt.dsi.bl_ports = BIT(port_bc);
>  		break;
>  	default:
>  	case DL_DCS_PORT_A_AND_C:
> -		panel->vbt.dsi.bl_ports = BIT(PORT_A) | BIT(PORT_C);
> +		panel->vbt.dsi.bl_ports = BIT(PORT_A) | BIT(port_bc);
>  		break;
>  	}
>  
> @@ -1625,12 +1627,12 @@ static void parse_dsi_backlight_ports(struct drm_i915_private *i915,
>  		panel->vbt.dsi.cabc_ports = BIT(PORT_A);
>  		break;
>  	case DL_DCS_PORT_C:
> -		panel->vbt.dsi.cabc_ports = BIT(PORT_C);
> +		panel->vbt.dsi.cabc_ports = BIT(port_bc);
>  		break;
>  	default:
>  	case DL_DCS_PORT_A_AND_C:
>  		panel->vbt.dsi.cabc_ports =
> -					BIT(PORT_A) | BIT(PORT_C);
> +					BIT(PORT_A) | BIT(port_bc);
>  		break;
>  	}
>  }
> -- 
> 2.34.1
> 

  reply	other threads:[~2022-08-17  8:13 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-16 15:37 [Intel-gfx] [RESEND 0/3] drm/i915/dsi: fix DSI DCS backlight port handling Jani Nikula
2022-08-16 15:37 ` [Intel-gfx] [RESEND 1/3] drm/i915/dsi: filter invalid backlight and CABC ports Jani Nikula
2022-08-17  8:13   ` Lisovskiy, Stanislav
2022-08-17  8:29     ` Jani Nikula
2022-08-19  9:52       ` Jani Nikula
2022-08-16 15:37 ` [Intel-gfx] [RESEND 2/3] drm/i915/dsi: fix dual-link DSI backlight and CABC ports for display 11+ Jani Nikula
2022-08-17  8:13   ` Lisovskiy, Stanislav [this message]
2022-08-16 15:37 ` [Intel-gfx] [RESEND 3/3] drm/i915/dsi: use VBT backlight and CABC port definitions directly Jani Nikula
2022-08-17  8:14   ` Lisovskiy, Stanislav
2022-08-16 16:56 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for drm/i915/dsi: fix DSI DCS backlight port handling (rev2) Patchwork
2022-08-16 17:15 ` [Intel-gfx] ✓ Fi.CI.BAT: success " Patchwork
2022-08-16 21:25 ` [Intel-gfx] ✗ Fi.CI.IGT: failure " Patchwork

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=YvyjR3x5kNAEfBOk@intel.com \
    --to=stanislav.lisovskiy@intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=jani.nikula@intel.com \
    --cc=stable@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox