[PATCH 18/29] drm/i915: Drain freed objects in gem_contexts selftest

Maarten Lankhorst maarten.lankhorst at linux.intel.com
Wed Sep 22 10:40:54 UTC 2021


In the next commit, we don't evict when refcount = 0, so we need to
call drain freed objects, because we want to pin new bo's in the same
place, causing a test failure.

Signed-off-by: Maarten Lankhorst <maarten.lankhorst at linux.intel.com>
---
 drivers/gpu/drm/i915/gem/selftests/i915_gem_context.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/gpu/drm/i915/gem/selftests/i915_gem_context.c b/drivers/gpu/drm/i915/gem/selftests/i915_gem_context.c
index b32f7fed2d9c..8365a1061116 100644
--- a/drivers/gpu/drm/i915/gem/selftests/i915_gem_context.c
+++ b/drivers/gpu/drm/i915/gem/selftests/i915_gem_context.c
@@ -1724,6 +1724,7 @@ static int read_from_scratch(struct i915_gem_context *ctx,
 	i915_vm_put(vm);
 out:
 	i915_gem_object_put(obj);
+	i915_gem_drain_freed_objects(i915);
 	return err;
 }
 
-- 
2.33.0



More information about the Intel-gfx-trybot mailing list