intel-gfx.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
From: Manasi Navare <manasi.d.navare@intel.com>
To: Jani Nikula <jani.nikula@intel.com>
Cc: intel-gfx@lists.freedesktop.org, dhinakaran.pandiyan@intel.com
Subject: Re: [PATCH v2 12/13] drm/i915/dp: localize link rate index variable more
Date: Tue, 7 Feb 2017 12:17:35 -0800	[thread overview]
Message-ID: <20170207201734.GB26663@intel.com> (raw)
In-Reply-To: <c2d303879bed24b96369a5f572d70d02472b4315.1486131408.git.jani.nikula@intel.com>

This has been tested to correctly execute the compliance request.

Reviewed-by: Manasi Navare <manasi.d.navare@intel.com>

Manasi

On Fri, Feb 03, 2017 at 04:19:35PM +0200, Jani Nikula wrote:
> Localize link_rate_index to the if block, and rename to just index to
> reduce indent.
> 
> Cc: Manasi Navare <manasi.d.navare@intel.com>
> Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
> ---
>  drivers/gpu/drm/i915/intel_dp.c | 13 +++++++------
>  1 file changed, 7 insertions(+), 6 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c
> index 58ec70f316c5..90ae95f2ecb2 100644
> --- a/drivers/gpu/drm/i915/intel_dp.c
> +++ b/drivers/gpu/drm/i915/intel_dp.c
> @@ -1640,7 +1640,6 @@ intel_dp_compute_config(struct intel_encoder *encoder,
>  	/* Conveniently, the link BW constants become indices with a shift...*/
>  	int min_clock = 0;
>  	int max_clock;
> -	int link_rate_index;
>  	int bpp, mode_rate;
>  	int link_avail, link_clock;
>  	int common_len;
> @@ -1684,11 +1683,13 @@ intel_dp_compute_config(struct intel_encoder *encoder,
>  
>  	/* Use values requested by Compliance Test Request */
>  	if (intel_dp->compliance.test_type == DP_TEST_LINK_TRAINING) {
> -		link_rate_index = intel_dp_rate_index(intel_dp->common_rates,
> -						      intel_dp->num_common_rates,
> -						      intel_dp->compliance.test_link_rate);
> -		if (link_rate_index >= 0)
> -			min_clock = max_clock = link_rate_index;
> +		int index;
> +
> +		index = intel_dp_rate_index(intel_dp->common_rates,
> +					    intel_dp->num_common_rates,
> +					    intel_dp->compliance.test_link_rate);
> +		if (index >= 0)
> +			min_clock = max_clock = index;
>  		min_lane_count = max_lane_count = intel_dp->compliance.test_lane_count;
>  	}
>  	DRM_DEBUG_KMS("DP link computation with max lane count %i "
> -- 
> 2.1.4
> 
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

  reply	other threads:[~2017-02-07 20:18 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-02-03 14:19 [PATCH v2 00/13] drm/i915/dp: link rate and lane count refactoring Jani Nikula
2017-02-03 14:19 ` [PATCH v2 01/13] drm/i915/dp: use known correct array size in rate_to_index Jani Nikula
2017-02-03 14:19 ` [PATCH v2 02/13] drm/i915/dp: return errors from rate_to_index() Jani Nikula
2017-02-03 14:19 ` [PATCH v2 03/13] drm/i915/dp: rename rate_to_index() to intel_dp_rate_index() and reuse Jani Nikula
2017-02-03 14:19 ` [PATCH v2 04/13] drm/i915/dp: cache source rates at init Jani Nikula
2017-02-03 14:19 ` [PATCH v2 05/13] drm/i915/dp: generate and cache sink rate array for all DP, not just eDP 1.4 Jani Nikula
2017-02-03 17:16   ` Ville Syrjälä
2017-02-04  9:10     ` Jani Nikula
2017-02-03 14:19 ` [PATCH v2 06/13] drm/i915/dp: use the sink rates array for max sink rates Jani Nikula
2017-02-03 14:19 ` [PATCH v2 07/13] drm/i915/dp: cache common rates with " Jani Nikula
2017-02-03 14:19 ` [PATCH v2 08/13] drm/i915/dp: do not limit rate seek when not needed Jani Nikula
2017-02-03 14:19 ` [PATCH v2 09/13] drm/i915/dp: don't call the link parameters sink parameters Jani Nikula
2017-02-03 14:19 ` [PATCH v2 10/13] drm/i915/dp: add functions for max common link rate and lane count Jani Nikula
2017-02-03 14:19 ` [PATCH v2 11/13] drm/i915/mst: use max link not sink " Jani Nikula
2017-02-03 14:19 ` [PATCH v2 12/13] drm/i915/dp: localize link rate index variable more Jani Nikula
2017-02-07 20:17   ` Manasi Navare [this message]
2017-02-03 14:19 ` [PATCH v2 13/13] drm/i915/dp: use readb and writeb calls for single byte DPCD access Jani Nikula
2017-02-03 17:25   ` Ville Syrjälä
2017-02-03 16:56 ` ✗ Fi.CI.BAT: failure for drm/i915/dp: link rate and lane count refactoring (rev2) Patchwork
2017-02-07 20:15 ` [PATCH v2 00/13] drm/i915/dp: link rate and lane count refactoring Manasi Navare

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=20170207201734.GB26663@intel.com \
    --to=manasi.d.navare@intel.com \
    --cc=dhinakaran.pandiyan@intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=jani.nikula@intel.com \
    /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;
as well as URLs for NNTP newsgroup(s).