From: "Thasleem, Mohammed" <mohammed.thasleem@intel.com>
To: "Michał Grzelak" <michal.grzelak@intel.com>,
igt-dev@lists.freedesktop.org
Subject: Re: [PATCH i-g-t v8 3/6] tests/kms_flip: limit output pairs when testing suspend
Date: Sat, 14 Mar 2026 20:21:26 +0530 [thread overview]
Message-ID: <d28a60bd-29ad-4513-84c4-bbcc2c58898a@intel.com> (raw)
In-Reply-To: <20260309092528.3336467-4-michal.grzelak@intel.com>
On 09-03-2026 02:55 pm, Michał Grzelak wrote:
> Currently 2x- subtests can still exceed timeout, even with limited
> number of pipes used. It can be seen when number of outputs is greater
> than 3.
>
> Default to testing at max 3 pairs of outputs. Add a commandline
> parameter enabling suspend testing on all possible output pairs. Add a
> LIMIT_PAIR macro which controls maximum number of output pairs to test.
>
> Signed-off-by: Michał Grzelak <michal.grzelak@intel.com>
LGTM:
Reviewed-by: Mohammed Thasleem <mohammed.thasleem@intel.com>
> ---
> tests/kms_flip.c | 32 ++++++++++++++++++++++++++------
> 1 file changed, 26 insertions(+), 6 deletions(-)
>
> diff --git a/tests/kms_flip.c b/tests/kms_flip.c
> index d09813f02..917c5ed6f 100755
> --- a/tests/kms_flip.c
> +++ b/tests/kms_flip.c
> @@ -263,11 +263,14 @@
> #define RUN_TEST 1
> #define RUN_PAIR 2
>
> +#define PAIR_LIMIT 3
> +
> #ifndef DRM_CAP_TIMESTAMP_MONOTONIC
> #define DRM_CAP_TIMESTAMP_MONOTONIC 6
> #endif
>
> static bool all_crtcs = false;
> +static bool all_pairs = false;
>
> drmModeRes *resources;
> int drm_fd;
> @@ -1904,6 +1907,7 @@ static void run_pair(int duration, int flags)
> {
> struct test_output o;
> int i, j, m, n, modes = 0;
> + int pair_count = 0;
>
> /* No tiling support in XE. */
> if (is_xe_device(drm_fd) && flags & TEST_FENCE_STRESS)
> @@ -1966,6 +1970,16 @@ static void run_pair(int duration, int flags)
> for (m = n + 1; m < resources->count_crtcs; m++) {
> int crtc_idxs[2];
>
> + /* Limit the execution to 2 CRTCs (first & last) for hang and suspend tests */
> + if (((flags & TEST_HANG) || (flags & TEST_SUSPEND)) && !all_crtcs &&
> + ((n != 0 && n != resources->count_crtcs) ||
> + m != resources->count_crtcs - 1))
> + continue;
> +
> + /* Limit number of suspend tests */
> + if ((flags & TEST_SUSPEND) && !all_pairs && pair_count >= PAIR_LIMIT)
> + continue;
> +
> memset(&o, 0, sizeof(o));
> o.count = 2;
> o._connector[0] = resources->connectors[i];
> @@ -1977,16 +1991,18 @@ static void run_pair(int duration, int flags)
> crtc_idxs[0] = n;
> crtc_idxs[1] = m;
>
> - /* Limit the execution to 2 CRTCs (first & last) for hang and suspend tests */
> - if (((flags & TEST_HANG) || (flags & TEST_SUSPEND)) && !all_crtcs &&
> - ((n != 0 && n != resources->count_crtcs) ||
> - m != resources->count_crtcs - 1))
> + connector_find_compatible_mode(n, m, &o);
> +
> + if (!o.mode_valid) {
> + free_test_output(&o);
> continue;
> + }
>
> run_test_on_crtc_set(&o, crtc_idxs,
> RUN_PAIR,
> resources->count_crtcs,
> duration);
> + pair_count++;
> }
> }
> }
> @@ -2044,6 +2060,9 @@ static int opt_handler(int opt, int opt_index, void *data)
> case 'e':
> all_crtcs = true;
> break;
> + case 'p':
> + all_pairs = true;
> + break;
> default:
> return IGT_OPT_HANDLER_ERROR;
> }
> @@ -2052,9 +2071,10 @@ static int opt_handler(int opt, int opt_index, void *data)
> }
>
> const char *help_str =
> - " -e \tRun on all CRTCs. (By default subtests will run on two CRTCs)\n";
> + " -e \tRun on all CRTCs. (By default subtests will run on two CRTCs)\n"
> + " -p \tRun on all output pairs. (By default 2x-* suspend subtests will run on 3 pairs)\n";
>
> -int igt_main_args("e", NULL, help_str, opt_handler, NULL)
> +int igt_main_args("ep", NULL, help_str, opt_handler, NULL)
> {
> struct {
> int duration;
next prev parent reply other threads:[~2026-03-14 14:51 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-09 9:25 [PATCH i-g-t v8 0/6] kms_flip: limit number of subtests run Michał Grzelak
2026-03-09 9:25 ` [PATCH i-g-t v8 1/6] tests/kms_flip: test suspend on one pair of pipes Michał Grzelak
2026-03-17 7:44 ` Thasleem, Mohammed
2026-03-09 9:25 ` [PATCH i-g-t v8 2/6] tests/kms_flip: run suspend tests on one pipe per output Michał Grzelak
2026-03-09 9:25 ` [PATCH i-g-t v8 3/6] tests/kms_flip: limit output pairs when testing suspend Michał Grzelak
2026-03-14 14:51 ` Thasleem, Mohammed [this message]
2026-03-09 9:25 ` [PATCH i-g-t v8 4/6] tests/kms_flip: limit number of outputs wrt suspend Michał Grzelak
2026-03-14 11:56 ` Thasleem, Mohammed
2026-03-25 23:39 ` Michał Grzelak
2026-03-09 9:25 ` [PATCH i-g-t v8 5/6] tests/kms_flip: staticize & remove unused global vars Michał Grzelak
2026-03-14 11:30 ` Thasleem, Mohammed
2026-03-09 9:25 ` [PATCH i-g-t v8 6/6] tests/kms_flip: test suspend at most twice on SNB && BMG Michał Grzelak
2026-03-25 10:30 ` Thasleem, Mohammed
2026-03-26 9:28 ` Michał Grzelak
2026-03-26 15:16 ` Thasleem, Mohammed
2026-03-09 14:14 ` ✓ Xe.CI.BAT: success for kms_flip: limit number of subtests run (rev10) Patchwork
2026-03-09 14:29 ` ✗ i915.CI.BAT: failure " Patchwork
2026-03-09 17:04 ` ✗ Xe.CI.FULL: " Patchwork
2026-03-10 20:53 ` ✓ Xe.CI.BAT: success for kms_flip: limit number of subtests run (rev11) Patchwork
2026-03-10 21:35 ` ✓ i915.CI.BAT: " Patchwork
2026-03-11 10:22 ` ✓ i915.CI.Full: " Patchwork
2026-03-11 15:06 ` ✓ Xe.CI.FULL: " 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=d28a60bd-29ad-4513-84c4-bbcc2c58898a@intel.com \
--to=mohammed.thasleem@intel.com \
--cc=igt-dev@lists.freedesktop.org \
--cc=michal.grzelak@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