[PATCH i-g-t v2 33/39] tests/chamelium/v3: Implement non-4K EDID stress test

Louis Chauvet louis.chauvet at bootlin.com
Tue Jul 9 15:34:49 UTC 2024


The existing EDID test has been enhanced to also test non-4K screens. The
current EDID database includes entries for HDMI and DP ports.

Signed-off-by: Louis Chauvet <louis.chauvet at bootlin.com>
---
 tests/chamelium/v3/kms_chamelium_v3_edid.c | 29 +++++++++++++++++++++++++++++
 1 file changed, 29 insertions(+)

diff --git a/tests/chamelium/v3/kms_chamelium_v3_edid.c b/tests/chamelium/v3/kms_chamelium_v3_edid.c
index deef04d97bec..b6660769897f 100644
--- a/tests/chamelium/v3/kms_chamelium_v3_edid.c
+++ b/tests/chamelium/v3/kms_chamelium_v3_edid.c
@@ -134,6 +134,35 @@ igt_main
 		}
 	}
 
+	igt_describe("Read many different non-4k EDID from the chamelium");
+	igt_subtest_with_dynamic("edid-stress-non-4k") {
+		struct chamelium_v3_port_mapping *port, *tmp;
+
+		igt_list_for_each_entry_safe(port, tmp, chamelium_v3_get_port_mapping(chamelium),
+					     link) {
+			igt_dynamic_f("port-%d", port->port_id) {
+				drmModeConnectorPtr connector;
+				size_t edid_count = 0;
+				char *name;
+
+				igt_require(!chamelium_v3_is_mst(chamelium, port->port_id));
+
+				name = chamelium_v3_get_port_name(chamelium, port->port_id);
+				igt_info("Testing port %s (%s)\n", port->connector_name, name);
+				free(name);
+
+				connector = chamelium_v3_port_mapping_get_connector(port, drm_fd);
+				igt_assert(connector);
+				edid_stress_resolution(drm_fd, chamelium, port,
+						       get_edids_for_connector_type(connector->connector_type,
+										    &edid_count,
+										    false),
+						       edid_count);
+				drmModeFreeConnector(connector);
+			}
+		}
+	}
+
 	igt_fixture {
 		chamelium_v3_uninit(chamelium);
 		drm_close_driver(drm_fd);

-- 
2.44.2



More information about the igt-dev mailing list