* [Intel-gfx] [PATCH i-g-t 1/3] igt/kms_frontbuffer_tracking: Skip over IGT_DRAW_BLT when there's no BLT
@ 2020-02-20 9:41 Chris Wilson
2020-02-20 9:41 ` [Intel-gfx] [PATCH i-g-t 2/3] igt/kms_flip_tiling: Check GEM availability before use Chris Wilson
2020-02-20 9:41 ` [Intel-gfx] [PATCH i-g-t 3/3] igt/kms_draw_crc: Test for a working GPU first Chris Wilson
0 siblings, 2 replies; 3+ messages in thread
From: Chris Wilson @ 2020-02-20 9:41 UTC (permalink / raw)
To: intel-gfx; +Cc: igt-dev
If the blitter is not available, we cannot use it as a source for dirty
rectangles. We shall have to rely on the other engines to create GPU
dirty instead.
v2: Try using lots of subgroup+fixtures
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
---
tests/kms_frontbuffer_tracking.c | 57 ++++++++++++++++++++++++++++++--
1 file changed, 55 insertions(+), 2 deletions(-)
diff --git a/tests/kms_frontbuffer_tracking.c b/tests/kms_frontbuffer_tracking.c
index c4b4af43a..9e00fa2e1 100644
--- a/tests/kms_frontbuffer_tracking.c
+++ b/tests/kms_frontbuffer_tracking.c
@@ -3043,6 +3043,8 @@ static void basic_subtest(const struct test_mode *t)
fb1 = params->primary.fb;
for (r = 0, method = 0; method < IGT_DRAW_METHOD_COUNT; method++) {
+ if (method == IGT_DRAW_BLT && !gem_has_blitter(drm.fd))
+ continue;
if (method == IGT_DRAW_MMAP_GTT &&
!gem_has_mappable_ggtt(drm.fd))
continue;
@@ -3275,10 +3277,11 @@ static const char *flip_str(enum flip_type flip)
continue; \
if (!opt.show_hidden && t.fbs == FBS_SHARED && \
(t.plane == PLANE_CUR || t.plane == PLANE_SPR)) \
- continue;
+ continue; \
+ igt_subtest_group {
-#define TEST_MODE_ITER_END } } } } } }
+#define TEST_MODE_ITER_END } } } } } } }
struct option long_options[] = {
{ "no-status-check", 0, 0, 's'},
@@ -3324,6 +3327,10 @@ igt_main_args("", long_options, help_str, opt_handler, NULL)
}
TEST_MODE_ITER_BEGIN(t)
+ igt_fixture {
+ if (t.method == IGT_DRAW_BLT)
+ gem_require_blitter(drm.fd);
+ }
igt_subtest_f("%s-%s-%s-%s-%s-draw-%s",
feature_str(t.feature),
pipes_str(t.pipes),
@@ -3340,6 +3347,11 @@ igt_main_args("", long_options, help_str, opt_handler, NULL)
(!opt.show_hidden && t.method != IGT_DRAW_BLT))
continue;
+ igt_fixture {
+ if (t.method == IGT_DRAW_BLT)
+ gem_require_blitter(drm.fd);
+ }
+
for (t.flip = 0; t.flip < FLIP_COUNT; t.flip++)
igt_subtest_f("%s-%s-%s-%s-%sflip-%s",
feature_str(t.feature),
@@ -3358,6 +3370,11 @@ igt_main_args("", long_options, help_str, opt_handler, NULL)
(t.feature & FEATURE_FBC) == 0)
continue;
+ igt_fixture {
+ if (t.method == IGT_DRAW_BLT)
+ gem_require_blitter(drm.fd);
+ }
+
igt_subtest_f("%s-%s-%s-fliptrack",
feature_str(t.feature),
pipes_str(t.pipes),
@@ -3371,6 +3388,11 @@ igt_main_args("", long_options, help_str, opt_handler, NULL)
t.plane == PLANE_PRI)
continue;
+ igt_fixture {
+ if (t.method == IGT_DRAW_BLT)
+ gem_require_blitter(drm.fd);
+ }
+
igt_subtest_f("%s-%s-%s-%s-%s-move",
feature_str(t.feature),
pipes_str(t.pipes),
@@ -3394,6 +3416,11 @@ igt_main_args("", long_options, help_str, opt_handler, NULL)
t.plane != PLANE_SPR)
continue;
+ igt_fixture {
+ if (t.method == IGT_DRAW_BLT)
+ gem_require_blitter(drm.fd);
+ }
+
igt_subtest_f("%s-%s-%s-%s-%s-fullscreen",
feature_str(t.feature),
pipes_str(t.pipes),
@@ -3410,6 +3437,11 @@ igt_main_args("", long_options, help_str, opt_handler, NULL)
(!opt.show_hidden && t.fbs != FBS_INDIVIDUAL))
continue;
+ igt_fixture {
+ if (t.method == IGT_DRAW_BLT)
+ gem_require_blitter(drm.fd);
+ }
+
igt_subtest_f("%s-%s-%s-%s-multidraw",
feature_str(t.feature),
pipes_str(t.pipes),
@@ -3426,6 +3458,11 @@ igt_main_args("", long_options, help_str, opt_handler, NULL)
t.method != IGT_DRAW_MMAP_GTT)
continue;
+ igt_fixture {
+ if (t.method == IGT_DRAW_BLT)
+ gem_require_blitter(drm.fd);
+ }
+
igt_subtest_f("%s-farfromfence", feature_str(t.feature))
farfromfence_subtest(&t);
TEST_MODE_ITER_END
@@ -3437,6 +3474,11 @@ igt_main_args("", long_options, help_str, opt_handler, NULL)
t.fbs != FBS_INDIVIDUAL)
continue;
+ igt_fixture {
+ if (t.method == IGT_DRAW_BLT)
+ gem_require_blitter(drm.fd);
+ }
+
for (t.format = 0; t.format < FORMAT_COUNT; t.format++) {
/* Skip what we already tested. */
if (t.format == FORMAT_DEFAULT)
@@ -3456,6 +3498,12 @@ igt_main_args("", long_options, help_str, opt_handler, NULL)
t.plane != PLANE_PRI ||
t.method != IGT_DRAW_BLT)
continue;
+
+ igt_fixture {
+ if (t.method == IGT_DRAW_BLT)
+ gem_require_blitter(drm.fd);
+ }
+
igt_subtest_f("%s-%s-scaledprimary",
feature_str(t.feature),
fbs_str(t.fbs))
@@ -3470,6 +3518,11 @@ igt_main_args("", long_options, help_str, opt_handler, NULL)
t.method != IGT_DRAW_BLT)
continue;
+ igt_fixture {
+ if (t.method == IGT_DRAW_BLT)
+ gem_require_blitter(drm.fd);
+ }
+
igt_subtest_f("%s-modesetfrombusy", feature_str(t.feature))
modesetfrombusy_subtest(&t);
--
2.25.1
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [Intel-gfx] [PATCH i-g-t 2/3] igt/kms_flip_tiling: Check GEM availability before use
2020-02-20 9:41 [Intel-gfx] [PATCH i-g-t 1/3] igt/kms_frontbuffer_tracking: Skip over IGT_DRAW_BLT when there's no BLT Chris Wilson
@ 2020-02-20 9:41 ` Chris Wilson
2020-02-20 9:41 ` [Intel-gfx] [PATCH i-g-t 3/3] igt/kms_draw_crc: Test for a working GPU first Chris Wilson
1 sibling, 0 replies; 3+ messages in thread
From: Chris Wilson @ 2020-02-20 9:41 UTC (permalink / raw)
To: intel-gfx; +Cc: igt-dev
We use the GPU to convert between tiling formats, indirectly via the
call to igt_create_pattern_fb. So before we try and execute commands on
the GPU, we should check that the GPU is available.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
---
tests/kms_flip_tiling.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/tests/kms_flip_tiling.c b/tests/kms_flip_tiling.c
index 17cf816de..1465e73a1 100644
--- a/tests/kms_flip_tiling.c
+++ b/tests/kms_flip_tiling.c
@@ -154,6 +154,7 @@ igt_main
igt_fixture {
data.drm_fd = drm_open_driver_master(DRIVER_INTEL);
data.gen = intel_gen(intel_get_drm_devid(data.drm_fd));
+ igt_require_gem(data.drm_fd);
data.testformat = DRM_FORMAT_XRGB8888;
--
2.25.1
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [Intel-gfx] [PATCH i-g-t 3/3] igt/kms_draw_crc: Test for a working GPU first
2020-02-20 9:41 [Intel-gfx] [PATCH i-g-t 1/3] igt/kms_frontbuffer_tracking: Skip over IGT_DRAW_BLT when there's no BLT Chris Wilson
2020-02-20 9:41 ` [Intel-gfx] [PATCH i-g-t 2/3] igt/kms_flip_tiling: Check GEM availability before use Chris Wilson
@ 2020-02-20 9:41 ` Chris Wilson
1 sibling, 0 replies; 3+ messages in thread
From: Chris Wilson @ 2020-02-20 9:41 UTC (permalink / raw)
To: intel-gfx; +Cc: igt-dev
The draw-method-blt subtests require a working GPU, so create a subtest
group for the draw-methods, and skip the BLT group using
igt_require_gem() in its fixture.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
---
tests/kms_draw_crc.c | 26 ++++++++++++++++++--------
1 file changed, 18 insertions(+), 8 deletions(-)
diff --git a/tests/kms_draw_crc.c b/tests/kms_draw_crc.c
index fa7433ab2..917a55432 100644
--- a/tests/kms_draw_crc.c
+++ b/tests/kms_draw_crc.c
@@ -331,14 +331,24 @@ igt_main
for (format_idx = 0; format_idx < N_FORMATS; format_idx++) {
for (method = 0; method < IGT_DRAW_METHOD_COUNT; method++) {
- for (tiling_idx = 0; tiling_idx < N_TILING_METHODS; tiling_idx++) {
- igt_subtest_f("draw-method-%s-%s-%s",
- format_str(format_idx),
- igt_draw_get_method_name(method),
- tiling_str(tiling_idx))
- draw_method_subtest(method, format_idx,
- tilings[tiling_idx]);
- } } }
+ igt_subtest_group {
+ igt_fixture {
+ if (method == IGT_DRAW_BLT)
+ igt_require_gem(drm_fd);
+ }
+
+ for (tiling_idx = 0;
+ tiling_idx < N_TILING_METHODS;
+ tiling_idx++) {
+ igt_subtest_f("draw-method-%s-%s-%s",
+ format_str(format_idx),
+ igt_draw_get_method_name(method),
+ tiling_str(tiling_idx))
+ draw_method_subtest(method,
+ format_idx,
+ tilings[tiling_idx]);
+ }
+ }}}
igt_subtest("fill-fb")
fill_fb_subtest();
--
2.25.1
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-02-20 9:41 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-02-20 9:41 [Intel-gfx] [PATCH i-g-t 1/3] igt/kms_frontbuffer_tracking: Skip over IGT_DRAW_BLT when there's no BLT Chris Wilson
2020-02-20 9:41 ` [Intel-gfx] [PATCH i-g-t 2/3] igt/kms_flip_tiling: Check GEM availability before use Chris Wilson
2020-02-20 9:41 ` [Intel-gfx] [PATCH i-g-t 3/3] igt/kms_draw_crc: Test for a working GPU first Chris Wilson
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).