This reverts commit bcefacd359f07dee18795dd80f834acb47fd21eb. IGT conversion is ready, so these execptions can already be removed. Once CI is clean, this commit will actually be removed from topic/core-for-CI. Signed-off-by: Lucas De Marchi <lucas.demarchi@xxxxxxxxx> --- .../gpu/drm/i915/gem/i915_gem_execbuffer.c | 21 +++++-------------- 1 file changed, 5 insertions(+), 16 deletions(-) diff --git a/drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c b/drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c index b279588c0672..c326bd2b444f 100644 --- a/drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c +++ b/drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c @@ -492,27 +492,16 @@ eb_unreserve_vma(struct eb_vma *ev) ev->flags &= ~__EXEC_OBJECT_RESERVED; } -static bool platform_has_relocs_enabled(const struct i915_execbuffer *eb) -{ - /* - * Relocations are disallowed starting from gen12 with Tigerlake - * as an exception. To unblock CI, we are temporarily allowing it - * for Rocketlake and Alderlake. - */ - if (GRAPHICS_VER(eb->i915) < 12 || IS_TIGERLAKE(eb->i915) || - IS_ROCKETLAKE(eb->i915) || IS_ALDERLAKE_S(eb->i915) || - IS_ALDERLAKE_P(eb->i915)) - return true; - - return false; -} - static int eb_validate_vma(struct i915_execbuffer *eb, struct drm_i915_gem_exec_object2 *entry, struct i915_vma *vma) { - if (entry->relocation_count && !platform_has_relocs_enabled(eb)) + /* Relocations are disallowed for all platforms after TGL-LP. This + * also covers all platforms with local memory. + */ + if (entry->relocation_count && + GRAPHICS_VER(eb->i915) >= 12 && !IS_TIGERLAKE(eb->i915)) return -EINVAL; if (unlikely(entry->flags & eb->invalid_flags)) -- 2.36.1