diff options
author | Zbigniew Kempczyński <zbigniew.kempczynski@intel.com> | 2021-07-20 07:51:05 +0200 |
---|---|---|
committer | Zbigniew Kempczyński <zbigniew.kempczynski@intel.com> | 2021-08-10 21:02:50 +0200 |
commit | 4650fa934bb88ebc650956bc48a89ee67cdab71d (patch) | |
tree | 05748be9a84bc5e19cb61f5980268f442fd5cf12 /tests/i915/gem_unref_active_buffers.c | |
parent | 8dcdc82f4ae22cb014d56cfe6fcf860a263e2aa0 (diff) |
tests/gem_unref_active_buffers: Adopt to use allocator
For newer gens we're not able to rely on relocations. Adopt to use
offsets acquired from the allocator.
Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com>
Cc: Petri Latvala <petri.latvala@intel.com>
Cc: Ashutosh Dixit <ashutosh.dixit@intel.com>
Reviewed-by: Ashutosh Dixit <ashutosh.dixit@intel.com>
Diffstat (limited to 'tests/i915/gem_unref_active_buffers.c')
-rw-r--r-- | tests/i915/gem_unref_active_buffers.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/tests/i915/gem_unref_active_buffers.c b/tests/i915/gem_unref_active_buffers.c index 731190b3..3b8c981d 100644 --- a/tests/i915/gem_unref_active_buffers.c +++ b/tests/i915/gem_unref_active_buffers.c @@ -69,11 +69,13 @@ igt_simple_main struct itimerval itv; igt_spin_t *spin; int i915; + uint64_t ahnd; i915 = drm_open_driver(DRIVER_INTEL); igt_require_gem(i915); - spin = igt_spin_new(i915); + ahnd = get_reloc_ahnd(i915, 0); + spin = igt_spin_new(i915, .ahnd = ahnd); fcntl(i915, F_SETFL, fcntl(i915, F_GETFL) | O_NONBLOCK); sigaction(SIGALRM, &sa, &old_sa); @@ -118,4 +120,5 @@ igt_simple_main sigaction(SIGALRM, &old_sa, NULL); igt_spin_free(i915, spin); + put_ahnd(ahnd); } |