public inbox for igt-dev@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Jonathan Cavitt <jonathan.cavitt@intel.com>
To: igt-dev@lists.freedesktop.org
Cc: saurabhg.gupta@intel.com, alex.zuo@intel.com, jonathan.cavitt@intel.com
Subject: [PATCH] tests/intel/kms: Drop unneeded igt_device_set_master calls
Date: Thu, 26 Feb 2026 23:10:37 +0000	[thread overview]
Message-ID: <20260226231036.83942-2-jonathan.cavitt@intel.com> (raw)

In kms_fbcon_fbt, igt_set_device_master is already called on the target
fd by drm_open_driver_master, so doing so again in the subtest function
is unnecessary.

In kms_pm_rpm, we call __drm_open_driver and igt_set_device_master while
asserting the return of the former is not -1.  This is already
accomplished by drm_open_driver_master, which also has additional guards
in place for i915, so just call that instead.

Signed-off-by: Jonathan Cavitt <jonathan.cavitt@intel.com>
---
 tests/intel/kms_fbcon_fbt.c | 1 -
 tests/intel/kms_pm_rpm.c    | 4 +---
 2 files changed, 1 insertion(+), 4 deletions(-)

diff --git a/tests/intel/kms_fbcon_fbt.c b/tests/intel/kms_fbcon_fbt.c
index 36de84f985..e44be15f60 100644
--- a/tests/intel/kms_fbcon_fbt.c
+++ b/tests/intel/kms_fbcon_fbt.c
@@ -371,7 +371,6 @@ static void restore_fbcon(struct drm_info *drm)
 
 static void subtest(struct drm_info *drm, struct feature *feature, bool suspend)
 {
-	igt_device_set_master(drm->fd);
 	kmstest_set_vt_graphics_mode();
 
 	igt_require(feature->supported_on_chipset(drm->fd, drm->debugfs_fd));
diff --git a/tests/intel/kms_pm_rpm.c b/tests/intel/kms_pm_rpm.c
index 5f24fd49b1..e16218ceeb 100644
--- a/tests/intel/kms_pm_rpm.c
+++ b/tests/intel/kms_pm_rpm.c
@@ -750,9 +750,7 @@ static bool setup_environment(void)
 	if (has_runtime_pm)
 		goto out;
 
-	drm_fd = __drm_open_driver(DRIVER_INTEL | DRIVER_XE);
-	igt_require(drm_fd != -1);
-	igt_device_set_master(drm_fd);
+	drm_fd = drm_open_driver_master(DRIVER_INTEL | DRIVER_XE);
 
 	debugfs = igt_debugfs_dir(drm_fd);
 	igt_require(debugfs != -1);
-- 
2.43.0


             reply	other threads:[~2026-02-26 23:10 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-02-26 23:10 Jonathan Cavitt [this message]
2026-02-27  2:31 ` ✓ i915.CI.BAT: success for tests/intel/kms: Drop unneeded igt_device_set_master calls Patchwork
2026-02-27  2:40 ` ✗ Xe.CI.BAT: failure " Patchwork
2026-02-27 10:45 ` ✓ Xe.CI.FULL: success " Patchwork
2026-02-27 11:20 ` ✗ i915.CI.Full: failure " Patchwork
2026-02-27 14:12 ` [PATCH] " Kamil Konieczny

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=20260226231036.83942-2-jonathan.cavitt@intel.com \
    --to=jonathan.cavitt@intel.com \
    --cc=alex.zuo@intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    --cc=saurabhg.gupta@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