From: Karthik B S <karthik.b.s@intel.com>
To: Jeevan B <jeevan.b@intel.com>, <igt-dev@lists.freedesktop.org>
Subject: Re: [PATCH i-g-t 3/3] tests/intel/kms_joiner: Add a new test to validate non-joiner mode
Date: Wed, 12 Feb 2025 16:20:45 +0530 [thread overview]
Message-ID: <ba867e47-6f54-4c6e-8ea9-20dce5f58a89@intel.com> (raw)
In-Reply-To: <20250212073604.1580120-4-jeevan.b@intel.com>
Hi,
Please mention 'max-non-joiner mode' in subtest.
With this update,
Reviewed-by: Karthik B S <karthik.b.s@intel.com>
On 2/12/2025 1:06 PM, Jeevan B wrote:
> We need to ensure that the system does not enable a joiner for modes
> that do not require it. This test runs on all pipes and validates
> that the highest available resolution and refresh rate within the
> max dot clock limit is selected. The test then forces a modeset and
> flip on the given pipe and checks the status using the joiner check.
> If the joiner is mistakenly enabled for a non-joiner mode, the test
> should fail.
>
> v2: Fix nonjoiner_mode_found to find the required case.
> Remove clk sort and minor fixes.
> v3: Rename nonjoiner to non_joiner and minor modifications.
> v4: Add joiner check.
> v5: Rename test name and function name, Update test description,
> update non_joiner_mode_found logic.
> v6: Update commit message and rename test, function name.
> v7: Fix mode selection, loop through all pipes instead on
> pipe - 1, update igt description and add igt info to display
> the selected mode.
>
> Signed-off-by: Jeevan B <jeevan.b@intel.com>
> ---
> tests/intel/kms_joiner.c | 65 ++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 65 insertions(+)
>
> diff --git a/tests/intel/kms_joiner.c b/tests/intel/kms_joiner.c
> index 086cfeb71..062a0e49d 100644
> --- a/tests/intel/kms_joiner.c
> +++ b/tests/intel/kms_joiner.c
> @@ -74,6 +74,10 @@
> *
> * SUBTEST: switch-modeset-ultra-joiner-big-joiner
> * Description: Verify switching between ultra joiner and big joiner modeset.
> + *
> + * SUBTEST: basic-max-non-joiner
> + * Description: Validate basic max non-joiner modeset by selecting the max mode
> + * supported on single pipe.
> */
> IGT_TEST_DESCRIPTION("Test joiner / force joiner");
>
> @@ -85,6 +89,7 @@ typedef struct {
> int ultra_joiner_output_count;
> int non_big_joiner_output_count;
> int non_ultra_joiner_output_count;
> + int non_joiner_output_count;
> int mixed_output_count;
> int output_count;
> int n_pipes;
> @@ -94,6 +99,7 @@ typedef struct {
> igt_output_t *non_big_joiner_output[IGT_MAX_PIPES];
> igt_output_t *non_ultra_joiner_output[IGT_MAX_PIPES];
> igt_output_t *mixed_output[IGT_MAX_PIPES];
> + igt_output_t *non_joiner_output[IGT_MAX_PIPES];
> enum pipe pipe_seq[IGT_MAX_PIPES];
> igt_display_t display;
> } data_t;
> @@ -491,6 +497,48 @@ static void test_ultra_joiner(data_t *data, bool invalid_pipe, bool two_display,
> }
> }
>
> +static void test_basic_max_non_joiner(data_t *data)
> +{
> + int count;
> + enum pipe pipe;
> + igt_output_t **outputs, *output;
> + igt_fb_t fb;
> + igt_plane_t *primary;
> + drmModeModeInfo mode;
> +
> + count = data->non_joiner_output_count;
> + outputs = data->non_joiner_output;
> + igt_display_reset(&data->display);
> +
> + for (int i = 0; i < count; i++) {
> + output = outputs[i];
> +
> + for (pipe = 0; pipe < data->n_pipes; pipe++) {
> + igt_dynamic_f("pipe-%s-%s", kmstest_pipe_name(pipe), output->name) {
> + igt_output_set_pipe(output, pipe);
> + igt_require(max_non_joiner_mode_found(data->drm_fd,
> + output->config.connector,
> + max_dotclock, &mode));
> + igt_output_override_mode(output, &mode);
> + igt_info("Appplying mode = %dx%d@%d\n", mode.hdisplay,
> + mode.vdisplay, mode.vrefresh);
> + 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);
> + igt_assert_f(!igt_is_joiner_enabled_for_pipe(data->drm_fd, pipe),
> + "Joiner enabled on pipe %c", 'A' + pipe);
> +
> + igt_display_reset(&data->display);
> + igt_plane_set_fb(primary, NULL);
> + igt_remove_fb(data->drm_fd, &fb);
> + }
> + }
> + }
> +}
> +
> igt_main
> {
> bool ultra_joiner_supported, is_dgfx;
> @@ -505,6 +553,7 @@ igt_main
> data.ultra_joiner_output_count = 0;
> data.non_big_joiner_output_count = 0;
> data.non_ultra_joiner_output_count = 0;
> + data.non_joiner_output_count = 0;
> data.mixed_output_count = 0;
> data.output_count = 0;
> j = 0;
> @@ -523,6 +572,7 @@ igt_main
>
> for_each_connected_output(&data.display, output) {
> bool ultrajoiner_found = false, bigjoiner_found = false, force_joiner_supported = false;
> + bool non_joiner_found = false;
> drmModeConnector *connector = output->config.connector;
>
> /*
> @@ -533,6 +583,8 @@ igt_main
> */
> bigjoiner_found = bigjoiner_mode_found(data.drm_fd, connector, max_dotclock, &mode);
> ultrajoiner_found = ultrajoiner_mode_found(data.drm_fd, connector, max_dotclock, &mode);
> + non_joiner_found = max_non_joiner_mode_found(data.drm_fd, connector,
> + max_dotclock, &mode);
>
> if (igt_has_force_joiner_debugfs(data.drm_fd, output->name))
> force_joiner_supported = true;
> @@ -548,6 +600,9 @@ igt_main
> else if (force_joiner_supported)
> data.non_big_joiner_output[data.non_big_joiner_output_count++] = output;
>
> + if (non_joiner_found)
> + data.non_joiner_output[data.non_joiner_output_count++] = output;
> +
> data.output_count++;
> }
> if (data.big_joiner_output_count == 1 && data.non_big_joiner_output_count >= 1) {
> @@ -713,6 +768,16 @@ igt_main
> }
> }
>
> + igt_describe("Verify the basic modeset on the maximum non-joiner mode across "
> + "all pipes");
> + igt_subtest_with_dynamic("basic-max-non-joiner") {
> + igt_require_f(data.n_pipes >= 1,
> + "At least one pipe is required.\n");
> + igt_require_f(data.non_joiner_output_count > 0,
> + "No suitable non-joiner mode found\n");
> + test_basic_max_non_joiner(&data);
> + }
> +
> igt_fixture {
> igt_display_fini(&data.display);
> drm_close_driver(data.drm_fd);
next prev parent reply other threads:[~2025-02-12 10:51 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-02-12 7:36 [PATCH i-g-t 0/3] tests/intel/kms_joiner: Add a new test to validate non-joiner mode Jeevan B
2025-02-12 7:21 ` B, Jeevan
2025-02-12 7:36 ` [PATCH i-g-t 1/3] lib/igt_kms: Add lib changes to check if joiner is enabled for a pipe Jeevan B
2025-02-12 10:42 ` Karthik B S
2025-02-12 7:36 ` [PATCH i-g-t 2/3] lib/igt_kms: Add support to check joiner mode limit Jeevan B
2025-02-12 10:46 ` Karthik B S
2025-02-12 7:36 ` [PATCH i-g-t 3/3] tests/intel/kms_joiner: Add a new test to validate non-joiner mode Jeevan B
2025-02-12 10:50 ` Karthik B S [this message]
2025-02-12 8:15 ` ✓ Xe.CI.BAT: success for tests/intel/kms_joiner: Add a new test to validate non-joiner mode (rev7) Patchwork
2025-02-12 8:32 ` ✓ i915.CI.BAT: " Patchwork
2025-02-12 10:17 ` ✗ i915.CI.Full: failure " Patchwork
2025-02-12 14:11 ` B, Jeevan
2025-02-12 10:20 ` ✗ Xe.CI.Full: " Patchwork
2025-02-12 14:11 ` B, Jeevan
-- strict thread matches above, loose matches on Subject: below --
2025-02-10 18:36 [PATCH i-g-t 0/3] tests/intel/kms_joiner: Add a new test to validate non-joiner mode Jeevan B
2025-02-10 18:36 ` [PATCH i-g-t 3/3] " Jeevan B
2025-02-04 18:27 [PATCH i-g-t 0/3] " Jeevan B
2025-02-04 18:27 ` [PATCH i-g-t 3/3] " Jeevan B
2025-02-07 8:25 ` 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=ba867e47-6f54-4c6e-8ea9-20dce5f58a89@intel.com \
--to=karthik.b.s@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