From: Kunal Joshi <kunal1.joshi@intel.com>
To: igt-dev@lists.freedesktop.org
Cc: Kunal Joshi <kunal1.joshi@intel.com>
Subject: [PATCH i-g-t 5/6] tests/kms_pipe_crc_basic: Use cleanup framework for drm_fd
Date: Mon, 2 Feb 2026 14:15:38 +0530 [thread overview]
Message-ID: <20260202084539.2524306-6-kunal1.joshi@intel.com> (raw)
In-Reply-To: <20260202084539.2524306-1-kunal1.joshi@intel.com>
Use the cleanup framework to automatically close the drm_fd, ensuring it is
closed after all resources that depend on it (framebuffers, pipe CRCs) have
been cleaned up. This removes the manual drm_close_driver() call from the
final fixture.
---
tests/kms_pipe_crc_basic.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tests/kms_pipe_crc_basic.c b/tests/kms_pipe_crc_basic.c
index 386cb15ef..f1deaf081 100644
--- a/tests/kms_pipe_crc_basic.c
+++ b/tests/kms_pipe_crc_basic.c
@@ -397,6 +397,7 @@ int igt_main_args("e", NULL, help_str, opt_handler, NULL)
igt_fixture() {
data.drm_fd = drm_open_driver_master(DRIVER_ANY);
+ igt_cleanup_register_fd(data.drm_fd);
kmstest_set_vt_graphics_mode();
@@ -503,6 +504,5 @@ int igt_main_args("e", NULL, help_str, opt_handler, NULL)
igt_fixture() {
igt_display_fini(&data.display);
- drm_close_driver(data.drm_fd);
}
}
--
2.43.0
next prev parent reply other threads:[~2026-02-02 8:24 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-02-02 8:45 [PATCH i-g-t 0/6] tests/kms_pipe_crc_basic: add mst suspend-resume test Kunal Joshi
2026-02-02 8:45 ` [PATCH i-g-t 1/6] tests/intel/kms_mst_helper: Add helper to check for MST outputs Kunal Joshi
2026-02-02 8:45 ` [PATCH i-g-t 2/6] lib/igt_cleanup: Add general resource cleanup infrastructure Kunal Joshi
2026-02-02 8:45 ` [PATCH i-g-t 3/6] tests/kms_pipe_crc_basic: Use cleanup framework for framebuffers Kunal Joshi
2026-02-02 8:45 ` [PATCH i-g-t 4/6] tests/kms_pipe_crc_basic: Use cleanup framework for pipe CRC Kunal Joshi
2026-02-02 8:45 ` Kunal Joshi [this message]
2026-02-02 8:45 ` [PATCH i-g-t 6/6] tests/kms_pipe_crc_basic: Add MST suspend-resume test Kunal Joshi
2026-02-04 10:40 ` Bilal, Mohammed
2026-02-03 0:13 ` ✓ Xe.CI.BAT: success for tests/kms_pipe_crc_basic: add mst suspend-resume test (rev3) Patchwork
2026-02-03 0:19 ` ✓ i915.CI.BAT: " Patchwork
2026-02-03 7:54 ` ✗ Xe.CI.FULL: failure " Patchwork
2026-02-03 8:55 ` ✗ 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=20260202084539.2524306-6-kunal1.joshi@intel.com \
--to=kunal1.joshi@intel.com \
--cc=igt-dev@lists.freedesktop.org \
/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