Igt-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Bhanuprakash Modem <bhanuprakash.modem@intel.com>
To: igt-dev@lists.freedesktop.org
Cc: Bhanuprakash Modem <bhanuprakash.modem@intel.com>,
	Jeevan B <jeevan.b@intel.com>
Subject: [i-g-t V6 2/6] tests/kms: Drop redundant check for pipe/output combo validity
Date: Tue, 18 Jun 2024 11:51:46 +0530	[thread overview]
Message-ID: <20240618062150.4004768-3-bhanuprakash.modem@intel.com> (raw)
In-Reply-To: <20240618062150.4004768-1-bhanuprakash.modem@intel.com>

As intel_pipe_output_combo_valid() is taking care of pipe/output
combo validity, drop other redundant checks.

Signed-off-by: Bhanuprakash Modem <bhanuprakash.modem@intel.com>
Reviewed-by: Jeevan B <jeevan.b@intel.com>
---
 tests/kms_content_protection.c |  3 ---
 tests/kms_properties.c         |  3 ---
 tests/kms_vrr.c                | 22 ++++++++++------------
 3 files changed, 10 insertions(+), 18 deletions(-)

diff --git a/tests/kms_content_protection.c b/tests/kms_content_protection.c
index 6858b22e2..e9a468eb0 100644
--- a/tests/kms_content_protection.c
+++ b/tests/kms_content_protection.c
@@ -564,9 +564,6 @@ test_content_protection(enum igt_commit_style s, int content_type)
 
 	for_each_connected_output(display, output) {
 		for_each_pipe(display, pipe) {
-			if (!igt_pipe_connector_valid(pipe, output))
-				continue;
-
 			igt_display_reset(display);
 
 			igt_output_set_pipe(output, pipe);
diff --git a/tests/kms_properties.c b/tests/kms_properties.c
index bd414f534..6f92b218e 100644
--- a/tests/kms_properties.c
+++ b/tests/kms_properties.c
@@ -337,9 +337,6 @@ static void connector_properties(igt_display_t *display, bool atomic)
 		bool found = false;
 
 		for_each_pipe(display, pipe) {
-			if (!igt_pipe_connector_valid(pipe, output))
-				continue;
-
 			igt_display_reset(display);
 
 			igt_output_set_pipe(output, pipe);
diff --git a/tests/kms_vrr.c b/tests/kms_vrr.c
index 7f64d6806..5af220b5b 100644
--- a/tests/kms_vrr.c
+++ b/tests/kms_vrr.c
@@ -794,22 +794,20 @@ run_vrr_test(data_t *data, test_t test, uint32_t flags)
 			continue;
 
 		for_each_pipe(&data->display, pipe) {
-			if (igt_pipe_connector_valid(pipe, output)) {
-				igt_output_set_pipe(output, pipe);
+			igt_output_set_pipe(output, pipe);
 
-				if (!intel_pipe_output_combo_valid(&data->display)) {
-					igt_output_set_pipe(output, PIPE_NONE);
-					continue;
-				}
+			if (!intel_pipe_output_combo_valid(&data->display)) {
+				igt_output_set_pipe(output, PIPE_NONE);
+				continue;
+			}
 
-				igt_dynamic_f("pipe-%s-%s",
-					      kmstest_pipe_name(pipe), output->name)
-					test(data, pipe, output, flags);
+			igt_dynamic_f("pipe-%s-%s",
+				      kmstest_pipe_name(pipe), output->name)
+				test(data, pipe, output, flags);
 
-				test_cleanup(data, pipe, output);
+			test_cleanup(data, pipe, output);
 
-				break;
-			}
+			break;
 		}
 	}
 }
-- 
2.43.2


  parent reply	other threads:[~2024-06-18  6:29 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-06-18  6:21 [i-g-t V6 0/6] Force joiner support in bigjoiner checks Bhanuprakash Modem
2024-06-18  6:21 ` [i-g-t V6 1/6] lib/igt_kms: Check validity of the selcted pipe/output combo Bhanuprakash Modem
2024-06-18  6:21 ` Bhanuprakash Modem [this message]
2024-06-18  6:21 ` [i-g-t V6 3/6] tests/chamelium: Use lib helper to check the pipe/output combo validity Bhanuprakash Modem
2024-06-18  6:21 ` [i-g-t V6 4/6] tests/intel/kms: " Bhanuprakash Modem
2024-06-18  6:21 ` [i-g-t V6 5/6] tests/kms_dither: " Bhanuprakash Modem
2024-06-18  6:21 ` [i-g-t V6 6/6] tests/kms_hdr: " Bhanuprakash Modem
  -- strict thread matches above, loose matches on Subject: below --
2024-06-18  6:23 [i-g-t V6 0/6] Check the validity of selected pipe/output combo Bhanuprakash Modem
2024-06-18  6:24 ` [i-g-t V6 2/6] tests/kms: Drop redundant check for pipe/output combo validity Bhanuprakash Modem

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=20240618062150.4004768-3-bhanuprakash.modem@intel.com \
    --to=bhanuprakash.modem@intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    --cc=jeevan.b@intel.com \
    /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