From: Santhosh Reddy Guddati <santhosh.reddy.guddati@intel.com>
To: igt-dev@lists.freedesktop.org
Cc: swati2.sharma@intel.com, karthik.b.s@intel.com,
ankit.k.nautiyal@intel.com,
Santhosh Reddy Guddati <santhosh.reddy.guddati@intel.com>
Subject: [PATCH i-g-t v1] tests/intel/kms_joiner: vblank test for joiner secondary crtc
Date: Thu, 13 Aug 2026 13:24:09 +0530 [thread overview]
Message-ID: <20260813075409.57087-1-santhosh.reddy.guddati@intel.com> (raw)
In joiner mode, add new subtests to validate vblank events are delivered
on secondary crtc.
Assisted-by: Claude:claude-opus-4-8
Signed-off-by: Santhosh Reddy Guddati <santhosh.reddy.guddati@intel.com>
---
tests/intel/kms_joiner.c | 94 ++++++++++++++++++++++++++++++++++++++++
1 file changed, 94 insertions(+)
diff --git a/tests/intel/kms_joiner.c b/tests/intel/kms_joiner.c
index dfcb24004..ff33256a3 100644
--- a/tests/intel/kms_joiner.c
+++ b/tests/intel/kms_joiner.c
@@ -76,6 +76,10 @@
* SUBTEST: basic-max-non-joiner
* Description: Validate basic max non-joiner modeset by selecting the max mode
* supported on single pipe.
+ *
+ * SUBTEST: vblank-joiner-secondary
+ * Description: Verify that vblank interrupts are generated on all pipes in a
+ * joiner configuration including the secondary pipe.
*/
IGT_TEST_DESCRIPTION("Test joiner / force joiner");
@@ -275,6 +279,74 @@ static void switch_modeset_ultra_joiner_big_joiner(data_t *data, igt_output_t *o
}
}
+static void test_joiner_vblank(data_t *data, bool force_joiner)
+{
+ int i;
+ enum pipe pipe, master_pipe;
+ uint32_t available_pipe_mask = BIT(data->n_pipes) - 1;
+ igt_output_t *output;
+ igt_plane_t *primary;
+ igt_output_t **outputs;
+ igt_fb_t fb;
+ drmModeModeInfo *mode;
+ int count;
+ drmVBlank wait_vbl;
+ uint32_t pipe_flag;
+
+ outputs = force_joiner ? data->non_big_joiner_output : data->big_joiner_output;
+ count = force_joiner ? data->non_big_joiner_output_count : data->big_joiner_output_count;
+ igt_display_reset(&data->display);
+ igt_display_commit2(&data->display, COMMIT_ATOMIC);
+
+ for (i = 0; i < count; i++) {
+ output = outputs[i];
+ for (pipe = 0; pipe < data->n_pipes - 1; pipe++) {
+ igt_crtc_t *primary_crtc, *secondary_crtc;
+ int ret;
+
+ master_pipe = setup_pipe(data, output, pipe, available_pipe_mask);
+ if (master_pipe == PIPE_NONE)
+ continue;
+
+ mode = igt_output_get_mode(output);
+ primary = igt_output_get_plane_type(output, DRM_PLANE_TYPE_PRIMARY);
+ igt_create_pattern_fb(data->drm_fd, mode->hdisplay, mode->vdisplay,
+ DRM_FORMAT_XRGB8888,
+ DRM_FORMAT_MOD_LINEAR, &fb);
+ igt_plane_set_fb(primary, &fb);
+ igt_display_commit2(&data->display, COMMIT_ATOMIC);
+
+ primary_crtc = igt_crtc_for_pipe(&data->display, master_pipe);
+ secondary_crtc = igt_crtc_for_pipe(&data->display, master_pipe + 1);
+
+ /* Verify vblank works on the primary joiner pipe */
+ igt_wait_for_vblank(primary_crtc);
+ igt_info("Pipe %s (primary): vblank wait OK\n",
+ kmstest_pipe_name(master_pipe));
+
+ /* Verify vblank works on the secondary joiner pipe */
+ pipe_flag = kmstest_get_vbl_flag(secondary_crtc->crtc_index);
+ memset(&wait_vbl, 0, sizeof(wait_vbl));
+
+ wait_vbl.request.type = DRM_VBLANK_RELATIVE | pipe_flag;
+ wait_vbl.request.sequence = 1;
+ ret = drmWaitVBlank(data->drm_fd, &wait_vbl);
+
+ igt_assert_f(ret == 0,
+ "Pipe %s (joiner secondary): vblank wait timed out - "
+ "no vblank interrupt delivered\n",
+ kmstest_pipe_name(master_pipe + 1));
+ igt_info("Pipe %s (secondary): vblank wait OK\n",
+ kmstest_pipe_name(master_pipe + 1));
+
+ igt_plane_set_fb(primary, NULL);
+ igt_output_set_crtc(output, NULL);
+ igt_display_commit2(&data->display, COMMIT_ATOMIC);
+ igt_remove_fb(data->drm_fd, &fb);
+ }
+ }
+}
+
static void test_single_joiner(data_t *data, int output_count, bool force_joiner)
{
int i;
@@ -836,6 +908,28 @@ int igt_main()
test_basic_max_non_joiner(&data);
}
+ igt_describe("Verify vblank interrupts arrive on joiner secondary pipes");
+ igt_subtest_with_dynamic("vblank-joiner-secondary") {
+ igt_require_f(data.n_pipes >= 2, "Minimum 2 pipes required\n");
+ igt_require_f(data.big_joiner_output_count > 0 ||
+ data.non_big_joiner_output_count > 0,
+ "No big joiner or force big joiner output found\n");
+
+ if (data.big_joiner_output_count > 0) {
+ igt_dynamic_f("big-joiner") {
+ test_joiner_vblank(&data, false);
+ }
+ }
+
+ if (data.non_big_joiner_output_count > 0) {
+ igt_dynamic_f("force-big-joiner") {
+ enable_force_joiner_on_all_non_big_joiner_outputs(&data);
+ test_joiner_vblank(&data, true);
+ igt_reset_connectors();
+ }
+ }
+ }
+
igt_fixture() {
igt_display_fini(&data.display);
drm_close_driver(data.drm_fd);
--
2.43.0
next reply other threads:[~2026-08-13 7:57 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-13 7:54 Santhosh Reddy Guddati [this message]
2026-08-13 10:47 ` ✓ i915.CI.BAT: success for tests/intel/kms_joiner: vblank test for joiner secondary crtc Patchwork
2026-08-13 10:49 ` ✓ Xe.CI.BAT: " Patchwork
2026-08-13 12:14 ` ✓ Xe.CI.FULL: " Patchwork
2026-08-13 14:33 ` ✗ i915.CI.Full: failure " Patchwork
2026-08-14 5:03 ` [PATCH i-g-t v1] " Karthik B S
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=20260813075409.57087-1-santhosh.reddy.guddati@intel.com \
--to=santhosh.reddy.guddati@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