public inbox for igt-dev@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Karthik B S <karthik.b.s@intel.com>
To: igt-dev@lists.freedesktop.org
Cc: petri.latvala@intel.com
Subject: [igt-dev] [PATCH i-g-t] tests/kms_multipipe_modeset: Changes based on lib updates and minor fixes
Date: Tue, 28 Jul 2020 18:47:32 +0530	[thread overview]
Message-ID: <20200728131732.27299-1-karthik.b.s@intel.com> (raw)

-Due to changes in igt lib, the igt_display_get_n_pipes() function now
 returns IGT_MAX_PIPES as opposed to the maximum pipes supported by a
 given platform which it was returning before. Made changes in the test
 to accommodate this.

-Removed the redundant kms_unset_all_crtcs, which also speeds up the test.

-Added freeing of resources which was missing.

Signed-off-by: Karthik B S <karthik.b.s@intel.com>
---
 tests/kms_multipipe_modeset.c | 13 ++++++-------
 1 file changed, 6 insertions(+), 7 deletions(-)

diff --git a/tests/kms_multipipe_modeset.c b/tests/kms_multipipe_modeset.c
index fb0b9662..b06c4e82 100644
--- a/tests/kms_multipipe_modeset.c
+++ b/tests/kms_multipipe_modeset.c
@@ -112,12 +112,11 @@ static void run_test(data_t *data, int valid_outputs)
 	igt_remove_fb(data->drm_fd, &data->fb);
 }
 
-static void test_multipipe(data_t *data)
+static void test_multipipe(data_t *data, int num_pipes)
 {
 	igt_output_t *output;
-	int valid_outputs = 0, num_pipes;
+	int valid_outputs = 0;
 
-	num_pipes = igt_display_get_n_pipes(&data->display);
 	for_each_connected_output(&data->display, output)
 		valid_outputs++;
 
@@ -142,15 +141,15 @@ igt_main
 
 		res = drmModeGetResources(data.drm_fd);
 		igt_assert(res);
-
-		kmstest_unset_all_crtcs(data.drm_fd, res);
 	}
 
 	igt_describe("Verify if simultaneous modesets on all the supported "
 		     "pipes is successful. Validate using CRC verification");
 	igt_subtest("basic-max-pipe-crc-check")
-		test_multipipe(&data);
+		test_multipipe(&data, res->count_crtcs);
 
-	igt_fixture
+	igt_fixture {
+		drmModeFreeResources(res);
 		igt_display_fini(&data.display);
+	}
 }
-- 
2.22.0

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

             reply	other threads:[~2020-07-28 13:40 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-28 13:17 Karthik B S [this message]
2020-07-28 14:05 ` [igt-dev] ✓ Fi.CI.BAT: success for tests/kms_multipipe_modeset: Changes based on lib updates and minor fixes Patchwork
2020-07-28 20:18 ` [igt-dev] ✗ Fi.CI.IGT: failure " Patchwork
     [not found]   ` <516cc07042dd4249b4a9f25486e6217c@intel.com>
2020-08-05  5:14     ` Joshi, Kunal1
2020-07-31 10:28 ` [igt-dev] [PATCH i-g-t] " Nautiyal, Ankit K
2020-07-31 10:47 ` [igt-dev] ✗ Fi.CI.BUILD: failure for tests/kms_multipipe_modeset: Changes based on lib updates and minor fixes (rev2) Patchwork
2020-07-31 10:54 ` [igt-dev] [PATCH i-g-t] tests/kms_multipipe_modeset: Changes based on lib updates and minor fixes Nautiyal, Ankit K

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=20200728131732.27299-1-karthik.b.s@intel.com \
    --to=karthik.b.s@intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    --cc=petri.latvala@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