public inbox for igt-dev@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Nidhi Gupta <nidhi1.gupta@intel.com>
To: igt-dev@lists.freedesktop.org
Cc: Nidhi Gupta <nidhi1.gupta@intel.com>
Subject: [igt-dev] [PATCH v4 6/7] tests/kms_plane_scaling: Limit the execution to two pipes/planes
Date: Thu,  2 Feb 2023 10:45:08 +0530	[thread overview]
Message-ID: <20230202051509.28983-7-nidhi1.gupta@intel.com> (raw)
In-Reply-To: <20230202051509.28983-1-nidhi1.gupta@intel.com>

From: Bhanuprakash Modem <bhanuprakash.modem@intel.com>

As the execution is taking more time, limit the execution of
clipping-clamping-[rotation | pixel-formats] tests to two (first
& last) pipes and two (first & last) planes.

Signed-off-by: Bhanuprakash Modem <bhanuprakash.modem@intel.com>
Signed-off-by: Nidhi Gupta <nidhi1.gupta@intel.com>
---
 tests/kms_plane_scaling.c | 47 +++++++++++++++++++++++++++++++++++++++
 1 file changed, 47 insertions(+)

diff --git a/tests/kms_plane_scaling.c b/tests/kms_plane_scaling.c
index 887a55e6..c32ea9d4 100644
--- a/tests/kms_plane_scaling.c
+++ b/tests/kms_plane_scaling.c
@@ -485,6 +485,8 @@ static void test_scaler_with_rotation_pipe(data_t *d,
 	unsigned format = DRM_FORMAT_XRGB8888;
 	uint64_t modifier = DRM_FORMAT_MOD_LINEAR;
 	igt_plane_t *plane;
+	int first_plane = -1;
+	int last_plane = -1;
 
 	cleanup_crtc(d);
 
@@ -494,6 +496,19 @@ static void test_scaler_with_rotation_pipe(data_t *d,
 		if (plane->type == DRM_PLANE_TYPE_CURSOR)
 			continue;
 
+		if (first_plane < 0)
+			first_plane = j__;
+
+		last_plane = j__;
+	}
+
+	for_each_plane_on_pipe(display, pipe, plane) {
+		if (plane->type == DRM_PLANE_TYPE_CURSOR)
+			continue;
+
+		if (!d->extended && j__ != first_plane && j__ != last_plane)
+			continue;
+
 		for (int i = 0; i < ARRAY_SIZE(rotations); i++) {
 			igt_rotation_t rot = rotations[i];
 
@@ -514,17 +529,32 @@ static void test_scaler_with_pixel_format_pipe(data_t *d, int width, int height,
 	igt_display_t *display = &d->display;
 	uint64_t modifier = DRM_FORMAT_MOD_LINEAR;
 	igt_plane_t *plane;
+	int first_plane = -1;
+	int last_plane = -1;
 
 	cleanup_crtc(d);
 
 	igt_output_set_pipe(output, pipe);
 
+	for_each_plane_on_pipe(display, pipe, plane) {
+		if (plane->type == DRM_PLANE_TYPE_CURSOR)
+			continue;
+
+		if (first_plane < 0)
+			first_plane = j__;
+
+		last_plane = j__;
+	}
+
 	for_each_plane_on_pipe(display, pipe, plane) {
 		struct igt_vec tested_formats;
 
 		if (plane->type == DRM_PLANE_TYPE_CURSOR)
 			continue;
 
+		if (!d->extended && j__ != first_plane && j__ != last_plane)
+			continue;
+
 		igt_vec_init(&tested_formats, sizeof(uint32_t));
 
 		for (int j = 0; j < plane->drm_plane->count_formats; j++) {
@@ -845,6 +875,8 @@ static data_t data;
 igt_main_args("", long_opts, help_str, opt_handler, &data)
 {
 	enum pipe pipe;
+	enum pipe active_pipes[IGT_MAX_PIPES];
+	uint32_t last_pipe = 0;
 
 	igt_fixture {
 		data.drm_fd = drm_open_driver_master(DRIVER_ANY);
@@ -852,6 +884,11 @@ igt_main_args("", long_opts, help_str, opt_handler, &data)
 		data.devid = is_i915_device(data.drm_fd) ?
 			intel_get_drm_devid(data.drm_fd) : 0;
 		igt_require(data.display.is_atomic);
+
+		/* Get active pipes. */
+		for_each_pipe(&data.display, pipe)
+			active_pipes[last_pipe++] = pipe;
+		last_pipe--;
 	}
 
 	igt_subtest_group {
@@ -916,6 +953,11 @@ igt_main_args("", long_opts, help_str, opt_handler, &data)
 			for_each_pipe_with_single_output(&data.display, pipe, output) {
 				drmModeModeInfo *mode;
 
+				if (igt_run_in_simulation() &&
+				    pipe != active_pipes[0] &&
+				    pipe != active_pipes[last_pipe])
+					continue;
+
 				mode = igt_output_get_mode(output);
 
 				igt_dynamic_f("pipe-%s-%s", kmstest_pipe_name(pipe), igt_output_name(output))
@@ -929,6 +971,11 @@ igt_main_args("", long_opts, help_str, opt_handler, &data)
 			for_each_pipe_with_single_output(&data.display, pipe, output) {
 				drmModeModeInfo *mode;
 
+				if (igt_run_in_simulation() &&
+				    pipe != active_pipes[0] &&
+				    pipe != active_pipes[last_pipe])
+					continue;
+
 				mode = igt_output_get_mode(output);
 
 				igt_dynamic_f("pipe-%s-%s", kmstest_pipe_name(pipe), igt_output_name(output))
-- 
2.39.0

  parent reply	other threads:[~2023-02-02  5:09 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-02  5:15 [igt-dev] [PATCH v4 0/7] Limit the execution to few pipes/planes Nidhi Gupta
2023-02-02  5:15 ` [igt-dev] [PATCH v4 1/7] tests/i915/kms_draw_crc: Ignore RGB565 & XRGB2101010 formats on simulation Nidhi Gupta
2023-02-02  5:15 ` [igt-dev] [PATCH v4 2/7] tests/kms_async_flips: Limit the execution to single pipe Nidhi Gupta
2023-02-02  5:15 ` [igt-dev] [PATCH v4 3/7] tests/kms_pipe_crc_basic: Limit the execution to two pipes Nidhi Gupta
2023-02-02 10:33   ` Modem, Bhanuprakash
2023-02-03  2:15   ` [igt-dev] [PATCH v5 " Nidhi Gupta
2023-02-03  5:49     ` [igt-dev] [i-g-t V3 " Bhanuprakash Modem
2023-02-02  5:15 ` [igt-dev] [PATCH v4 4/7] tests/kms_plane_alpha_blend: Limit the execution to single pipe & two planes Nidhi Gupta
2023-02-02  6:01   ` [igt-dev] [PATCH v5 " Nidhi Gupta
2023-02-02  7:00     ` Nidhi Gupta
2023-02-02 15:00       ` Kamil Konieczny
2023-02-02  5:15 ` [igt-dev] [PATCH v4 5/7] tests/kms_plane_cursor: Limit the execution to two pipes Nidhi Gupta
2023-02-02  5:15 ` Nidhi Gupta [this message]
2023-02-02  5:15 ` [igt-dev] [PATCH v4 7/7] tests/i915/kms_frontbuffer_tracking: Reduce the execution time on simulation Nidhi Gupta
2023-02-02  5:51 ` [igt-dev] ✗ GitLab.Pipeline: warning for Limit the execution to few pipes/planes (rev2) Patchwork
2023-02-02  6:00 ` [igt-dev] ✗ Fi.CI.BUILD: failure for Limit the execution to few pipes/planes (rev3) Patchwork
2023-02-02  6:00 ` [igt-dev] ✗ Fi.CI.BAT: failure for Limit the execution to few pipes/planes (rev2) Patchwork
2023-02-02  7:25 ` [igt-dev] ✓ Fi.CI.BAT: success for Limit the execution to few pipes/planes (rev4) Patchwork
2023-02-02  7:26 ` [igt-dev] ✗ GitLab.Pipeline: warning " Patchwork
2023-02-02 15:45 ` [igt-dev] ✓ Fi.CI.IGT: success " Patchwork
2023-02-03  2:40 ` [igt-dev] ✗ GitLab.Pipeline: warning for Limit the execution to few pipes/planes (rev5) Patchwork
2023-02-03  7:16 ` [igt-dev] ✗ GitLab.Pipeline: warning for Limit the execution to few pipes/planes (rev6) Patchwork
2023-02-03 12:40 ` [igt-dev] ✓ Fi.CI.BAT: success for Limit the execution to few pipes/planes (rev5) Patchwork
2023-02-03 13:08 ` [igt-dev] ✓ Fi.CI.BAT: success for Limit the execution to few pipes/planes (rev6) Patchwork
2023-02-03 17:48 ` [igt-dev] ✓ Fi.CI.IGT: success for Limit the execution to few pipes/planes (rev5) Patchwork
2023-02-04  0:12 ` [igt-dev] ✓ Fi.CI.IGT: success for Limit the execution to few pipes/planes (rev6) Patchwork

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230202051509.28983-7-nidhi1.gupta@intel.com \
    --to=nidhi1.gupta@intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox