From: Bhanuprakash Modem <bhanuprakash.modem@intel.com>
To: igt-dev@lists.freedesktop.org, ankit.k.nautiyal@intel.com,
swati2.sharma@intel.com, karthik.b.s@intel.com
Subject: [igt-dev] [i-g-t 4/5] tests/kms_flip: Fix Bigjoiner checks
Date: Wed, 17 May 2023 10:54:33 +0530 [thread overview]
Message-ID: <20230517052434.4097572-5-bhanuprakash.modem@intel.com> (raw)
In-Reply-To: <20230517052434.4097572-1-bhanuprakash.modem@intel.com>
Bigjoiner will come in the picture when the resolution > 5K or
clock > max dot-clock. Add a support to check the selected mode
clock is greater than the max dot-clock.
V2: - Limit the bigjoiner checks to intel hardware
Signed-off-by: Bhanuprakash Modem <bhanuprakash.modem@intel.com>
Reviewed-by: Ankit Nautiyal <ankit.k.nautiyal@intel.com>
---
tests/kms_flip.c | 18 +++++++++++-------
1 file changed, 11 insertions(+), 7 deletions(-)
diff --git a/tests/kms_flip.c b/tests/kms_flip.c
index f1e0700c1..3b181d4fa 100755
--- a/tests/kms_flip.c
+++ b/tests/kms_flip.c
@@ -87,8 +87,6 @@
#define RUN_TEST 1
#define RUN_PAIR 2
-#define MAX_HDISPLAY_PER_CRTC 5120
-
#ifndef DRM_CAP_TIMESTAMP_MONOTONIC
#define DRM_CAP_TIMESTAMP_MONOTONIC 6
#endif
@@ -102,6 +100,7 @@ uint32_t devid;
int test_time = 3;
static bool monotonic_timestamp;
static pthread_t vblank_wait_thread;
+static int max_dotclock;
static drmModeConnector *last_connector;
@@ -1535,21 +1534,24 @@ static void run_test_on_crtc_set(struct test_output *o, int *crtc_idxs,
igt_assert_eq(o->count, crtc_count);
/*
- * Handle BW limitations:
+ * Handle BW limitations on intel hardware:
*
- * if mode.hdisplay > 5120, then ignore
+ * if mode resolution > 5K (or) mode clock > max_dotclock, then ignore
* - last crtc in single/multi-connector config
* - consecutive crtcs in multi-connector config
*
* in multi-connector config ignore if
- * - previous crtc mode.hdisplay > 5120 and
+ * - previous crtc (mode resolution > 5K or mode clock > max_dotclock) and
* - current & previous crtcs are consecutive
*/
+ if (!is_intel_device(drm_fd))
+ goto test;
+
for (i = 0; i < crtc_count; i++) {
- if (((o->kmode[i].hdisplay > MAX_HDISPLAY_PER_CRTC) &&
+ if ((igt_bigjoiner_possible(&o->kmode[i], max_dotclock) &&
((crtc_idxs[i] >= (total_crtcs - 1)) ||
((i < (crtc_count - 1)) && (abs(crtc_idxs[i + 1] - crtc_idxs[i]) <= 1)))) ||
- ((i > 0) && (o->kmode[i - 1].hdisplay > MAX_HDISPLAY_PER_CRTC) &&
+ ((i > 0) && igt_bigjoiner_possible(&o->kmode[i - 1], max_dotclock) &&
(abs(crtc_idxs[i] - crtc_idxs[i - 1]) <= 1))) {
igt_debug("Combo: %s is not possible with selected mode(s).\n", test_name);
@@ -1557,6 +1559,7 @@ static void run_test_on_crtc_set(struct test_output *o, int *crtc_idxs,
}
}
+test:
igt_dynamic_f("%s", test_name)
__run_test_on_crtc_set(o, crtc_idxs, crtc_count, duration_ms);
}
@@ -1870,6 +1873,7 @@ igt_main_args("e", NULL, help_str, opt_handler, NULL)
for (i = 0; i < sizeof(tests) / sizeof(tests[0]); i++)
tests[i].flags &= ~(TEST_CHECK_TS | TEST_VBLANK_EXPIRED_SEQ);
}
+ max_dotclock = igt_get_max_dotclock(drm_fd);
}
igt_describe("Tests that nonblocking reading fails correctly");
--
2.40.0
next prev parent reply other threads:[~2023-05-17 5:30 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-05-17 5:24 [igt-dev] [i-g-t 0/5] Fix Bigjoiner checks Bhanuprakash Modem
2023-05-17 5:24 ` [igt-dev] [i-g-t 1/5] tests: s/i915_pipe_output_combo_valid/intel_pipe_output_combo_valid/ Bhanuprakash Modem
2023-05-17 5:24 ` [igt-dev] [i-g-t 2/5] lib/igt_kms: s/is_i915_device/is_intel_device Bhanuprakash Modem
2023-05-17 5:24 ` [igt-dev] [i-g-t 3/5] tests/i915/kms_big_joiner: Fix Bigjoiner checks Bhanuprakash Modem
2023-05-17 5:24 ` Bhanuprakash Modem [this message]
2023-05-17 5:24 ` [igt-dev] [i-g-t 5/5] tests/kms_setmode: " Bhanuprakash Modem
2023-05-17 6:18 ` [igt-dev] ✓ Fi.CI.BAT: success for Fix Bigjoiner checks (rev7) Patchwork
2023-05-17 15:25 ` [igt-dev] ✗ Fi.CI.IGT: failure " Patchwork
-- strict thread matches above, loose matches on Subject: below --
2023-11-13 8:19 [igt-dev] [i-g-t 0/5] Fix Bigjoiner checks Bhanuprakash Modem
2023-11-13 8:19 ` [igt-dev] [i-g-t 4/5] tests/kms_flip: " Bhanuprakash Modem
2023-11-15 8:34 ` Ville Syrjälä
2023-11-15 8:47 ` Saarinen, Jani
2023-11-15 8:55 ` Saarinen, Jani
2023-11-15 9:01 ` Saarinen, Jani
2023-11-15 9:20 ` Modem, Bhanuprakash
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=20230517052434.4097572-5-bhanuprakash.modem@intel.com \
--to=bhanuprakash.modem@intel.com \
--cc=ankit.k.nautiyal@intel.com \
--cc=igt-dev@lists.freedesktop.org \
--cc=karthik.b.s@intel.com \
--cc=swati2.sharma@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