[PATCH 21/21] fixup! drm/i915: Drain freed objects in gem_contexts selftest
Maarten Lankhorst
maarten.lankhorst at linux.intel.com
Tue Sep 28 06:10:16 UTC 2021
---
drivers/gpu/drm/i915/gem/selftests/i915_gem_context.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
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 bc9af29fbae3..cac102459965 100644
--- a/drivers/gpu/drm/i915/gem/selftests/i915_gem_context.c
+++ b/drivers/gpu/drm/i915/gem/selftests/i915_gem_context.c
@@ -1491,7 +1491,7 @@ static int write_to_scratch(struct i915_gem_context *ctx,
u32 *cmd;
int err;
- GEM_BUG_ON(offset < I915_GTT_PAGE_SIZE);
+ GEM_BUG_ON(offset < 2 * I915_GTT_PAGE_SIZE);
err = check_scratch(ctx->vm, offset);
if (err)
@@ -1589,7 +1589,7 @@ static int read_from_scratch(struct i915_gem_context *ctx,
u32 *cmd;
int err;
- GEM_BUG_ON(offset < I915_GTT_PAGE_SIZE);
+ GEM_BUG_ON(offset < 2 * I915_GTT_PAGE_SIZE);
err = check_scratch(ctx->vm, offset);
if (err)
@@ -1609,7 +1609,7 @@ static int read_from_scratch(struct i915_gem_context *ctx,
goto out_vm;
}
- err = i915_vma_pin(vma, 0, 0, PIN_USER | PIN_OFFSET_FIXED);
+ err = i915_vma_pin(vma, 0, 0, PIN_USER | PIN_OFFSET_FIXED | I915_GTT_PAGE_SIZE);
if (err)
goto out_vm;
@@ -1831,7 +1831,7 @@ static int igt_vm_isolation(void *arg)
/* Leave enough space at offset 0 for the batch */
offset = igt_random_offset(&prng,
- I915_GTT_PAGE_SIZE, vm_total,
+ 2 * I915_GTT_PAGE_SIZE, vm_total,
sizeof(u32), alignof_dword);
err = write_to_scratch(ctx_a, engine,
--
2.33.0
More information about the Intel-gfx-trybot
mailing list