diff options
-rw-r--r-- | Android.bp | 6 | ||||
-rw-r--r-- | tests/kms_setmode.c | 6 |
2 files changed, 12 insertions, 0 deletions
diff --git a/Android.bp b/Android.bp index 01f59dbed..567772d75 100644 --- a/Android.bp +++ b/Android.bp @@ -231,3 +231,9 @@ cc_test { defaults: ["igt-gpu-tools-test-defaults"], srcs: ["tests/syncobj_wait.c"], } + +cc_test { + name: "kms_setmode", + defaults: ["igt-gpu-tools-test-defaults"], + srcs: ["tests/kms_setmode.c"], +} diff --git a/tests/kms_setmode.c b/tests/kms_setmode.c index 8ace587ee..a47a886ee 100644 --- a/tests/kms_setmode.c +++ b/tests/kms_setmode.c @@ -23,7 +23,9 @@ #include "config.h" #include "igt.h" +#if defined(USE_CAIRO_PIXMAN) #include <cairo.h> +#endif #include <errno.h> #include <stdint.h> #include <unistd.h> @@ -134,6 +136,7 @@ static bool crtc_supports_mode(struct crtc_config *crtc, drmModeModeInfo *mode) return true; } +#if defined(USE_CAIRO_PIXMAN) static int paint_fb(struct igt_fb *fb, const char *test_name, const char **crtc_str, int crtc_count, int current_crtc_idx) { @@ -165,6 +168,7 @@ static int paint_fb(struct igt_fb *fb, const char *test_name, return 0; } +#endif static void create_fb_for_crtc(struct crtc_config *crtc, struct igt_fb *fb_info) @@ -569,7 +573,9 @@ static void test_crtc_config(const struct test_config *tconf, igt_info(" %s\n", crtc_strs[i]); create_fb_for_crtc(crtc, &crtc->fb_info); +#if defined(USE_CAIRO_PIXMAN) paint_fb(&crtc->fb_info, tconf->name, crtc_strs, crtc_count, i); +#endif ids = get_connector_ids(crtc); if (tconf->flags & TEST_STEALING) |