[PATCH v2 4/5] tests/kms_writeback: Disable all outputs after igt_display_require()
Jessica Zhang
quic_jesszhan at quicinc.com
Thu Aug 29 03:05:35 UTC 2024
In cases where the custom mode set by the `-c` flag is the same as the
primary display mode, a modeset will not occur in the driver despite the
outputs being changed.
Since the writeback connector is stealing the primary display without
changing the display mode, the CRTC would only register that the
connectors have changed and not that the mode is changed. This would
cause the encoder mode set to be skipped [1].
Force a modeset to happen by disabling all outputs after
igt_display_require().
[1] https://elixir.bootlin.com/linux/v6.10.6/source/drivers/gpu/drm/drm_atomic_helper.c#L1379
Signed-off-by: Jessica Zhang <quic_jesszhan at quicinc.com>
---
tests/kms_writeback.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/tests/kms_writeback.c b/tests/kms_writeback.c
index 4155961a0..97abb88fe 100644
--- a/tests/kms_writeback.c
+++ b/tests/kms_writeback.c
@@ -571,6 +571,7 @@ igt_main_args("b:c:f:dl", long_options, help_str, opt_handler, NULL)
igt_require_f(!ret, "error setting DRM_CLIENT_CAP_WRITEBACK_CONNECTORS\n");
igt_display_require(&display, display.drm_fd);
+ igt_modeset_disable_all_outputs(&display);
igt_require(display.is_atomic);
--
2.34.1
More information about the igt-dev
mailing list