All of lore.kernel.org
 help / color / mirror / Atom feed
From: Clint Taylor <Clinton.A.Taylor@intel.com>
To: intel-gfx@lists.freedesktop.org
Subject: Re: [Intel-gfx] [PATCH 4/5] drm/i915/display/adl_p: Allow DC3CO in pipe and port B
Date: Mon, 24 May 2021 15:28:14 -0700	[thread overview]
Message-ID: <7f1a2814-2cae-49a9-58a4-b9f826590c11@intel.com> (raw)
In-Reply-To: <20210524214805.259692-4-jose.souza@intel.com>


On 5/24/21 2:48 PM, José Roberto de Souza wrote:
> DC3CO is allowed in all the combinations between pipe and port A and B
> on alderlake-P.
>
> BSpec: 49196
> Cc: Anshuman Gupta <anshuman.gupta@intel.com>
> Cc: Gwan-gyeong Mun <gwan-gyeong.mun@intel.com>
> Cc: Matt Atwood <matthew.s.atwood@intel.com>
> Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
> ---
>   drivers/gpu/drm/i915/display/intel_psr.c | 20 ++++++++++++++++----
>   1 file changed, 16 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/display/intel_psr.c b/drivers/gpu/drm/i915/display/intel_psr.c
> index 216626444c76..c57210862206 100644
> --- a/drivers/gpu/drm/i915/display/intel_psr.c
> +++ b/drivers/gpu/drm/i915/display/intel_psr.c
> @@ -646,12 +646,26 @@ static void tgl_disallow_dc3co_on_psr2_exit(struct intel_dp *intel_dp)
>   	tgl_psr2_disable_dc3co(intel_dp);
>   }
>   
> +static bool
> +dc3co_is_pipe_port_compatible(struct intel_dp *intel_dp,
> +			      struct intel_crtc_state *crtc_state)
> +{
> +	struct intel_digital_port *dig_port = dp_to_dig_port(intel_dp);
> +	enum pipe pipe = to_intel_crtc(crtc_state->uapi.crtc)->pipe;
> +	struct drm_i915_private *dev_priv = dp_to_i915(intel_dp);
> +	enum port port = dig_port->base.port;
> +
> +	if (IS_ALDERLAKE_P(dev_priv))
> +		return pipe <= PIPE_B && port <= PORT_B;
> +	else
> +		return pipe == PIPE_A && port == PORT_A;
> +}
> +
>   static void
>   tgl_dc3co_exitline_compute_config(struct intel_dp *intel_dp,
>   				  struct intel_crtc_state *crtc_state)
>   {
>   	const u32 crtc_vdisplay = crtc_state->uapi.adjusted_mode.crtc_vdisplay;
> -	struct intel_digital_port *dig_port = dp_to_dig_port(intel_dp);
>   	struct drm_i915_private *dev_priv = dp_to_i915(intel_dp);
>   	u32 exit_scanlines;
>   
> @@ -672,9 +686,7 @@ tgl_dc3co_exitline_compute_config(struct intel_dp *intel_dp,
>   	if (!(dev_priv->dmc.allowed_dc_mask & DC_STATE_EN_DC3CO))
>   		return;
>   
> -	/* B.Specs:49196 DC3CO only works with pipeA and DDIA.*/
> -	if (to_intel_crtc(crtc_state->uapi.crtc)->pipe != PIPE_A ||
> -	    dig_port->base.port != PORT_A)
> +	if (!dc3co_is_pipe_port_compatible(intel_dp, crtc_state))
>   		return;
>   
>   	/*

Reviewed-by: Clint Taylor <Clinton.A.Taylor@intel.com>

-Clint


_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

  reply	other threads:[~2021-05-24 22:28 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-24 21:48 [Intel-gfx] [PATCH 1/5] drm/i915/display/adl_p: Drop earlier return in tc_has_modular_fia() José Roberto de Souza
2021-05-24 21:48 ` [Intel-gfx] [PATCH 2/5] drm/i915/adl_p: Handle TC cold José Roberto de Souza
2021-05-24 22:24   ` Clint Taylor
2021-05-24 21:48 ` [Intel-gfx] [PATCH 3/5] drm/i915: WA for zero memory channel José Roberto de Souza
2021-05-24 22:25   ` Clint Taylor
2021-05-24 21:48 ` [Intel-gfx] [PATCH 4/5] drm/i915/display/adl_p: Allow DC3CO in pipe and port B José Roberto de Souza
2021-05-24 22:28   ` Clint Taylor [this message]
2021-05-24 21:48 ` [Intel-gfx] [PATCH 5/5] drm/i915/display/adl_p: Disable PSR2 José Roberto de Souza
2021-05-24 22:28   ` Clint Taylor
2021-05-25 10:55   ` Jani Nikula
2021-05-25 17:31     ` Souza, Jose
2021-05-24 22:23 ` [Intel-gfx] [PATCH 1/5] drm/i915/display/adl_p: Drop earlier return in tc_has_modular_fia() Clint Taylor
2021-05-24 23:01 ` [Intel-gfx] ✗ Fi.CI.SPARSE: warning for series starting with [1/5] " Patchwork
2021-05-24 23:25 ` [Intel-gfx] ✓ Fi.CI.BAT: success " Patchwork
2021-05-25  6:30 ` [Intel-gfx] ✓ Fi.CI.IGT: " Patchwork
2021-05-25 17:31   ` Souza, Jose

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=7f1a2814-2cae-49a9-58a4-b9f826590c11@intel.com \
    --to=clinton.a.taylor@intel.com \
    --cc=intel-gfx@lists.freedesktop.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.