[igt-dev] [i-g-t v8 20/51] tests/kms_pipe_crc_basic: Add support for Bigjoiner

Bhanuprakash Modem bhanuprakash.modem at intel.com
Thu Feb 23 15:09:47 UTC 2023


This patch will add a check to Skip the subtest if a selected pipe/output
combo won't support Bigjoiner or 8K mode.

Example:
* Pipe-D wont support a mode > 5K
* To use 8K mode on a pipe then consecutive pipe must be available & free.

V2: - Use updated helper name

Signed-off-by: Bhanuprakash Modem <bhanuprakash.modem at intel.com>
Reviewed-by: Mohammed Thasleem <mohammed.thasleem at intel.com>
---
 tests/kms_pipe_crc_basic.c | 24 ++++++++++++++++++++++++
 1 file changed, 24 insertions(+)

diff --git a/tests/kms_pipe_crc_basic.c b/tests/kms_pipe_crc_basic.c
index b0b8665b3..65afc9f60 100644
--- a/tests/kms_pipe_crc_basic.c
+++ b/tests/kms_pipe_crc_basic.c
@@ -287,6 +287,21 @@ static void test_disable_crc_after_crtc(data_t *data, enum pipe pipe,
 	igt_remove_fb(data->drm_fd, &data->fb);
 }
 
+static bool pipe_output_combo_valid(igt_display_t *display,
+				    enum pipe pipe, igt_output_t *output)
+{
+	bool ret = true;
+
+	igt_display_reset(display);
+
+	igt_output_set_pipe(output, pipe);
+	if (!i915_pipe_output_combo_valid(display))
+		ret = false;
+	igt_output_set_pipe(output, PIPE_NONE);
+
+	return ret;
+}
+
 data_t data = {0, };
 
 static int opt_handler(int opt, int opt_index, void *_data)
@@ -360,6 +375,9 @@ igt_main_args("e", NULL, help_str, opt_handler, NULL)
 				if (simulation_constraint(pipe))
 					continue;
 
+				if(!pipe_output_combo_valid(&data.display, pipe, output))
+					continue;
+
 				igt_dynamic_f("pipe-%s-%s", kmstest_pipe_name(pipe), output->name) {
 					if (tests[i].flags & TEST_SUSPEND) {
 						test_read_crc(&data, pipe, output, 0);
@@ -391,6 +409,9 @@ igt_main_args("e", NULL, help_str, opt_handler, NULL)
 			if (simulation_constraint(pipe))
 				continue;
 
+			if(!pipe_output_combo_valid(&data.display, pipe, output))
+				continue;
+
 			igt_dynamic_f("pipe-%s-%s", kmstest_pipe_name(pipe), output->name)
 				test_disable_crc_after_crtc(&data, pipe, output);
 		}
@@ -402,6 +423,9 @@ igt_main_args("e", NULL, help_str, opt_handler, NULL)
 			if (simulation_constraint(pipe))
 				continue;
 
+			if(!pipe_output_combo_valid(&data.display, pipe, output))
+				continue;
+
 			igt_dynamic_f("pipe-%s-%s", kmstest_pipe_name(pipe), output->name)
 				test_compare_crc(&data, pipe, output);
 		}
-- 
2.39.1



More information about the igt-dev mailing list