Big patch series to perform a single thing. With legacy modesets if the primary plane had a null fb it was disabled, and code would often do the following: for_each_pipe(...) for_each_output(...) { igt_output_set_pipe(output, pipe); igt_display_commit(); if (!output->valid) bail; cleanup; igt_output_set_pipe(output, PIPE_ANY); igt_display_commit(); } A straightforward replacement of igt_display_commit with igt_display_commit2(COMMIT_ATOMIC) will not work with this series, since in this case it can perform a modeset without primary framebuffer, and invalid configurations get rejected. Best solution is to do the following to get atomic behavior, with fallback to legacy: bool valid = false; for_each_pipe_with_valid_output(display, pipe, output) { valid = true; igt_output_set_pipe(output, pipe); /* perform more setup here for planes, etc */ igt_display_commit2(display, display->is_atomic ? COMMIT_ATOMIC : COMMIT_LEGACY); /* tests + cleanup */ igt_output_set_pipe(output, PIPE_NONE); } igt_require_f(valid, "no valid crtc/connector combinations found\n"); If the test requires a fixed pipe, use for_each_valid_output_on_pipe instead. Maarten Lankhorst (10): igt_kms: Remove kmstest_connector_config.crtc_idx igt_kms: Find optimal encoder only after selecting pipe kms_psr_sink_crc: Use for_each_pipe_with_valid_output to find a valid config. igt_kms: Make PIPE_ANY a alias for PIPE_NONE igt_kms: Change PIPE_ANY behavior to mean unassigned igt_kms: Handle atomic pipe properties better. igt_kms: Remove pan members from igt_plane igt_kms: Clear all _changed members centrally igt_kms: Add modeset support to atomic commits. tests: Add kms_rmfb test. lib/igt_kms.c | 626 ++++++++++++++++++++++++++-------------------- lib/igt_kms.h | 48 ++-- tests/Makefile.sources | 1 + tests/kms_panel_fitting.c | 2 +- tests/kms_plane.c | 8 +- tests/kms_plane_scaling.c | 2 +- tests/kms_psr_sink_crc.c | 5 +- tests/kms_rmfb.c | 171 +++++++++++++ tests/testdisplay.c | 4 +- 9 files changed, 567 insertions(+), 300 deletions(-) create mode 100644 tests/kms_rmfb.c -- 2.5.5 _______________________________________________ Intel-gfx mailing list Intel-gfx@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/intel-gfx