[Intel-gfx] [PATCH] drm/i915: Add relocation exceptions for two other platforms

Daniel Vetter daniel at ffwll.ch
Tue May 11 17:04:56 UTC 2021


On Tue, May 11, 2021 at 10:31:39AM +0200, Zbigniew Kempczyński wrote:
> We have established previously we stop using relocations starting
> from gen12 platforms with Tigerlake as an exception. Unfortunately
> we need extend transition period and support relocations for two
> other igfx platforms - Rocketlake and Alderlake.
> 
> Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski at intel.com>
> Cc: Dave Airlie <airlied at redhat.com>
> Cc: Daniel Vetter <daniel.vetter at intel.com>
> Cc: Jason Ekstrand <jason at jlekstrand.net>

So the annoying thing here is that now media-driver is fixed:

https://github.com/intel/media-driver/commit/144020c37770083974bedf59902b70b8f444c799

Which means igt is really the only thing left.

Dave, is this still ok for an acked exception, or is this now leaning
towards "just fix igt"?
-Daniel
> ---
>  drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c | 10 +++++++---
>  1 file changed, 7 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c b/drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c
> index 297143511f99..f80da1d6d9b2 100644
> --- a/drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c
> +++ b/drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c
> @@ -496,11 +496,15 @@ eb_validate_vma(struct i915_execbuffer *eb,
>  		struct drm_i915_gem_exec_object2 *entry,
>  		struct i915_vma *vma)
>  {
> -	/* Relocations are disallowed for all platforms after TGL-LP.  This
> -	 * also covers all platforms with local memory.
> +	/*
> +	 * Relocations are disallowed starting from gen12 with some exceptions
> +	 * - TGL/RKL/ADL.
>  	 */
>  	if (entry->relocation_count &&
> -	    INTEL_GEN(eb->i915) >= 12 && !IS_TIGERLAKE(eb->i915))
> +	    INTEL_GEN(eb->i915) >= 12 && !(IS_TIGERLAKE(eb->i915) ||
> +					   IS_ROCKETLAKE(eb->i915) ||
> +					   IS_ALDERLAKE_S(eb->i915) ||
> +					   IS_ALDERLAKE_P(eb->i915)))
>  		return -EINVAL;
>  
>  	if (unlikely(entry->flags & eb->invalid_flags))
> -- 
> 2.26.0
> 

-- 
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch


More information about the Intel-gfx mailing list