drm/i915/selftests: Remove hardcoded value with a macro
authorNirmoy Das <nirmoy.das@intel.com>
Tue, 13 Dec 2022 12:00:10 +0000 (13:00 +0100)
committerMatthew Auld <matthew.auld@intel.com>
Tue, 20 Dec 2022 09:56:33 +0000 (09:56 +0000)
Use MI_USE_GGTT instead of hardcoded value.

Signed-off-by: Nirmoy Das <nirmoy.das@intel.com>
Reviewed-by: Matthew Auld <matthew.auld@intel.com>
Reviewed-by: Andrzej Hajda <andrzej.hajda@intel.com>
Signed-off-by: Matthew Auld <matthew.auld@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20221213120010.5857-1-nirmoy.das@intel.com
drivers/gpu/drm/i915/gem/selftests/i915_gem_coherency.c

index c228fe4aba505a371769320da20581d9a5e1984c..3bef1beec7cbb5a72bf0c6d804c37b247277a22f 100644 (file)
@@ -222,7 +222,7 @@ static int gpu_set(struct context *ctx, unsigned long offset, u32 v)
        }
 
        if (GRAPHICS_VER(ctx->engine->i915) >= 8) {
-               *cs++ = MI_STORE_DWORD_IMM_GEN4 | 1 << 22;
+               *cs++ = MI_STORE_DWORD_IMM_GEN4 | MI_USE_GGTT;
                *cs++ = lower_32_bits(i915_ggtt_offset(vma) + offset);
                *cs++ = upper_32_bits(i915_ggtt_offset(vma) + offset);
                *cs++ = v;