Thread (34 messages) 34 messages, 2 authors, 2021-01-15

[igt-dev] [PATCH i-g-t v16 21/31] tests/gem_ppgtt: Adopt test to use intel_bb with allocator

From: Zbigniew Kempczyński <hidden>
Date: 2021-01-15 12:09:25
Subsystem: the rest · Maintainer: Linus Torvalds

Tests work in multiprocess environment so we must turn on/off
thread in parent process which is responsible for allocations.

Signed-off-by: Zbigniew Kempczyński <redacted>
Cc: Dominik Grzegorzek <redacted>
Cc: Chris Wilson <redacted>
---
 tests/i915/gem_ppgtt.c | 6 ++++++
 1 file changed, 6 insertions(+)
diff --git a/tests/i915/gem_ppgtt.c b/tests/i915/gem_ppgtt.c
index 5f8b34224..d44bf0785 100644
--- a/tests/i915/gem_ppgtt.c
+++ b/tests/i915/gem_ppgtt.c
@@ -283,10 +283,13 @@ igt_main
 		rcs = calloc(sizeof(*rcs), nchild);
 		igt_assert(rcs);
 
+		intel_allocator_multiprocess_start();		
+
 		fork_bcs_copy(30, 0x4000, bcs, 1);
 		fork_rcs_copy(30, 0x8000 / nchild, rcs, nchild, 0);
 
 		igt_waitchildren();
+		intel_allocator_multiprocess_stop();
 
 		surfaces_check(bcs, 1, 0x4000);
 		surfaces_check(rcs, nchild, 0x8000 / nchild);
@@ -310,10 +313,13 @@ igt_main
 		rcs = calloc(sizeof(*rcs), nchild);
 		igt_assert(rcs);
 
+		intel_allocator_multiprocess_start();
+
 		fork_rcs_copy(30, 0x8000 / nchild, rcs, nchild, CREATE_CONTEXT);
 		fork_bcs_copy(30, 0x4000, bcs, 1);
 
 		igt_waitchildren();
+		intel_allocator_multiprocess_stop();
 
 		surfaces_check(bcs, 1, 0x4000);
 		surfaces_check(rcs, nchild, 0x8000 / nchild);
-- 
2.26.0

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help