From: Mohammed Thasleem <mohammed.thasleem@intel.com>
To: igt-dev@lists.freedesktop.org
Cc: uma.shankar@intel.com, Mohammed Thasleem <mohammed.thasleem@intel.com>
Subject: [PATCH i-g-t] tests/intel/kms_pm_dc: Add DC5 negative test for continuous page-flip activity
Date: Mon, 8 Jun 2026 13:00:19 +0530 [thread overview]
Message-ID: <20260608073019.9011-1-mohammed.thasleem@intel.com> (raw)
In-Reply-To: <20260316111517.24452-1-mohammed.thasleem@intel.com>
This test validates that DC5 entry should not occur when the display engine
is kept continuously busy with back-to-back page-flips. The test performs
a tight flip loop for 10 seconds, alternating between two fb's with no
delays between flips.
It monitors the DC5 counter to ensure no state transitions occur during
active display operations, validating proper power management behavior.
v2: Update test description and test name. (Uma)
Update test assert message and minor changes. (Uma)
Signed-off-by: Mohammed Thasleem <mohammed.thasleem@intel.com>
---
tests/intel/kms_pm_dc.c | 58 +++++++++++++++++++++++++++++++++++++++++
1 file changed, 58 insertions(+)
diff --git a/tests/intel/kms_pm_dc.c b/tests/intel/kms_pm_dc.c
index 423a5c4a4..90df8ee37 100644
--- a/tests/intel/kms_pm_dc.c
+++ b/tests/intel/kms_pm_dc.c
@@ -77,6 +77,9 @@
*
* SUBTEST: dc5-retention-flops
* Description: This test validates display engine entry to DC5 state while PSR is active on Pipe B
+ *
+ * SUBTEST: dc5-pageflip-negative
+ * Description: This test validates that DC5 entry should not occur during continuous page-flips
*/
#define PWR_DOMAIN_INFO "i915_power_domain_info"
@@ -622,6 +625,49 @@ static void test_deep_pkgc_state(data_t *data)
igt_assert_f(pkgc_flag, "PKGC10 is not achieved.\n");
}
+static void test_dc5_pageflip_negative(data_t *data, int dc_flag)
+{
+ igt_plane_t *primary;
+ uint32_t dc5_prev_counter;
+ time_t duration = 10;
+ bool flip = false;
+ time_t start;
+
+ igt_require_dc_counter(data->debugfs_fd, dc_flag);
+
+ setup_output(data);
+ setup_videoplayback(data);
+
+ primary = igt_output_get_plane_type(data->output,
+ DRM_PLANE_TYPE_PRIMARY);
+
+ igt_plane_set_fb(primary, &data->fb_rgb);
+ igt_display_commit(&data->display);
+
+ dc5_prev_counter = igt_read_dc_counter(data->debugfs_fd, dc_flag);
+
+ /*
+ * Page-flip loop for 10 seconds.
+ * No delay in between flips - here display engine remains continuously busy.
+ */
+ start = time(NULL);
+ while (time(NULL) - start < duration) {
+ flip = !flip;
+
+ igt_plane_set_fb(primary,
+ flip ? &data->fb_rgb : &data->fb_rgr);
+
+ igt_display_commit(&data->display);
+ }
+
+ igt_assert_f(igt_read_dc_counter(data->debugfs_fd, dc_flag) == dc5_prev_counter,
+ "DC5 state incorrectly entered during continuous page-flips\n%s:\n%s\n",
+ PWR_DOMAIN_INFO, data->debugfs_dump = igt_sysfs_get(data->debugfs_fd,
+ PWR_DOMAIN_INFO));
+
+ cleanup_dc3co_fbs(data);
+}
+
static void kms_poll_state_restore(int sig)
{
int sysfs_fd;
@@ -717,6 +763,18 @@ int igt_main()
test_dc5_retention_flops(&data, IGT_INTEL_CHECK_DC5);
}
+ igt_describe("This test validates that DC5 entry should not occur during "
+ "continuous page-flips");
+ igt_subtest("dc5-pageflip-negative") {
+ igt_require(psr_sink_support(data.drm_fd, data.debugfs_fd,
+ PSR_MODE_1, NULL));
+ data.op_psr_mode = PSR_MODE_1;
+ psr_enable(data.drm_fd, data.debugfs_fd, data.op_psr_mode, NULL);
+ igt_require(!psr_disabled_check(data.debugfs_fd));
+ test_dc5_pageflip_negative(&data, IGT_INTEL_CHECK_DC5);
+ psr_disable(data.drm_fd, data.debugfs_fd, NULL);
+ }
+
igt_describe("This test validates negative scenario of DC5 display "
"engine entry to DC5 state while all connectors's DPMS "
"property set to ON");
--
2.43.0
next prev parent reply other threads:[~2026-06-08 7:40 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-16 11:15 [PATCH i-g-t] tests/intel/kms_pm_dc: Add DC5 negative test for continuous page-flip activity Mohammed Thasleem
2026-03-17 5:30 ` ✓ Xe.CI.BAT: success for " Patchwork
2026-03-17 11:19 ` ✓ i915.CI.BAT: " Patchwork
2026-03-18 10:29 ` ✓ Xe.CI.FULL: " Patchwork
2026-06-05 9:42 ` [PATCH i-g-t] " Shankar, Uma
2026-06-08 7:30 ` Mohammed Thasleem [this message]
2026-06-08 10:34 ` Shankar, Uma
2026-06-08 22:33 ` ✓ Xe.CI.BAT: success for tests/intel/kms_pm_dc: Add DC5 negative test for continuous page-flip activity (rev2) Patchwork
2026-06-08 22:46 ` ✓ i915.CI.BAT: " Patchwork
2026-06-09 1:05 ` ✗ Xe.CI.FULL: failure " Patchwork
2026-06-09 5:56 ` ✗ i915.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=20260608073019.9011-1-mohammed.thasleem@intel.com \
--to=mohammed.thasleem@intel.com \
--cc=igt-dev@lists.freedesktop.org \
--cc=uma.shankar@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