Igt-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH i-g-t] tests/kms_atomic_transition: Fix retry-path resources in modeset tests
@ 2026-06-23 18:42 Pranay Samala
  2026-06-23 19:14 ` ✓ Xe.CI.BAT: success for " Patchwork
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: Pranay Samala @ 2026-06-23 18:42 UTC (permalink / raw)
  To: igt-dev; +Cc: karthik.b.s, sameer.lattannavar, pranay.samala

When a bandwidth fallback retry happens, resources from
previous attempt may not be released, leading to accumulation
of allocated objects across retries.

Add cleanup before retry to ensure clean starting state by
releasing resources and removing allocated framebuffers,
preventing resource buildup.

Signed-off-by: Pranay Samala <pranay.samala@intel.com>
---
 tests/kms_atomic_transition.c | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/tests/kms_atomic_transition.c b/tests/kms_atomic_transition.c
index 58cadc560..37dc77c28 100644
--- a/tests/kms_atomic_transition.c
+++ b/tests/kms_atomic_transition.c
@@ -1026,6 +1026,16 @@ retry:
 		bool found = igt_override_all_active_output_modes_to_fit_bw(&data->display);
 		igt_require_f(found, "No valid mode combo found.\n");
 
+		if (is_intel_device(data->drm_fd)) {
+			for_each_crtc(&data->display, crtc) {
+				igt_pipe_crc_free(data->pipe_crcs[crtc->crtc_index]);
+				data->pipe_crcs[crtc->crtc_index] = NULL;
+			}
+		}
+
+		igt_remove_fb(data->drm_fd, &data->fbs[0]);
+		igt_remove_fb(data->drm_fd, &data->fbs[1]);
+
 		goto retry;
 	}
 	igt_display_commit2(&data->display, COMMIT_ATOMIC);
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2026-06-24  6:37 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-06-23 18:42 [PATCH i-g-t] tests/kms_atomic_transition: Fix retry-path resources in modeset tests Pranay Samala
2026-06-23 19:14 ` ✓ Xe.CI.BAT: success for " Patchwork
2026-06-23 19:54 ` ✓ i915.CI.BAT: " Patchwork
2026-06-24  2:46 ` ✗ Xe.CI.FULL: failure " Patchwork
2026-06-24  3:39 ` [PATCH i-g-t] " Reddy Guddati, Santhosh
2026-06-24  6:36 ` ✓ i915.CI.Full: success for " Patchwork

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox