Re: [Intel-gfx] [PATCH igt] igt/gem_eio: Require context support before creation

2018-04-06 Thread Tvrtko Ursulin


On 06/04/2018 10:11, Chris Wilson wrote:

gem_context_create() nowadays assumes you have already checked for
context support and asserts for any error. So check first.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105924
Signed-off-by: Chris Wilson 
Cc: Tvrtko Ursulin 
---
  tests/gem_eio.c | 14 ++
  1 file changed, 10 insertions(+), 4 deletions(-)

diff --git a/tests/gem_eio.c b/tests/gem_eio.c
index 9599e73d..1a4659a9 100644
--- a/tests/gem_eio.c
+++ b/tests/gem_eio.c
@@ -703,11 +703,17 @@ igt_main
igt_subtest("in-flight-suspend")
test_inflight_suspend(fd);
  
-	igt_subtest("reset-stress")

-   test_reset_stress(fd, 0);
+   igt_subtest_group {
+   igt_fixture {
+   igt_require(gem_has_contexts(fd));
+   }
  
-	igt_subtest("unwedge-stress")

-   test_reset_stress(fd, TEST_WEDGE);
+   igt_subtest("reset-stress")
+   test_reset_stress(fd, 0);
+
+   igt_subtest("unwedge-stress")
+   test_reset_stress(fd, TEST_WEDGE);
+   }
  
  	igt_subtest_group {

const struct {



I am so good at context isolation that I can fix one thing in one stream 
of work, then switch to another stream and repeat the same mistake again. :(


Reviewed-by: Tvrtko Ursulin 

Regards,

Tvrtko


___
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx


[Intel-gfx] [PATCH igt] igt/gem_eio: Require context support before creation

2018-04-06 Thread Chris Wilson
gem_context_create() nowadays assumes you have already checked for
context support and asserts for any error. So check first.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105924
Signed-off-by: Chris Wilson 
Cc: Tvrtko Ursulin 
---
 tests/gem_eio.c | 14 ++
 1 file changed, 10 insertions(+), 4 deletions(-)

diff --git a/tests/gem_eio.c b/tests/gem_eio.c
index 9599e73d..1a4659a9 100644
--- a/tests/gem_eio.c
+++ b/tests/gem_eio.c
@@ -703,11 +703,17 @@ igt_main
igt_subtest("in-flight-suspend")
test_inflight_suspend(fd);
 
-   igt_subtest("reset-stress")
-   test_reset_stress(fd, 0);
+   igt_subtest_group {
+   igt_fixture {
+   igt_require(gem_has_contexts(fd));
+   }
 
-   igt_subtest("unwedge-stress")
-   test_reset_stress(fd, TEST_WEDGE);
+   igt_subtest("reset-stress")
+   test_reset_stress(fd, 0);
+
+   igt_subtest("unwedge-stress")
+   test_reset_stress(fd, TEST_WEDGE);
+   }
 
igt_subtest_group {
const struct {
-- 
2.16.3

___
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx