[Intel-gfx] [PATCH] drm/i915/pmu: Drop redundant IS_VALLEYVIEW check in __get_rc6()
Nilawar, Badal
badal.nilawar at intel.com
Mon Mar 14 05:29:18 UTC 2022
On 12-03-2022 01:30, Ashutosh Dixit wrote:
> Because VLV_GT_RENDER_RC6 == GEN6_GT_GFX_RC6, the IS_VALLEYVIEW() check is
> not needed. Neither is the check present in other code paths which call
> intel_rc6_residency_ns() (in functions gen6_drpc(), rc6_residency() and
> rc6_residency_ms_show()).
>
> Signed-off-by: Ashutosh Dixit <ashutosh.dixit at intel.com>
> ---
> drivers/gpu/drm/i915/i915_pmu.c | 5 +----
> 1 file changed, 1 insertion(+), 4 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/i915_pmu.c b/drivers/gpu/drm/i915/i915_pmu.c
> index cfc21042499d..3e3b09588fd3 100644
> --- a/drivers/gpu/drm/i915/i915_pmu.c
> +++ b/drivers/gpu/drm/i915/i915_pmu.c
> @@ -148,10 +148,7 @@ static u64 __get_rc6(struct intel_gt *gt)
> struct drm_i915_private *i915 = gt->i915;
> u64 val;
>
> - val = intel_rc6_residency_ns(>->rc6,
> - IS_VALLEYVIEW(i915) ?
> - VLV_GT_RENDER_RC6 :
> - GEN6_GT_GFX_RC6);
> + val = intel_rc6_residency_ns(>->rc6, GEN6_GT_GFX_RC6);
This change looks fine.
Reviewed-by: Badal Nilawar <badal.nilawar at intel.com>
>
> if (HAS_RC6p(i915))
> val += intel_rc6_residency_ns(>->rc6, GEN6_GT_GFX_RC6p);
More information about the Intel-gfx
mailing list