diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2013-06-21 16:52:53 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2013-06-21 16:54:47 +0100 |
commit | d2048819b9db8781c65399f28696f375448a03e6 (patch) | |
tree | c947dfc2cf8fd2aa4d519a8ec580c3c4adc78b17 | |
parent | e56754965fad7c53130cecd26a91b841e22a8ab9 (diff) |
kms_render: Skip unsupported display configurations
Certain modes may not be supported by certain combinations of pipes.
This is impossible to determine upfront, and we await an atomic
modesetting query operation. In the meantime, if we fail to set a mode,
just skip that test.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=66000
-rw-r--r-- | tests/kms_render.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/tests/kms_render.c b/tests/kms_render.c index 707ce27a..3867a0b8 100644 --- a/tests/kms_render.c +++ b/tests/kms_render.c @@ -124,9 +124,10 @@ static int test_format(const char *test_name, if (!kmstest_create_fb2(drm_fd, width, height, format, false, &fb[1])) goto err2; - do_or_die(drmModeSetCrtc(drm_fd, cconf->crtc->crtc_id, fb[0].fb_id, + if (drmModeSetCrtc(drm_fd, cconf->crtc->crtc_id, fb[0].fb_id, 0, 0, &cconf->connector->connector_id, 1, - mode)); + mode)) + goto err2; do_or_die(drmModePageFlip(drm_fd, cconf->crtc->crtc_id, fb[0].fb_id, 0, NULL)); sleep(2); @@ -152,8 +153,10 @@ static int test_format(const char *test_name, err2: kmstest_remove_fb(drm_fd, &fb[0]); err1: - fprintf(stderr, "skip testing unsupported format %s\n", - kmstest_format_str(format)); + printf("Test %s with %s on %s: SKIPPED\n", + test_name, mode_format_str, cconf_str); + free(mode_format_str); + free(cconf_str); return -1; } |