public inbox for intel-gfx@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Balasubramani Vivekanandan <balasubramani.vivekanandan@intel.com>
To: Anusha Srivatsa <anusha.srivatsa@intel.com>,
	<intel-gfx@lists.freedesktop.org>
Subject: Re: [Intel-gfx] [PATCH 4/4] drm/i915/display: Move squash_ctl register programming to its own function
Date: Fri, 21 Oct 2022 12:37:56 +0530	[thread overview]
Message-ID: <Y1JFTJsfRLKA6usV@bala-ubuntu> (raw)
In-Reply-To: <20221021002024.390052-5-anusha.srivatsa@intel.com>

On 20.10.2022 17:20, Anusha Srivatsa wrote:
> No functional change. Introduce dg2_cdclk_squash_programming and
> move squash_ctl register programming bits to this.
> 
> Cc: Balasubramani Vivekanandan <balasubramani.vivekanandan@intel.com>
> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
> Signed-off-by: Anusha Srivatsa <anusha.srivatsa@intel.com>
> ---
>  drivers/gpu/drm/i915/display/intel_cdclk.c | 23 +++++++++++++---------
>  1 file changed, 14 insertions(+), 9 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/display/intel_cdclk.c b/drivers/gpu/drm/i915/display/intel_cdclk.c
> index 8701796788e3..b692186c8f02 100644
> --- a/drivers/gpu/drm/i915/display/intel_cdclk.c
> +++ b/drivers/gpu/drm/i915/display/intel_cdclk.c
> @@ -1705,6 +1705,18 @@ static void bxt_cdclk_pll(struct drm_i915_private *i915, int vco)
>  
>  }
>  
> +static void dg2_cdclk_squash_programming(struct drm_i915_private *i915,
> +					 u16 waveform)
> +{
> +	u32 squash_ctl = 0;
> +
> +	if (waveform)
> +		squash_ctl = CDCLK_SQUASH_ENABLE |
> +			     CDCLK_SQUASH_WINDOW_SIZE(0xf) | waveform;
> +
> +	intel_de_write(i915, CDCLK_SQUASH_CTL, squash_ctl);
> +}
> +
>  static void bxt_set_cdclk(struct drm_i915_private *dev_priv,
>  			  const struct intel_cdclk_config *cdclk_config,
>  			  enum pipe pipe)
> @@ -1752,15 +1764,8 @@ static void bxt_set_cdclk(struct drm_i915_private *dev_priv,
>  	else
>  		clock = cdclk;
>  
> -	if (HAS_CDCLK_SQUASH(dev_priv)) {
> -		u32 squash_ctl = 0;
> -
> -		if (waveform)
> -			squash_ctl = CDCLK_SQUASH_ENABLE |
> -				CDCLK_SQUASH_WINDOW_SIZE(0xf) | waveform;
> -
> -		intel_de_write(dev_priv, CDCLK_SQUASH_CTL, squash_ctl);
> -	}
> +	if (HAS_CDCLK_SQUASH(dev_priv))
> +		dg2_cdclk_squash_programming(dev_priv, waveform);

Is it possible to move also the function cdclk_squash_waveform() inside
dg2_cdclk_squash_programming()?

Regards,
Bala

>  
>  	val = bxt_cdclk_cd2x_div_sel(dev_priv, clock, vco) |
>  		bxt_cdclk_cd2x_pipe(dev_priv, pipe) |
> -- 
> 2.25.1
> 

  reply	other threads:[~2022-10-21  7:08 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-21  0:20 [Intel-gfx] [PATCH 0/4] Prep series - CDCLK code churn Anusha Srivatsa
2022-10-21  0:20 ` [Intel-gfx] [PATCH 1/4] drm/i915/display: Change terminology for cdclk actions Anusha Srivatsa
2022-10-21  0:20 ` [Intel-gfx] [PATCH 2/4] drm/i915/display: Introduce HAS_CDCLK_SQUASH macro Anusha Srivatsa
2022-10-21  7:11   ` Balasubramani Vivekanandan
2022-10-21  8:46     ` Jani Nikula
2022-10-21 20:28       ` Srivatsa, Anusha
2022-10-21  0:20 ` [Intel-gfx] [PATCH 3/4] drm/i915/display: Move chunks of code out of bxt_set_cdclk() Anusha Srivatsa
2022-10-21  8:32   ` Jani Nikula
2022-10-21 20:33     ` Srivatsa, Anusha
2022-10-21  0:20 ` [Intel-gfx] [PATCH 4/4] drm/i915/display: Move squash_ctl register programming to its own function Anusha Srivatsa
2022-10-21  7:07   ` Balasubramani Vivekanandan [this message]
2022-10-21 21:06     ` Srivatsa, Anusha
2022-10-21  8:41   ` Jani Nikula
2022-10-21 20:31     ` Srivatsa, Anusha
2022-10-21  1:04 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for Prep series - CDCLK code churn Patchwork
2022-10-21  1:04 ` [Intel-gfx] ✗ Fi.CI.SPARSE: " Patchwork
2022-10-21  1:23 ` [Intel-gfx] ✓ Fi.CI.BAT: success " Patchwork
2022-10-21  6:27 ` [Intel-gfx] ✗ Fi.CI.IGT: failure " Patchwork
2022-10-21  7:06 ` [Intel-gfx] [PATCH 0/4] " Balasubramani Vivekanandan
2022-10-21  8:42   ` Jani Nikula
  -- strict thread matches above, loose matches on Subject: below --
2022-10-21 21:39 Anusha Srivatsa
2022-10-21 21:39 ` [Intel-gfx] [PATCH 4/4] drm/i915/display: Move squash_ctl register programming to its own function Anusha Srivatsa
2022-10-25 17:44   ` Balasubramani Vivekanandan
2022-10-25 18:29 [Intel-gfx] [PATCH 1/4] drm/i915/display: Change terminology for cdclk actions Anusha Srivatsa
2022-10-25 18:29 ` [Intel-gfx] [PATCH 4/4] drm/i915/display: Move squash_ctl register programming to its own function Anusha Srivatsa

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=Y1JFTJsfRLKA6usV@bala-ubuntu \
    --to=balasubramani.vivekanandan@intel.com \
    --cc=anusha.srivatsa@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox