[Intel-gfx] [PATCH 4/9] drm/i915/debugfs: replace I915_READ()+I915_WRITE() with intel_uncore_rmw()
Rodrigo Vivi
rodrigo.vivi at intel.com
Thu Nov 12 20:21:03 UTC 2020
On Thu, Nov 12, 2020 at 01:44:37PM +0200, Jani Nikula wrote:
> Remove the last I915_WRITE() use in i915_debugfs.c.
>
> Signed-off-by: Jani Nikula <jani.nikula at intel.com>
Reviewed-by: Rodrigo Vivi <rodrigo.vivi at intel.com>
> ---
> drivers/gpu/drm/i915/i915_debugfs.c | 8 ++------
> 1 file changed, 2 insertions(+), 6 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/i915_debugfs.c
> index 7cbca268cb61..151734a1a496 100644
> --- a/drivers/gpu/drm/i915/i915_debugfs.c
> +++ b/drivers/gpu/drm/i915/i915_debugfs.c
> @@ -1562,13 +1562,9 @@ i915_cache_sharing_set(void *data, u64 val)
> drm_dbg(&dev_priv->drm,
> "Manually setting uncore sharing to %llu\n", val);
> with_intel_runtime_pm(&dev_priv->runtime_pm, wakeref) {
> - u32 snpcr;
> -
> /* Update the cache sharing policy here as well */
> - snpcr = I915_READ(GEN6_MBCUNIT_SNPCR);
> - snpcr &= ~GEN6_MBC_SNPCR_MASK;
> - snpcr |= val << GEN6_MBC_SNPCR_SHIFT;
> - I915_WRITE(GEN6_MBCUNIT_SNPCR, snpcr);
> + intel_uncore_rmw(&dev_priv->uncore, GEN6_MBCUNIT_SNPCR,
> + GEN6_MBC_SNPCR_MASK, val << GEN6_MBC_SNPCR_SHIFT);
> }
>
> return 0;
> --
> 2.20.1
>
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx
More information about the Intel-gfx
mailing list