[Intel-gfx] [PATCH 5/5] tests: Convert the ctx test to use render nodes when possible

Damien Lespiau damien.lespiau at intel.com
Thu Oct 24 16:40:56 CEST 2013


Signed-off-by: Damien Lespiau <damien.lespiau at intel.com>
---
 tests/gem_ctx_bad_destroy.c | 2 +-
 tests/gem_ctx_bad_exec.c    | 2 +-
 tests/gem_ctx_basic.c       | 4 ++--
 tests/gem_ctx_create.c      | 2 +-
 tests/gem_ctx_exec.c        | 2 +-
 5 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/tests/gem_ctx_bad_destroy.c b/tests/gem_ctx_bad_destroy.c
index 7852618..e93642f 100644
--- a/tests/gem_ctx_bad_destroy.c
+++ b/tests/gem_ctx_bad_destroy.c
@@ -62,7 +62,7 @@ int main(int argc, char *argv[])
 
 	igt_skip_on_simulation();
 
-	fd = drm_open_any();
+	fd = drm_open_any_render();
 
 	ctx_id = gem_context_create(fd);
 
diff --git a/tests/gem_ctx_bad_exec.c b/tests/gem_ctx_bad_exec.c
index dadd663..c60e693 100644
--- a/tests/gem_ctx_bad_exec.c
+++ b/tests/gem_ctx_bad_exec.c
@@ -91,7 +91,7 @@ int main(int argc, char *argv[])
 	igt_subtest_init(argc, argv);
 
 	igt_fixture {
-		fd = drm_open_any();
+		fd = drm_open_any_render();
 
 		ctx_id = gem_context_create(fd);
 
diff --git a/tests/gem_ctx_basic.c b/tests/gem_ctx_basic.c
index 47f4b4b..bc21a8a 100644
--- a/tests/gem_ctx_basic.c
+++ b/tests/gem_ctx_basic.c
@@ -64,7 +64,7 @@ static void *work(void *arg)
 	int i;
 
 	if (multiple_fds)
-		td_fd = fd = drm_open_any();
+		td_fd = fd = drm_open_any_render();
 	else
 		td_fd = fd;
 
@@ -133,7 +133,7 @@ int main(int argc, char *argv[])
 {
 	int i;
 
-	fd = drm_open_any();
+	fd = drm_open_any_render();
 	devid = intel_get_drm_devid(fd);
 
 	if (igt_run_in_simulation()) {
diff --git a/tests/gem_ctx_create.c b/tests/gem_ctx_create.c
index f22522b..1d9ff86 100644
--- a/tests/gem_ctx_create.c
+++ b/tests/gem_ctx_create.c
@@ -47,7 +47,7 @@ int main(int argc, char *argv[])
 	create.ctx_id = rand();
 	create.pad = rand();
 
-	fd = drm_open_any();
+	fd = drm_open_any_render();
 
 	ret = drmIoctl(fd, CONTEXT_CREATE_IOCTL, &create);
 	if (ret != 0 && (errno == ENODEV || errno == EINVAL)) {
diff --git a/tests/gem_ctx_exec.c b/tests/gem_ctx_exec.c
index 5f2c59f..620a944 100644
--- a/tests/gem_ctx_exec.c
+++ b/tests/gem_ctx_exec.c
@@ -102,7 +102,7 @@ int main(int argc, char *argv[])
 
 	igt_skip_on_simulation();
 
-	fd = drm_open_any();
+	fd = drm_open_any_render();
 
 	ctx_id = gem_context_create(fd);
 	handle = gem_create(fd, 4096);
-- 
1.8.3.1




More information about the Intel-gfx mailing list